drop_monitor: allow more events per second
It seems there is a logic error in trace_drop_common(), since we store only 64 drops, even if they are from same location. This fix is a one liner, but we probably need more work to avoid useless atomic dec/inc Now I can watch 1 Mpps drops through dropwatch... Signed-off-by: Eric Dumazet <edumazet@google.com> Cc: Neil Horman <nhorman@tuxdriver.com> Acked-by: Neil Horman <nhorman@tuxdriver.com> Signed-off-by: David S. Miller <davem@davemloft.net>wifi-calibration
parent
e8195b24fe
commit
bbe362be53
|
@ -150,6 +150,7 @@ static void trace_drop_common(struct sk_buff *skb, void *location)
|
||||||
for (i = 0; i < msg->entries; i++) {
|
for (i = 0; i < msg->entries; i++) {
|
||||||
if (!memcmp(&location, msg->points[i].pc, sizeof(void *))) {
|
if (!memcmp(&location, msg->points[i].pc, sizeof(void *))) {
|
||||||
msg->points[i].count++;
|
msg->points[i].count++;
|
||||||
|
atomic_inc(&data->dm_hit_count);
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue