From f8c959dc8c4e46f733dbd4dcc954e6fa3304b248 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stig=20Bj=C3=B8rlykke?= Date: Mon, 22 Jun 2009 04:58:08 +0000 Subject: From Kovarththanan Rajaratnam: Move header field info declarations into function scope. This is the first step. Another patch will be submitted which actually scrubs the header field info declarations (remove empty blurbs, etc.) svn path=/trunk/; revision=28797 --- plugins/wimax/msg_fpc.c | 83 ++++++++++++++++++++++++------------------------- 1 file changed, 41 insertions(+), 42 deletions(-) (limited to 'plugins/wimax/msg_fpc.c') diff --git a/plugins/wimax/msg_fpc.c b/plugins/wimax/msg_fpc.c index 39aa88c648..540b431534 100644 --- a/plugins/wimax/msg_fpc.c +++ b/plugins/wimax/msg_fpc.c @@ -63,58 +63,57 @@ static gint hf_fpc_power_adjust = -1; static gint hf_fpc_power_measurement_frame = -1; static gint hf_fpc_invalid_tlv = -1; -/* FPC fields display */ -static hf_register_info hf[] = +/* Register Wimax Mac Payload Protocol and Dissector */ +void proto_register_mac_mgmt_msg_fpc(void) { + /* FPC fields display */ + static hf_register_info hf[] = { - &hf_fpc_message_type, { - "MAC Management Message Type", "wmx.macmgtmsgtype.fpc", - FT_UINT8, BASE_DEC, NULL, 0x0, - "", HFILL - } - }, - { - &hf_fpc_basic_cid, + &hf_fpc_message_type, + { + "MAC Management Message Type", "wmx.macmgtmsgtype.fpc", + FT_UINT8, BASE_DEC, NULL, 0x0, + "", HFILL + } + }, { - "Basic CID", "wmx.fpc.basic_cid", - FT_UINT16, BASE_DEC, NULL, 0x0, "", HFILL - } - }, - { - &hf_fpc_invalid_tlv, + &hf_fpc_basic_cid, + { + "Basic CID", "wmx.fpc.basic_cid", + FT_UINT16, BASE_DEC, NULL, 0x0, "", HFILL + } + }, { - "Invalid TLV", "wmx.fpc.invalid_tlv", - FT_BYTES, BASE_HEX, NULL, 0, "", HFILL - } - }, - { - &hf_fpc_number_of_stations, + &hf_fpc_invalid_tlv, + { + "Invalid TLV", "wmx.fpc.invalid_tlv", + FT_BYTES, BASE_HEX, NULL, 0, "", HFILL + } + }, { - "Number of stations", "wmx.fpc.number_stations", - FT_UINT8, BASE_DEC, NULL, 0x0, "", HFILL - } - }, - { - &hf_fpc_power_adjust, + &hf_fpc_number_of_stations, + { + "Number of stations", "wmx.fpc.number_stations", + FT_UINT8, BASE_DEC, NULL, 0x0, "", HFILL + } + }, { - "Power Adjust. Signed change in power level (incr of 0.25dB) that the SS shall apply to its current power setting", "wmx.fpc.power_adjust", - FT_FLOAT, BASE_DEC, NULL, 0x0, "", HFILL - } - }, - { - &hf_fpc_power_measurement_frame, + &hf_fpc_power_adjust, + { + "Power Adjust. Signed change in power level (incr of 0.25dB) that the SS shall apply to its current power setting", "wmx.fpc.power_adjust", + FT_FLOAT, BASE_DEC, NULL, 0x0, "", HFILL + } + }, { - "Power measurement frame. The 8 LSB of the frame number in which the BS measured the power corrections referred to in the message", "wmx.fpc.power_measurement_frame", - FT_INT8, BASE_DEC, NULL, 0x0, "", HFILL + &hf_fpc_power_measurement_frame, + { + "Power measurement frame. The 8 LSB of the frame number in which the BS measured the power corrections referred to in the message", "wmx.fpc.power_measurement_frame", + FT_INT8, BASE_DEC, NULL, 0x0, "", HFILL + } } - } -}; - + }; -/* Register Wimax Mac Payload Protocol and Dissector */ -void proto_register_mac_mgmt_msg_fpc(void) -{ if (proto_mac_mgmt_msg_fpc_decoder == -1) { proto_mac_mgmt_msg_fpc_decoder = proto_register_protocol ( "WiMax FPC Message", /* name */ -- cgit v1.2.1