diff options
author | Bill Meier <wmeier@newsguy.com> | 2014-10-04 11:28:35 -0400 |
---|---|---|
committer | Bill Meier <wmeier@newsguy.com> | 2014-10-04 15:34:02 +0000 |
commit | ebfe8f6d289e3d2649dcfd5a3902ba038b0ee2bd (patch) | |
tree | d7cfeb5eb4592086744dbfaa71f1163932bc43a8 /epan/dissectors/packet-bpdu.c | |
parent | 20795925ffb2f9687e960de8d6798e53482cb175 (diff) |
Add editor modelines; Reformat as appropriate.
Change-Id: I8e9c58b75eea85877d22024201e5d8d0e9a3dbfd
Reviewed-on: https://code.wireshark.org/review/4459
Reviewed-by: Bill Meier <wmeier@newsguy.com>
Diffstat (limited to 'epan/dissectors/packet-bpdu.c')
-rw-r--r-- | epan/dissectors/packet-bpdu.c | 499 |
1 files changed, 256 insertions, 243 deletions
diff --git a/epan/dissectors/packet-bpdu.c b/epan/dissectors/packet-bpdu.c index 895998b3ae..0a4b9203d2 100644 --- a/epan/dissectors/packet-bpdu.c +++ b/epan/dissectors/packet-bpdu.c @@ -36,70 +36,70 @@ /* Offsets of fields within a BPDU */ -#define BPDU_IDENTIFIER 0 -#define BPDU_VERSION_IDENTIFIER 2 -#define BPDU_TYPE 3 -#define BPDU_FLAGS 4 -#define BPDU_ROOT_IDENTIFIER 5 -#define BPDU_ROOT_PATH_COST 13 -#define BPDU_BRIDGE_IDENTIFIER 17 -#define BPDU_PORT_IDENTIFIER 25 -#define BPDU_MESSAGE_AGE 27 -#define BPDU_MAX_AGE 29 -#define BPDU_HELLO_TIME 31 -#define BPDU_FORWARD_DELAY 33 -#define BPDU_VERSION_1_LENGTH 35 -#define BPDU_VERSION_3_LENGTH 36 -#define BPDU_MST_CONFIG_FORMAT_SELECTOR 38 -#define BPDU_MST_CONFIG_NAME 39 -#define BPDU_MST_CONFIG_REVISION_LEVEL 71 -#define BPDU_MST_CONFIG_DIGEST 73 -#define BPDU_CIST_INTERNAL_ROOT_PATH_COST 89 -#define BPDU_CIST_BRIDGE_IDENTIFIER 93 -#define BPDU_CIST_REMAINING_HOPS 101 -#define BPDU_MSTI 102 - -#define BPDU_PVST_TLV 36 - -#define MSTI_FLAGS 0 -#define MSTI_REGIONAL_ROOT 1 -#define MSTI_INTERNAL_ROOT_PATH_COST 9 -#define MSTI_BRIDGE_IDENTIFIER_PRIORITY 13 -#define MSTI_PORT_IDENTIFIER_PRIORITY 14 -#define MSTI_REMAINING_HOPS 15 - - -#define CONF_BPDU_SIZE 35 -#define TC_BPDU_SIZE 4 -#define MST_BPDU_SIZE 38 -#define VERSION_3_STATIC_LENGTH 64 -#define MSTI_MESSAGE_SIZE 16 +#define BPDU_IDENTIFIER 0 +#define BPDU_VERSION_IDENTIFIER 2 +#define BPDU_TYPE 3 +#define BPDU_FLAGS 4 +#define BPDU_ROOT_IDENTIFIER 5 +#define BPDU_ROOT_PATH_COST 13 +#define BPDU_BRIDGE_IDENTIFIER 17 +#define BPDU_PORT_IDENTIFIER 25 +#define BPDU_MESSAGE_AGE 27 +#define BPDU_MAX_AGE 29 +#define BPDU_HELLO_TIME 31 +#define BPDU_FORWARD_DELAY 33 +#define BPDU_VERSION_1_LENGTH 35 +#define BPDU_VERSION_3_LENGTH 36 +#define BPDU_MST_CONFIG_FORMAT_SELECTOR 38 +#define BPDU_MST_CONFIG_NAME 39 +#define BPDU_MST_CONFIG_REVISION_LEVEL 71 +#define BPDU_MST_CONFIG_DIGEST 73 +#define BPDU_CIST_INTERNAL_ROOT_PATH_COST 89 +#define BPDU_CIST_BRIDGE_IDENTIFIER 93 +#define BPDU_CIST_REMAINING_HOPS 101 +#define BPDU_MSTI 102 + +#define BPDU_PVST_TLV 36 + +#define MSTI_FLAGS 0 +#define MSTI_REGIONAL_ROOT 1 +#define MSTI_INTERNAL_ROOT_PATH_COST 9 +#define MSTI_BRIDGE_IDENTIFIER_PRIORITY 13 +#define MSTI_PORT_IDENTIFIER_PRIORITY 14 +#define MSTI_REMAINING_HOPS 15 + + +#define CONF_BPDU_SIZE 35 +#define TC_BPDU_SIZE 4 +#define MST_BPDU_SIZE 38 +#define VERSION_3_STATIC_LENGTH 64 +#define MSTI_MESSAGE_SIZE 16 /* Values for the Alternative MSTI format */ -#define ALT_BPDU_CIST_BRIDGE_IDENTIFIER 89 -#define ALT_BPDU_CIST_INTERNAL_ROOT_PATH_COST 97 +#define ALT_BPDU_CIST_BRIDGE_IDENTIFIER 89 +#define ALT_BPDU_CIST_INTERNAL_ROOT_PATH_COST 97 -#define ALT_MSTI_MSTID 0 -#define ALT_MSTI_FLAGS 2 -#define ALT_MSTI_REGIONAL_ROOT 3 -#define ALT_MSTI_INTERNAL_ROOT_PATH_COST 11 -#define ALT_MSTI_BRIDGE_IDENTIFIER 15 -#define ALT_MSTI_PORT_IDENTIFIER 23 -#define ALT_MSTI_REMAINING_HOPS 25 +#define ALT_MSTI_MSTID 0 +#define ALT_MSTI_FLAGS 2 +#define ALT_MSTI_REGIONAL_ROOT 3 +#define ALT_MSTI_INTERNAL_ROOT_PATH_COST 11 +#define ALT_MSTI_BRIDGE_IDENTIFIER 15 +#define ALT_MSTI_PORT_IDENTIFIER 23 +#define ALT_MSTI_REMAINING_HOPS 25 -#define ALT_MSTI_MESSAGE_SIZE 26 +#define ALT_MSTI_MESSAGE_SIZE 26 /* Flag bits */ -#define BPDU_FLAGS_TCACK 0x80 -#define BPDU_FLAGS_AGREEMENT 0x40 -#define BPDU_FLAGS_FORWARDING 0x20 -#define BPDU_FLAGS_LEARNING 0x10 -#define BPDU_FLAGS_PORT_ROLE_MASK 0x0C -#define BPDU_FLAGS_PORT_ROLE_SHIFT 2 -#define BPDU_FLAGS_PROPOSAL 0x02 -#define BPDU_FLAGS_TC 0x01 +#define BPDU_FLAGS_TCACK 0x80 +#define BPDU_FLAGS_AGREEMENT 0x40 +#define BPDU_FLAGS_FORWARDING 0x20 +#define BPDU_FLAGS_LEARNING 0x10 +#define BPDU_FLAGS_PORT_ROLE_MASK 0x0C +#define BPDU_FLAGS_PORT_ROLE_SHIFT 2 +#define BPDU_FLAGS_PROPOSAL 0x02 +#define BPDU_FLAGS_TC 0x01 void proto_register_bpdu(void); void proto_reg_handoff_bpdu(void); @@ -189,17 +189,17 @@ static const value_string protocol_id_vals[] = { { 0, NULL } }; -#define BPDU_PVST_TLV_ORIGVLAN 0 /* Originating VLAN TLV in Cisco (R)PVST+ BPDUs */ +#define BPDU_PVST_TLV_ORIGVLAN 0 /* Originating VLAN TLV in Cisco (R)PVST+ BPDUs */ static const value_string bpdu_pvst_tlv_vals[] = { - { BPDU_PVST_TLV_ORIGVLAN, "Originating VLAN" }, - { 0, NULL } + { BPDU_PVST_TLV_ORIGVLAN, "Originating VLAN" }, + { 0, NULL } }; -#define BPDU_TYPE_CONF 0x00 /* STP Configuration BPDU */ -#define BPDU_TYPE_RST 0x02 /* RST BPDU (or MST) */ -#define BPDU_TYPE_TOPOLOGY_CHANGE 0x80 /* STP TCN (Topology change notify) BPDU */ +#define BPDU_TYPE_CONF 0x00 /* STP Configuration BPDU */ +#define BPDU_TYPE_RST 0x02 /* RST BPDU (or MST) */ +#define BPDU_TYPE_TOPOLOGY_CHANGE 0x80 /* STP TCN (Topology change notify) BPDU */ static const value_string bpdu_type_vals[] = { { BPDU_TYPE_CONF, "Configuration" }, @@ -208,21 +208,21 @@ static const value_string bpdu_type_vals[] = { { 0, NULL } }; -#define PROTO_VERSION_STP 0 -#define PROTO_VERSION_RSTP 2 -#define PROTO_VERSION_MSTP 3 -#define PROTO_VERSION_SPB 4 +#define PROTO_VERSION_STP 0 +#define PROTO_VERSION_RSTP 2 +#define PROTO_VERSION_MSTP 3 +#define PROTO_VERSION_SPB 4 -#define MSTI_FORMAT_UNKNOWN 0 -#define MSTI_FORMAT_IEEE_8021S 1 -#define MSTI_FORMAT_ALTERNATIVE 2 +#define MSTI_FORMAT_UNKNOWN 0 +#define MSTI_FORMAT_IEEE_8021S 1 +#define MSTI_FORMAT_ALTERNATIVE 2 static const value_string version_id_vals[] = { - { PROTO_VERSION_STP, "Spanning Tree" }, - { PROTO_VERSION_RSTP, "Rapid Spanning Tree" }, - { PROTO_VERSION_MSTP, "Multiple Spanning Tree" }, - { PROTO_VERSION_SPB, "Shortest Path Tree" }, - { 0, NULL} + { PROTO_VERSION_STP, "Spanning Tree" }, + { PROTO_VERSION_RSTP, "Rapid Spanning Tree" }, + { PROTO_VERSION_MSTP, "Multiple Spanning Tree" }, + { PROTO_VERSION_SPB, "Shortest Path Tree" }, + { 0, NULL} }; static const value_string role_vals[] = { { 1, "Alternate or Backup" }, @@ -236,8 +236,8 @@ static const char cont_sep[] = ", "; #define APPEND_BOOLEAN_FLAG(flag, item, string) \ if(flag){ \ - if(item) \ - proto_item_append_text(item, string, sep); \ + if(item) \ + proto_item_append_text(item, string, sep); \ sep = cont_sep; \ } @@ -1172,219 +1172,219 @@ proto_register_bpdu(void) static hf_register_info hf[] = { { &hf_bpdu_proto_id, - { "Protocol Identifier", "stp.protocol", - FT_UINT16, BASE_HEX, VALS(protocol_id_vals), 0x0, - NULL, HFILL }}, + { "Protocol Identifier", "stp.protocol", + FT_UINT16, BASE_HEX, VALS(protocol_id_vals), 0x0, + NULL, HFILL }}, { &hf_bpdu_version_id, - { "Protocol Version Identifier", "stp.version", - FT_UINT8, BASE_DEC, VALS(version_id_vals), 0x0, - NULL, HFILL }}, + { "Protocol Version Identifier", "stp.version", + FT_UINT8, BASE_DEC, VALS(version_id_vals), 0x0, + NULL, HFILL }}, { &hf_bpdu_type, - { "BPDU Type", "stp.type", - FT_UINT8, BASE_HEX, VALS(bpdu_type_vals), 0x0, - NULL, HFILL }}, + { "BPDU Type", "stp.type", + FT_UINT8, BASE_HEX, VALS(bpdu_type_vals), 0x0, + NULL, HFILL }}, { &hf_bpdu_flags, - { "BPDU flags", "stp.flags", - FT_UINT8, BASE_HEX, NULL, 0x0, - NULL, HFILL }}, + { "BPDU flags", "stp.flags", + FT_UINT8, BASE_HEX, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_flags_tcack, { "Topology Change Acknowledgment", "stp.flags.tcack", - FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_TCACK, - NULL, HFILL }}, + FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_TCACK, + NULL, HFILL }}, { &hf_bpdu_flags_agreement, - { "Agreement", "stp.flags.agreement", - FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_AGREEMENT, - NULL, HFILL }}, + { "Agreement", "stp.flags.agreement", + FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_AGREEMENT, + NULL, HFILL }}, { &hf_bpdu_flags_forwarding, - { "Forwarding", "stp.flags.forwarding", - FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_FORWARDING, - NULL, HFILL }}, + { "Forwarding", "stp.flags.forwarding", + FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_FORWARDING, + NULL, HFILL }}, { &hf_bpdu_flags_learning, - { "Learning", "stp.flags.learning", - FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_LEARNING, - NULL, HFILL }}, + { "Learning", "stp.flags.learning", + FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_LEARNING, + NULL, HFILL }}, { &hf_bpdu_flags_port_role, - { "Port Role", "stp.flags.port_role", - FT_UINT8, BASE_DEC, VALS(role_vals), BPDU_FLAGS_PORT_ROLE_MASK, - NULL, HFILL }}, + { "Port Role", "stp.flags.port_role", + FT_UINT8, BASE_DEC, VALS(role_vals), BPDU_FLAGS_PORT_ROLE_MASK, + NULL, HFILL }}, { &hf_bpdu_flags_proposal, - { "Proposal", "stp.flags.proposal", - FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_PROPOSAL, - NULL, HFILL }}, + { "Proposal", "stp.flags.proposal", + FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_PROPOSAL, + NULL, HFILL }}, { &hf_bpdu_flags_tc, - { "Topology Change", "stp.flags.tc", - FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_TC, - NULL, HFILL }}, + { "Topology Change", "stp.flags.tc", + FT_BOOLEAN, 8, TFS(&tfs_yes_no), BPDU_FLAGS_TC, + NULL, HFILL }}, { &hf_bpdu_root_prio, - { "Root Bridge Priority", "stp.root.prio", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Root Bridge Priority", "stp.root.prio", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_root_sys_id_ext, - { "Root Bridge System ID Extension", "stp.root.ext", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Root Bridge System ID Extension", "stp.root.ext", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_root_mac, - { "Root Bridge System ID", "stp.root.hw", - FT_ETHER, BASE_NONE, NULL, 0x0, - NULL, HFILL }}, + { "Root Bridge System ID", "stp.root.hw", + FT_ETHER, BASE_NONE, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_root_cost, - { "Root Path Cost", "stp.root.cost", - FT_UINT32, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Root Path Cost", "stp.root.cost", + FT_UINT32, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_bridge_prio, - { "Bridge Priority", "stp.bridge.prio", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Bridge Priority", "stp.bridge.prio", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_bridge_sys_id_ext, - { "Bridge System ID Extension", "stp.bridge.ext", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Bridge System ID Extension", "stp.bridge.ext", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_bridge_mac, - { "Bridge System ID", "stp.bridge.hw", - FT_ETHER, BASE_NONE, NULL, 0x0, - NULL, HFILL }}, + { "Bridge System ID", "stp.bridge.hw", + FT_ETHER, BASE_NONE, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_port_id, - { "Port identifier", "stp.port", - FT_UINT16, BASE_HEX, NULL, 0x0, - NULL, HFILL }}, + { "Port identifier", "stp.port", + FT_UINT16, BASE_HEX, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_msg_age, - { "Message Age", "stp.msg_age", - FT_DOUBLE, BASE_NONE, NULL, 0x0, - NULL, HFILL }}, + { "Message Age", "stp.msg_age", + FT_DOUBLE, BASE_NONE, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_max_age, - { "Max Age", "stp.max_age", - FT_DOUBLE, BASE_NONE, NULL, 0x0, - NULL, HFILL }}, + { "Max Age", "stp.max_age", + FT_DOUBLE, BASE_NONE, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_hello_time, - { "Hello Time", "stp.hello", - FT_DOUBLE, BASE_NONE, NULL, 0x0, - NULL, HFILL }}, + { "Hello Time", "stp.hello", + FT_DOUBLE, BASE_NONE, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_forward_delay, - { "Forward Delay", "stp.forward", - FT_DOUBLE, BASE_NONE, NULL, 0x0, - NULL, HFILL }}, + { "Forward Delay", "stp.forward", + FT_DOUBLE, BASE_NONE, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_version_1_length, - { "Version 1 Length", "stp.version_1_length", - FT_UINT8, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Version 1 Length", "stp.version_1_length", + FT_UINT8, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_pvst_tlvtype, - { "Type", "stp.pvst.tlvtype", - FT_UINT16, BASE_HEX, VALS(bpdu_pvst_tlv_vals), 0x0, - NULL, HFILL }}, + { "Type", "stp.pvst.tlvtype", + FT_UINT16, BASE_HEX, VALS(bpdu_pvst_tlv_vals), 0x0, + NULL, HFILL }}, { &hf_bpdu_pvst_tlvlength, - { "Length", "stp.pvst.tlvlen", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Length", "stp.pvst.tlvlen", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_pvst_tlv_origvlan, - { "Originating VLAN", "stp.pvst.origvlan", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Originating VLAN", "stp.pvst.origvlan", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_pvst_tlvvalue, - { "Value", "stp.pvst.tlvval", - FT_BYTES, BASE_NONE, NULL, 0x0, - NULL, HFILL }}, + { "Value", "stp.pvst.tlvval", + FT_BYTES, BASE_NONE, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_version_3_length, - { "Version 3 Length", "mstp.version_3_length", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Version 3 Length", "mstp.version_3_length", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_mst_config_format_selector, - { "MST Config ID format selector", "mstp.config_format_selector", - FT_UINT8, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "MST Config ID format selector", "mstp.config_format_selector", + FT_UINT8, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_mst_config_name, - { "MST Config name", "mstp.config_name", - FT_STRINGZ, BASE_NONE, NULL, 0x0, - NULL, HFILL }}, + { "MST Config name", "mstp.config_name", + FT_STRINGZ, BASE_NONE, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_mst_config_revision_level, - { "MST Config revision", "mstp.config_revision_level", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "MST Config revision", "mstp.config_revision_level", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_mst_config_digest, - { "MST Config digest", "mstp.config_digest", - FT_BYTES, BASE_NONE, NULL, 0x0, - NULL, HFILL }}, + { "MST Config digest", "mstp.config_digest", + FT_BYTES, BASE_NONE, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_cist_internal_root_path_cost, - { "CIST Internal Root Path Cost", "mstp.cist_internal_root_path_cost", - FT_UINT32, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "CIST Internal Root Path Cost", "mstp.cist_internal_root_path_cost", + FT_UINT32, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_cist_bridge_prio, - { "CIST Bridge Priority", "mstp.cist_bridge.prio", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "CIST Bridge Priority", "mstp.cist_bridge.prio", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_cist_bridge_sys_id_ext, - { "CIST Bridge Identifier System ID Extension", "mstp.cist_bridge.ext", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "CIST Bridge Identifier System ID Extension", "mstp.cist_bridge.ext", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_cist_bridge_mac, - { "CIST Bridge Identifier System ID", "mstp.cist_bridge.hw", - FT_ETHER, BASE_NONE, NULL, 0x0, - NULL, HFILL }}, + { "CIST Bridge Identifier System ID", "mstp.cist_bridge.hw", + FT_ETHER, BASE_NONE, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_cist_remaining_hops, - { "CIST Remaining hops", "mstp.cist_remaining_hops", - FT_UINT8, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "CIST Remaining hops", "mstp.cist_remaining_hops", + FT_UINT8, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_msti_flags, - { "MSTI flags", "mstp.msti.flags", - FT_UINT8, BASE_HEX, NULL, 0x0, - NULL, HFILL }}, + { "MSTI flags", "mstp.msti.flags", + FT_UINT8, BASE_HEX, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_msti_regional_root_mac, - { "Regional Root", "mstp.msti.root.hw", - FT_ETHER, BASE_NONE, NULL, 0x0, - NULL, HFILL }}, + { "Regional Root", "mstp.msti.root.hw", + FT_ETHER, BASE_NONE, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_msti_internal_root_path_cost, - { "Internal root path cost", "mstp.msti.root_cost", - FT_UINT32, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Internal root path cost", "mstp.msti.root_cost", + FT_UINT32, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_msti_bridge_identifier_priority, - { "Bridge Identifier Priority", "mstp.msti.bridge_priority", - FT_UINT8, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Bridge Identifier Priority", "mstp.msti.bridge_priority", + FT_UINT8, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_msti_port_identifier_priority, - { "Port identifier priority", "mstp.msti.port_priority", - FT_UINT8, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Port identifier priority", "mstp.msti.port_priority", + FT_UINT8, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_msti_port_id, - { "Port identifier", "mstp.msti.port", - FT_UINT16, BASE_HEX, NULL, 0x0, - NULL, HFILL }}, + { "Port identifier", "mstp.msti.port", + FT_UINT16, BASE_HEX, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_msti_remaining_hops, - { "Remaining hops", "mstp.msti.remaining_hops", - FT_UINT8, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, - { &hf_bpdu_version_4_length, - { "Version 4 Length", "mstp.version_4_length", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, + { "Remaining hops", "mstp.msti.remaining_hops", + FT_UINT8, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, + { &hf_bpdu_version_4_length, + { "Version 4 Length", "mstp.version_4_length", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, { &hf_bpdu_spt_config_format_selector, - { "SPT Config ID format selector", "mstp.config_format_selector", - FT_UINT8, BASE_DEC, NULL, 0x0, - NULL, HFILL }}, - { &hf_bpdu_spt_config_name, - {"SPT Config name", "mstp.config_name", - FT_STRINGZ, BASE_NONE, NULL, 0x0, - NULL, HFILL } }, - { &hf_bpdu_spt_config_revision_level, - { "SPT Config revision", "mstp.config_revision_level", - FT_UINT16, BASE_DEC, NULL, 0x0, - NULL, HFILL } }, - { &hf_bpdu_spt_config_digest, - { "SPT Config digest", "mstp.config_digest", - FT_BYTES, BASE_NONE, NULL, 0x0, - NULL, HFILL } }, - { &hf_bpdu_flags_agree_num, - { "Agreement Number", "mstp.agree_flags.agreement_num", - FT_UINT8, BASE_DEC, NULL, 0x03, - NULL, HFILL } }, - { &hf_bpdu_flags_dagree_num, - { "Disagreement Number", "mstp.agree_flags.dagreement_num", - FT_UINT8, BASE_DEC, NULL, 0x0C, - NULL, HFILL } }, - { &hf_bpdu_flags_agree_valid, - { "Agreement Valid Flag", "mstp.agree_flags.agreement_valid", - FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x10, - NULL, HFILL } }, - { &hf_bpdu_flags_restricted_role, - { "Restricted Role", "mstp.agree_flags.rest_role", + { "SPT Config ID format selector", "mstp.config_format_selector", + FT_UINT8, BASE_DEC, NULL, 0x0, + NULL, HFILL }}, + { &hf_bpdu_spt_config_name, + {"SPT Config name", "mstp.config_name", + FT_STRINGZ, BASE_NONE, NULL, 0x0, + NULL, HFILL } }, + { &hf_bpdu_spt_config_revision_level, + { "SPT Config revision", "mstp.config_revision_level", + FT_UINT16, BASE_DEC, NULL, 0x0, + NULL, HFILL } }, + { &hf_bpdu_spt_config_digest, + { "SPT Config digest", "mstp.config_digest", + FT_BYTES, BASE_NONE, NULL, 0x0, + NULL, HFILL } }, + { &hf_bpdu_flags_agree_num, + { "Agreement Number", "mstp.agree_flags.agreement_num", + FT_UINT8, BASE_DEC, NULL, 0x03, + NULL, HFILL } }, + { &hf_bpdu_flags_dagree_num, + { "Disagreement Number", "mstp.agree_flags.dagreement_num", + FT_UINT8, BASE_DEC, NULL, 0x0C, + NULL, HFILL } }, + { &hf_bpdu_flags_agree_valid, + { "Agreement Valid Flag", "mstp.agree_flags.agreement_valid", + FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x10, + NULL, HFILL } }, + { &hf_bpdu_flags_restricted_role, + { "Restricted Role", "mstp.agree_flags.rest_role", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x20, NULL, HFILL } }, { &hf_bpdu_spt_agreement_digest, @@ -1468,3 +1468,16 @@ proto_reg_handoff_bpdu(void) bpdu_handle = find_dissector("bpdu_cisco"); dissector_add_uint("llc.cisco_pid", 0x010b, bpdu_handle); /* Handle Cisco's (R)PVST+ TLV extensions */ } + +/* + * Editor modelines - http://www.wireshark.org/tools/modelines.html + * + * Local Variables: + * c-basic-offset: 2 + * tab-width: 8 + * indent-tabs-mode: nil + * End: + * + * ex: set shiftwidth=2 tabstop=8 expandtab: + * :indentSize=2:tabSize=8:noTabs=true: + */ |