]> Git Repo - linux.git/commitdiff
usb: pd: fix the offset for SVID specific commands
authorHeikki Krogerus <[email protected]>
Mon, 18 Dec 2017 14:03:03 +0000 (17:03 +0300)
committerGreg Kroah-Hartman <[email protected]>
Tue, 19 Dec 2017 10:47:23 +0000 (11:47 +0100)
The SVID specific commands in the Command field of the
Structured VDM Header start from 16, not 10. Changing the
value used in VDO_CMD_VENDOR() macro from 10 to 0x10.

Signed-off-by: Heikki Krogerus <[email protected]>
Reviewed-by: Guenter Roeck <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
include/linux/usb/pd_vdo.h

index d92259f8de0a835ad2a634d079e6d08ab327f654..2b64d23ace5c8f5ab327a31338f34840eae6d0aa 100644 (file)
@@ -65,7 +65,7 @@
 #define CMD_EXIT_MODE          5
 #define CMD_ATTENTION          6
 
-#define VDO_CMD_VENDOR(x)    (((10 + (x)) & 0x1f))
+#define VDO_CMD_VENDOR(x)    (((0x10 + (x)) & 0x1f))
 
 /* ChromeOS specific commands */
 #define VDO_CMD_VERSION                VDO_CMD_VENDOR(0)
This page took 0.063149 seconds and 4 git commands to generate.