]> git.sur5r.net Git - ngadmin/blobdiff - raw/include/nsdp/protocol.h
Merge remote-tracking branch 'upstream/master'
[ngadmin] / raw / include / nsdp / protocol.h
index a785e2c1b4ee1318091f5dcfcb49b15f22282381..70d111e0f187af18ce33ac0b72f9a7767003107a 100644 (file)
@@ -17,7 +17,9 @@
 #define CODE_WRITE_REQ         3
 #define CODE_WRITE_REP         4
 
+#define ERROR_NONE             0
 #define ERROR_READONLY         3
+#define ERROR_WRITEONLY                4
 #define ERROR_INVALID_VALUE    5
 #define ERROR_DENIED           7
 
@@ -64,6 +66,7 @@
 #define ATTR_IGMP_BLOCK_UNK    0x6C00
 #define ATTR_IGMP_VALID_V3     0x7000
 #define ATTR_TLV_BITMAP                0x7400
+#define ATTR_LOOP_DETECT       0x9000
 #define ATTR_END               0xFFFF
 
 
@@ -147,14 +150,23 @@ struct attr_cabletest_result {
 } __attribute__((packed));
 
 
-/**
- * Note: this structure is not sent "as-is" on the wire.
+/* Note: this structure is not sent "as-is" on the wire.
  * A translation is done between the wire format (which uses somewhat not
- * trivial bitmap) and this simpler format. See encoding_attr.c for more details.
+ * trivial bitmap) and this simpler format. See attr.c for more details.
  */
 struct attr_vlan_conf {
-       unsigned short vlan;            /* port number */
-       unsigned char ports[0];         /* array, maps each port to a VLAN */
+       unsigned short vlan;            /* VLAN number */
+       unsigned char ports[0];         /* array, maps each port association with the VLAN */
+};
+
+
+/* Note: this structure is not sent "as-is" on the wire.
+ * A translation is done between the wire format (which uses somewhat not
+ * trivial bitmap) and this simpler format. See attr.c for more details.
+ */
+struct attr_mirror {
+       unsigned char outport;          /* port number on which traffic is sent */
+       unsigned char ports[0];         /* array, maps each port source mirror traffic */
 };