can: kvaser_usb: Simplify struct kvaser_cmd_cardinfo
authorJimmy Assarsson <jimmyassarsson@gmail.com>
Fri, 16 Feb 2018 13:41:06 +0000 (14:41 +0100)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Fri, 27 Jul 2018 08:40:19 +0000 (10:40 +0200)
serial_number_high can be removed from the struct since it is never used in
the USBcan II firmware.

Signed-off-by: Jimmy Assarsson <jimmyassarsson@gmail.com>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/usb/kvaser_usb/kvaser_usb_leaf.c

index 70ffff724a2682bdc01b2646854cf6364fe86d03..07d2f3aa2c026c99e0358266ff781e8d893c75a5 100644 (file)
@@ -125,16 +125,8 @@ struct kvaser_cmd_simple {
 struct kvaser_cmd_cardinfo {
        u8 tid;
        u8 nchannels;
-       union {
-               struct {
-                       __le32 serial_number;
-                       __le32 padding;
-               } __packed leaf0;
-               struct {
-                       __le32 serial_number_low;
-                       __le32 serial_number_high;
-               } __packed usbcan0;
-       } __packed;
+       __le32 serial_number;
+       __le32 padding0;
        __le32 clock_resolution;
        __le32 mfgdate;
        u8 ean[8];
@@ -147,7 +139,7 @@ struct kvaser_cmd_cardinfo {
                        u8 padding;
                } __packed usbcan1;
        } __packed;
-       __le16 padding;
+       __le16 padding1;
 } __packed;
 
 struct leaf_cmd_softinfo {