Re: warn: Turn the netdev timeout WARN_ON() into a WARN()

From: Jeff Garzik
Date: Wed Sep 17 2008 - 17:39:23 EST


Arjan van de Ven wrote:
From: Arjan van de Ven <arjan@xxxxxxxxxxxxxxx>
Subject: [PATCH] net: WARN_ONCE -> WARN as requested by Jeff Garzik

Jeff points out that you want to see each and every
timeout message

Signed-off-by: Arjan van de Ven <arjan@xxxxxxxxxxxxxxx>
---
net/sched/sch_generic.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c
index ec0a083..8772642 100644
--- a/net/sched/sch_generic.c
+++ b/net/sched/sch_generic.c
@@ -215,7 +215,7 @@ static void dev_watchdog(unsigned long arg)
time_after(jiffies, (dev->trans_start +
dev->watchdog_timeo))) {
char drivername[64];
- WARN_ONCE(1, KERN_INFO "NETDEV WATCHDOG: %s (%s): transmit timed out\n",
+ WARN(1, KERN_INFO "NETDEV WATCHDOG: %s (%s): transmit timed out\n",
dev->name, netdev_drivername(dev, drivername, 64));
dev->tx_timeout(dev);


ACK, this fixes my objection, thanks

It still seems a bit burdensome to print out a huge, redundant backtrace and kernel info each time, though.

The most important information is (a) a timeout occurred and (b) hopefully some hardware register dump or similar driver-specific output.

If all the networking guys agree that the report
has no value for developers because they're all unfixable hardware bugs,

You misunderstand; reporting and tracking these issues have value, but the information you are dumping (specifically the backtrace) does not.

You say your goal here mainly to standardize reporting to permit automated collection -- I support that goal too. But is there a better way -- say perhaps just printing the header you need, and _not_ the useless backtrace?

I think it would benefit Linux if our bugs announce themselves in a standard way, but the backtrace is not a key part of that, and IMO should be optional.

Jeff


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/