]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - net/core/dev.c
dropmon: add ability to detect when hardware dropsrxpackets
[net-next-2.6.git] / net / core / dev.c
index 92ebeca29901fd803daba7f2cc979a6a68b890d2..3942266d1f6c7a0ca3c23beb1b9d1be7cc26c9cf 100644 (file)
 #include <linux/in.h>
 #include <linux/jhash.h>
 #include <linux/random.h>
+#include <trace/napi.h>
 
 #include "net-sysfs.h"
 
@@ -2771,8 +2772,10 @@ static void net_rx_action(struct softirq_action *h)
                 * accidently calling ->poll() when NAPI is not scheduled.
                 */
                work = 0;
-               if (test_bit(NAPI_STATE_SCHED, &n->state))
+               if (test_bit(NAPI_STATE_SCHED, &n->state)) {
                        work = n->poll(n, weight);
+                       trace_napi_poll(n);
+               }
 
                WARN_ON_ONCE(work > weight);