提交 da6b9ba9 编写于 作者: A Andrew Lunn 提交者: Greg Kroah-Hartman

Staging: batman-adv: stop persistent warnings if a device is deactivated.

Without this change we spam the kernel log on every packet received on
any other interface when an interface has been added, but is not yet
active, ie UP.
Signed-off-by: NSimon Wunderlich <siwu@hrz.tu-chemnitz.de>
Signed-off-by: NAndrew Lunn <andrew@lunn.ch>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 4efe0b06
...@@ -1177,12 +1177,8 @@ static int discard_one_packet(struct batman_if *batman_if, ...@@ -1177,12 +1177,8 @@ static int discard_one_packet(struct batman_if *batman_if,
{ {
int result = -EAGAIN; int result = -EAGAIN;
if (batman_if->if_active != IF_TO_BE_ACTIVATED) { if ((batman_if->if_active == IF_TO_BE_ACTIVATED)
printk(KERN_WARNING && (batman_if->raw_sock)) {
"batman-adv:Could not read from deactivated interface %s!\n",
batman_if->dev);
} else {
if (batman_if->raw_sock)
result = receive_raw_packet(batman_if->raw_sock, result = receive_raw_packet(batman_if->raw_sock,
packet_buff, packet_buff,
PACKBUFF_SIZE); PACKBUFF_SIZE);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册