forked from osmocom/wireshark
Remove "Cisco MDS-specific" fields from packet_info. 2 of the 3 fields were used strictly for columns that are considered "deprecated" and I think the third could be put in that category as well.
I assume the column enumerations haven't already been removed because of legacy "indexing issues", but if I'm wrong, we should definitely remove the columns altogether. Could also see renaming columns to DEPRECATED_[X]. svn path=/trunk/; revision=52910
This commit is contained in:
parent
233c409184
commit
3ead3a994a
|
@ -1813,11 +1813,6 @@ col_fill_in(packet_info *pinfo, const gboolean fill_col_exprs, const gboolean fi
|
|||
col_set_port(pinfo, i, FALSE, FALSE, fill_col_exprs);
|
||||
break;
|
||||
|
||||
case COL_VSAN:
|
||||
guint32_to_str_buf(pinfo->vsan, pinfo->cinfo->col_buf[i], COL_MAX_LEN);
|
||||
pinfo->cinfo->col_data[i] = pinfo->cinfo->col_buf[i];
|
||||
break;
|
||||
|
||||
case NUM_COL_FMTS: /* keep compiler happy - shouldn't get here */
|
||||
g_assert_not_reached();
|
||||
break;
|
||||
|
@ -2025,13 +2020,13 @@ col_fill_fdata(packet_info *pinfo)
|
|||
set_circuit_id(pinfo);
|
||||
break;
|
||||
case COL_SRCIDX:
|
||||
fdata->col_text[i] = (gchar *)(GUINT_TO_POINTER((guint)pinfo->src_idx));
|
||||
fdata->col_text[i] = (gchar *)-1; /* !! DEPRECATED !!*/
|
||||
break;
|
||||
case COL_DSTIDX:
|
||||
fdata->col_text[i] = (gchar *)(GUINT_TO_POINTER((guint)pinfo->dst_idx));
|
||||
fdata->col_text[i] = (gchar *)-1; /* !! DEPRECATED !!*/
|
||||
break;
|
||||
case COL_VSAN:
|
||||
fdata->col_text[i] = (gchar *)(GUINT_TO_POINTER((guint)pinfo->vsan));
|
||||
fdata->col_text[i] = (gchar *)-1; /* !! DEPRECATED !!*/
|
||||
break;
|
||||
|
||||
case NUM_COL_FMTS: /* keep compiler happy - shouldn't get here */
|
||||
|
|
|
@ -48,9 +48,9 @@ col_format_to_string(const gint fmt) {
|
|||
"%Yt", /* 1) COL_ABS_DATE_TIME */
|
||||
"%At", /* 2) COL_ABS_TIME */
|
||||
"%c", /* 3) COL_CIRCUIT_ID */
|
||||
"%Xd", /* 4) COL_DSTIDX */
|
||||
"%Xs", /* 5) COL_SRCIDX */
|
||||
"%V", /* 6) COL_VSAN */
|
||||
"%Xd", /* 4) COL_DSTIDX - !! DEPRECATED !!*/
|
||||
"%Xs", /* 5) COL_SRCIDX - !! DEPRECATED !!*/
|
||||
"%V", /* 6) COL_VSAN - !! DEPRECATED !!*/
|
||||
"%B", /* 7) COL_CUMULATIVE_BYTES */
|
||||
"%Cus", /* 8) COL_CUSTOM */
|
||||
"%y", /* 9) COL_DCE_CALL */
|
||||
|
@ -525,7 +525,7 @@ get_column_longest_string(const gint format)
|
|||
break;
|
||||
case COL_SRCIDX:
|
||||
case COL_DSTIDX:
|
||||
return "0000000";
|
||||
return "00000000";
|
||||
break;
|
||||
case COL_VSAN:
|
||||
return "000000";
|
||||
|
|
|
@ -225,7 +225,6 @@ dissect_brdwlk(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
|
||||
col_clear(pinfo->cinfo, COL_INFO);
|
||||
|
||||
pinfo->vsan = (tvb_get_ntohs(tvb, offset) & 0xFFF);
|
||||
sof = (tvb_get_guint8(tvb, offset) & 0xF0) >> 4;
|
||||
|
||||
if ((sof == FCM_DELIM_SOFI3) || (sof == FCM_DELIM_SOFI2) || (sof == FCM_DELIM_SOFI1)
|
||||
|
|
|
@ -729,7 +729,6 @@ dissect_fc_helper (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gboolean
|
|||
* standardized in FC-FS-2. See section 10.2.4.
|
||||
*/
|
||||
if (fchdr.r_ctl == FC_RCTL_VFT) {
|
||||
pinfo->vsan = (tvb_get_ntohs(tvb, offset + 2) >> 1) & 0xfff;
|
||||
vft_offset = offset;
|
||||
offset += 8;
|
||||
fchdr.r_ctl = tvb_get_guint8 (tvb, offset);
|
||||
|
|
|
@ -142,8 +142,6 @@ dissect_mdshdr(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
guint pktlen;
|
||||
tvbuff_t *next_tvb;
|
||||
guint8 sof, eof;
|
||||
guint16 vsan;
|
||||
guint8 span_id;
|
||||
int trailer_start = 0; /*0 means "no trailer found"*/
|
||||
|
||||
col_set_str(pinfo->cinfo, COL_PROTOCOL, "MDS Header");
|
||||
|
@ -152,8 +150,6 @@ dissect_mdshdr(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
|
||||
sof = tvb_get_guint8(tvb, offset+MDSHDR_SOF_OFFSET) & 0x0F;
|
||||
pktlen = tvb_get_ntohs(tvb, offset+MDSHDR_PKTLEN_OFFSET) & 0x1FFF;
|
||||
vsan = tvb_get_ntohs(tvb, offset+MDSHDR_VSAN_OFFSET) & 0x0FFF;
|
||||
span_id = (tvb_get_ntohs(tvb, offset+MDSHDR_VSAN_OFFSET) & 0xF000) >> 12;
|
||||
|
||||
/* The Mdshdr trailer is at the end of the frame */
|
||||
if ((tvb_length(tvb) >= (MDSHDR_HEADER_SIZE + pktlen))
|
||||
|
@ -168,9 +164,6 @@ dissect_mdshdr(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
eof = MDSHDR_EOF_UNKNOWN;
|
||||
}
|
||||
|
||||
pinfo->src_idx = (tvb_get_ntohs(tvb, MDSHDR_SIDX_OFFSET) & 0x3FF);
|
||||
pinfo->dst_idx = (tvb_get_ntohs(tvb, MDSHDR_DIDX_OFFSET) & 0xFFC) >> 2;
|
||||
pinfo->vsan = vsan;
|
||||
pinfo->sof_eof = 0;
|
||||
|
||||
if ((sof == MDSHDR_SOFi3) || (sof == MDSHDR_SOFi2) || (sof == MDSHDR_SOFi1)
|
||||
|
@ -215,7 +208,7 @@ dissect_mdshdr(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
|
|||
MDSHDR_SIZE_INT16, ENC_BIG_ENDIAN);
|
||||
hidden_item = proto_tree_add_uint(mdshdr_tree_hdr, hf_mdshdr_span,
|
||||
tvb, MDSHDR_VSAN_OFFSET,
|
||||
MDSHDR_SIZE_BYTE, span_id);
|
||||
MDSHDR_SIZE_INT16, ENC_BIG_ENDIAN);
|
||||
PROTO_ITEM_SET_HIDDEN(hidden_item);
|
||||
|
||||
/* Add Mdshdr Trailer part */
|
||||
|
@ -279,7 +272,7 @@ proto_register_mdshdr(void)
|
|||
{"EOF", "mdshdr.eof", FT_UINT8, BASE_DEC, VALS(eof_vals), 0x0, NULL, HFILL}},
|
||||
|
||||
{ &hf_mdshdr_span,
|
||||
{"SPAN Frame", "mdshdr.span", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL}},
|
||||
{"SPAN Frame", "mdshdr.span", FT_UINT16, BASE_DEC, NULL, 0xF000, NULL, HFILL}},
|
||||
|
||||
{ &hf_mdshdr_fccrc,
|
||||
{"CRC", "mdshdr.crc", FT_UINT32, BASE_HEX, NULL, 0x0, NULL, HFILL}},
|
||||
|
|
|
@ -150,9 +150,6 @@ typedef struct _packet_info {
|
|||
* Bit 2 set if SOFf
|
||||
* Bit 1 set if first frame in sequence
|
||||
*/
|
||||
guint16 src_idx; /**< Source port index (Cisco MDS-specific) */
|
||||
guint16 dst_idx; /**< Dest port index (Cisco MDS-specific) */
|
||||
guint16 vsan; /**< Fibre channel/Cisco MDS-specific */
|
||||
|
||||
/* Extra data for DCERPC handling and tracking of context ids */
|
||||
guint16 dcectxid; /**< Context ID (DCERPC-specific) */
|
||||
|
|
Loading…
Reference in New Issue