From ca3b4a79b2d4236ea4b44ec5784ca1880d720c29 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tomasz=20Mo=C5=84?= Date: Mon, 20 Jul 2020 19:48:57 +0200 Subject: FTDI MPSSE: Dissect CPUMode read response data MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Ping-Bug: 11743 Change-Id: I6c5b2d1b28062998d485e2d709f950b7b99e89cd Reviewed-on: https://code.wireshark.org/review/37914 Petri-Dish: Tomasz Moń Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman --- epan/dissectors/packet-ftdi-mpsse.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'epan/dissectors/packet-ftdi-mpsse.c') diff --git a/epan/dissectors/packet-ftdi-mpsse.c b/epan/dissectors/packet-ftdi-mpsse.c index 0bcb4ac1df..d37138fd74 100644 --- a/epan/dissectors/packet-ftdi-mpsse.c +++ b/epan/dissectors/packet-ftdi-mpsse.c @@ -950,6 +950,13 @@ dissect_read_data_bits_response(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tre return 1; } +static gint +dissect_cpumode_response(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, gint offset) +{ + proto_tree_add_item(tree, hf_mpsse_cpumode_data, tvb, offset, 1, ENC_LITTLE_ENDIAN); + return 1; +} + static gint dissect_non_data_shifting_command_response(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, gint offset, command_data_t *cmd_data) { @@ -967,6 +974,9 @@ dissect_non_data_shifting_command_response(tvbuff_t *tvb, packet_info *pinfo, pr case CMD_READ_DATA_BITS_HIGH_BYTE: pin_prefix = get_data_bit_pin_prefix(TRUE, &cmd_data->mpsse_info, &num_pins, &signal_names); return dissect_read_data_bits_response(tvb, pinfo, tree, offset, *signal_names, pin_prefix, num_pins); + case CMD_CPUMODE_READ_SHORT_ADDR: + case CMD_CPUMODE_READ_EXT_ADDR: + return dissect_cpumode_response(tvb, pinfo, tree, offset); default: return 0; } -- cgit v1.2.3