extcon: Add EXTCON_USB_VBUS_EN for USB Type-C
authorBin Yang <yangbin@rock-chips.com>
Fri, 23 Sep 2016 02:51:58 +0000 (10:51 +0800)
committerHuang, Tao <huangtao@rock-chips.com>
Fri, 7 Oct 2016 07:42:26 +0000 (15:42 +0800)
Add the new extcon EXTCON_USB_VBUS_EN to enable
vbus output.

Change-Id: I83fb75b2a82ad617dc292967bb4917bbfbcb84cb
Signed-off-by: Bin Yang <yangbin@rock-chips.com>
drivers/extcon/extcon.c
include/linux/extcon.h

index 519ac5c8bed14e3e77af3c0320fe1c9ca522f182..f21ab75fdbabba2da25de692362fe7285e6cc8f8 100644 (file)
@@ -61,6 +61,11 @@ struct __extcon_info {
                .id = EXTCON_USB_HOST,
                .name = "USB_HOST",
        },
+       [EXTCON_USB_VBUS_EN] = {
+               .type = EXTCON_TYPE_USB,
+               .id = EXTCON_USB_VBUS_EN,
+               .name = "USB_VBUS_EN",
+       },
 
        /* Charging external connector */
        [EXTCON_CHG_USB_SDP] = {
index 9147c421fb05ecacbf6dfc1777495c2c9d50af1b..dd1f925d0e0150c59825bae9f59e74a12b17ca06 100644 (file)
@@ -45,6 +45,7 @@
 /* USB external connector */
 #define EXTCON_USB             1
 #define EXTCON_USB_HOST                2
+#define EXTCON_USB_VBUS_EN     3
 
 /* Charging external connector */
 #define EXTCON_CHG_USB_SDP     5       /* Standard Downstream Port */