~ubuntu-branches/debian/wheezy/linux-2.6/wheezy

« back to all changes in this revision

Viewing changes to net/core/gen_stats.c

  • Committer: Bazaar Package Importer
  • Author(s): Ben Hutchings, Ben Hutchings, Aurelien Jarno, Martin Michlmayr
  • Date: 2011-04-06 13:53:30 UTC
  • mfrom: (43.1.5 sid)
  • Revision ID: james.westby@ubuntu.com-20110406135330-wjufxhd0tvn3zx4z
Tags: 2.6.38-3
[ Ben Hutchings ]
* [ppc64] Add to linux-tools package architectures (Closes: #620124)
* [amd64] Save cr4 to mmu_cr4_features at boot time (Closes: #620284)
* appletalk: Fix bugs introduced when removing use of BKL
* ALSA: Fix yet another race in disconnection
* cciss: Fix lost command issue
* ath9k: Fix kernel panic in AR2427
* ses: Avoid kernel panic when lun 0 is not mapped
* PCI/ACPI: Report ASPM support to BIOS if not disabled from command line

[ Aurelien Jarno ]
* rtlwifi: fix build when PCI is not enabled.

[ Martin Michlmayr ]
* rtlwifi: Eliminate udelay calls with too large values (Closes: #620204)

Show diffs side-by-side

added added

removed removed

Lines of Context:
73
73
 
74
74
        return 0;
75
75
}
 
76
EXPORT_SYMBOL(gnet_stats_start_copy_compat);
76
77
 
77
78
/**
78
79
 * gnet_stats_start_copy_compat - start dumping procedure in compatibility mode
93
94
{
94
95
        return gnet_stats_start_copy_compat(skb, type, 0, 0, lock, d);
95
96
}
 
97
EXPORT_SYMBOL(gnet_stats_start_copy);
96
98
 
97
99
/**
98
100
 * gnet_stats_copy_basic - copy basic statistics into statistic TLV
123
125
        }
124
126
        return 0;
125
127
}
 
128
EXPORT_SYMBOL(gnet_stats_copy_basic);
126
129
 
127
130
/**
128
131
 * gnet_stats_copy_rate_est - copy rate estimator statistics into statistics TLV
129
132
 * @d: dumping handle
 
133
 * @b: basic statistics
130
134
 * @r: rate estimator statistics
131
135
 *
132
136
 * Appends the rate estimator statistics to the top level TLV created by
136
140
 * if the room in the socket buffer was not sufficient.
137
141
 */
138
142
int
139
 
gnet_stats_copy_rate_est(struct gnet_dump *d, struct gnet_stats_rate_est *r)
 
143
gnet_stats_copy_rate_est(struct gnet_dump *d,
 
144
                         const struct gnet_stats_basic_packed *b,
 
145
                         struct gnet_stats_rate_est *r)
140
146
{
 
147
        if (b && !gen_estimator_active(b, r))
 
148
                return 0;
 
149
 
141
150
        if (d->compat_tc_stats) {
142
151
                d->tc_stats.bps = r->bps;
143
152
                d->tc_stats.pps = r->pps;
148
157
 
149
158
        return 0;
150
159
}
 
160
EXPORT_SYMBOL(gnet_stats_copy_rate_est);
151
161
 
152
162
/**
153
163
 * gnet_stats_copy_queue - copy queue statistics into statistics TLV
175
185
 
176
186
        return 0;
177
187
}
 
188
EXPORT_SYMBOL(gnet_stats_copy_queue);
178
189
 
179
190
/**
180
191
 * gnet_stats_copy_app - copy application specific statistics into statistics TLV
202
213
 
203
214
        return 0;
204
215
}
 
216
EXPORT_SYMBOL(gnet_stats_copy_app);
205
217
 
206
218
/**
207
219
 * gnet_stats_finish_copy - finish dumping procedure
235
247
        spin_unlock_bh(d->lock);
236
248
        return 0;
237
249
}
238
 
 
239
 
 
240
 
EXPORT_SYMBOL(gnet_stats_start_copy);
241
 
EXPORT_SYMBOL(gnet_stats_start_copy_compat);
242
 
EXPORT_SYMBOL(gnet_stats_copy_basic);
243
 
EXPORT_SYMBOL(gnet_stats_copy_rate_est);
244
 
EXPORT_SYMBOL(gnet_stats_copy_queue);
245
 
EXPORT_SYMBOL(gnet_stats_copy_app);
246
250
EXPORT_SYMBOL(gnet_stats_finish_copy);