开发者

ifconfig packet count

if I type ifconfig i get packet for Tx and RX ... where exactly the piece of code to increment this counter? Is it in the network driver itself? or in the kernel ?

If possible please provide lxr link of the counter var开发者_JAVA技巧iable used.

Thx !


It's done in the individual network drivers.

Eg, for the rtl8139too driver, the TX count is incremented on line 1786 (see here).


ifconfig read the statistics off from procfs. The values found in proc is updated by the kernel and ultimately boils down to the drivers of the network card.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜