[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4857B542.6030703@trash.net>
Date: Tue, 17 Jun 2008 14:59:46 +0200
From: Patrick McHardy <kaber@...sh.net>
To: Wang Chen <wangchen@...fujitsu.com>
CC: "David S. Miller" <davem@...emloft.net>,
NETDEV <netdev@...r.kernel.org>
Subject: Re: v2: [PATCH 2/3] netdevice: Fix promiscuity and allmulti overflow
Wang Chen wrote:
> + if (dev->promiscuity == 0) {
> + /*
> + * Avoid overflow.
> + * If inc causes overflow, untouch promisc and return error.
> + */
> + if (inc < 0)
> + dev->flags &= ~IFF_PROMISC;
> + else {
> + dev->promiscuity -= inc;
> + printk(KERN_ERR "%s: promiscuity touches roof, "
> + "set promiscuity failed, promiscuity feature "
> + "of device will be broken.\n", dev->name);
> + return -EOVERFLOW;
> + }
> + }
Assuming the caller does proper error handling, that printk is
not true.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists