Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F109093850
D38064.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
931 B
Referenced Files
None
Subscribers
None
D38064.diff
View Options
diff --git a/sys/dev/netmap/netmap.c b/sys/dev/netmap/netmap.c
--- a/sys/dev/netmap/netmap.c
+++ b/sys/dev/netmap/netmap.c
@@ -4329,8 +4329,10 @@
mbq_unlock(q);
done:
- if (m)
+ if (m) {
+ if_inc_counter(ifp, IFCOUNTER_OQDROPS, 1);
m_freem(m);
+ }
/* unconditionally wake up listeners */
kring->nm_notify(kring, 0);
/* this is normally netmap_notify(), but for nics
diff --git a/sys/dev/netmap/netmap_generic.c b/sys/dev/netmap/netmap_generic.c
--- a/sys/dev/netmap/netmap_generic.c
+++ b/sys/dev/netmap/netmap_generic.c
@@ -837,8 +837,10 @@
* support RX scatter-gather. */
nm_prlim(2, "Warning: driver pushed up big packet "
"(size=%d)", (int)MBUF_LEN(m));
+ if_inc_counter(ifp, IFCOUNTER_IQDROPS, 1);
m_freem(m);
} else if (unlikely(mbq_len(&kring->rx_queue) > na->num_rx_desc)) {
+ if_inc_counter(ifp, IFCOUNTER_IQDROPS, 1);
m_freem(m);
} else {
mbq_safe_enqueue(&kring->rx_queue, m);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Feb 1, 4:53 PM (20 h, 41 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16387850
Default Alt Text
D38064.diff (931 B)
Attached To
Mode
D38064: netmap: Try to count packet drops in emulated mode
Attached
Detach File
Event Timeline
Log In to Comment