Thread (44 messages) 44 messages, 6 authors, 2015-05-09
STALE4050d
Revisions (6)
  1. v1 [diff vs current]
  2. v2 [diff vs current]
  3. v3 [diff vs current]
  4. v5 current
  5. v6 [diff vs current]
  6. v7 [diff vs current]

[PATCH net-next v5 07/21] switchdev: add port vlan obj

From: <hidden>
Date: 2015-05-05 17:34:08
Subsystem: networking [general], switchdev, the rest · Maintainers: "David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Jiri Pirko, Ivan Vecera, Linus Torvalds

From: Scott Feldman <redacted>

VLAN obj has flags (PVID and untagged) as well as start and end vid ranges.
The switchdev driver can optimize programing the device using the ranges.

Signed-off-by: Scott Feldman <redacted>
---
 include/net/switchdev.h |    8 ++++++++
 1 file changed, 8 insertions(+)
diff --git a/include/net/switchdev.h b/include/net/switchdev.h
index 4f43300..e598c2d 100644
--- a/include/net/switchdev.h
+++ b/include/net/switchdev.h
@@ -43,11 +43,19 @@ struct fib_info;
 
 enum switchdev_obj_id {
 	SWITCHDEV_OBJ_UNDEFINED,
+	SWITCHDEV_OBJ_PORT_VLAN,
 };
 
 struct switchdev_obj {
 	enum switchdev_obj_id id;
 	enum switchdev_trans trans;
+	union {
+		struct switchdev_obj_vlan {			/* PORT_VLAN */
+			u16 flags;
+			u16 vid_start;
+			u16 vid_end;
+		} vlan;
+	};
 };
 
 /**
-- 
1.7.10.4
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help