netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1] ip6_pol_route panic: Do not allow VLAN on loopback
@ 2011-04-14 16:07 Krishna Kumar
  2011-04-14 16:07 ` [PATCH v2] ip6_pol_route panic: Do not propagate LOOPBACK to VLAN Krishna Kumar
  2011-04-18  6:27 ` [PATCH v1] ip6_pol_route panic: Do not allow VLAN on loopback David Miller
  0 siblings, 2 replies; 3+ messages in thread
From: Krishna Kumar @ 2011-04-14 16:07 UTC (permalink / raw)
  To: davem; +Cc: netdev, Krishna Kumar

I have tested two ways of fixing this panic:
	1. PATCH1: Do not allow vlan on lo.
	2. PATCH2: Do not propagate LOOPBACK to vlan devices.

Isn't it better to use PATCH1 and disallow vlan on lo?

The result of this patch is:

# modprobe 8021q
# vconfig add lo 43
ERROR: trying to add VLAN #43 to IF -:lo:-  error: Operation not supported

Signed-off-by: Krishna Kumar <krkumar2@in.ibm.com>
---
 drivers/net/loopback.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff -ruNp org/drivers/net/loopback.c new1/drivers/net/loopback.c
--- org/drivers/net/loopback.c	2011-04-14 20:45:46.000000000 +0530
+++ new1/drivers/net/loopback.c	2011-04-14 20:47:09.000000000 +0530
@@ -173,7 +173,8 @@ static void loopback_setup(struct net_de
 		| NETIF_F_RXCSUM
 		| NETIF_F_HIGHDMA
 		| NETIF_F_LLTX
-		| NETIF_F_NETNS_LOCAL;
+		| NETIF_F_NETNS_LOCAL
+		| NETIF_F_VLAN_CHALLENGED;
 	dev->ethtool_ops	= &loopback_ethtool_ops;
 	dev->header_ops		= &eth_header_ops;
 	dev->netdev_ops		= &loopback_ops;

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-04-18  6:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-04-14 16:07 [PATCH v1] ip6_pol_route panic: Do not allow VLAN on loopback Krishna Kumar
2011-04-14 16:07 ` [PATCH v2] ip6_pol_route panic: Do not propagate LOOPBACK to VLAN Krishna Kumar
2011-04-18  6:27 ` [PATCH v1] ip6_pol_route panic: Do not allow VLAN on loopback David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).