Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1417464

[RFC v4 3/7] extcon: Add raw VBUS and ID cable states

From Krzysztof Kozlowski <k.kozlowski@samsung.com>
Newsgroups linux.kernel
Subject [RFC v4 3/7] extcon: Add raw VBUS and ID cable states
Date 2016-06-08 16:00 +0200
Message-ID <rHMbw-ST-11@gated-at.bofh.it> (permalink)
References <rHM1P-Pq-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


The USB controller driver might want to receive the changes for VBUS and
ID pins so it could properly handle USB OTG. Add new cable states for
that purpose.

Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>

---

Previous discussion:
http://lkml.kernel.org/g/<1427980385-21285-3-git-send-email-r.baldyga@samsung.com>
---
 drivers/extcon/extcon.c | 3 +++
 include/linux/extcon.h  | 8 +++++++-
 2 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/drivers/extcon/extcon.c b/drivers/extcon/extcon.c
index 21a123cadf78..aa02d94e8a78 100644
--- a/drivers/extcon/extcon.c
+++ b/drivers/extcon/extcon.c
@@ -74,6 +74,9 @@ static const char *extcon_name[] =  {
 	[EXTCON_JIG]			= "JIG",
 	[EXTCON_MECHANICAL]		= "MECHANICAL",
 
+	[EXTCON_USB_ID]			= "USB-ID",
+	[EXTCON_USB_VBUS]		= "USB-VBUS",
+
 	NULL,
 };
 
diff --git a/include/linux/extcon.h b/include/linux/extcon.h
index 7abf674c388c..126ae41b84fd 100644
--- a/include/linux/extcon.h
+++ b/include/linux/extcon.h
@@ -66,7 +66,13 @@
 #define EXTCON_JIG		61
 #define EXTCON_MECHANICAL	62
 
-#define EXTCON_NUM		63
+/* Raw status, useful for USB controllers */
+#define EXTCON_USB_ID		63
+#define EXTCON_USB_VBUS		64
+
+#define EXTCON_NUM		65
+
+
 
 struct extcon_cable;
 
-- 
1.9.1

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[RFC v4 0/7] extcon: usb-gpio: fixes and improvements Krzysztof Kozlowski <k.kozlowski@samsung.com> - 2016-06-08 15:50 +0200
  [RFC v4 2/7] Revert "extcon: usb-gpio: switch to use pm wakeirq apis" Krzysztof Kozlowski <k.kozlowski@samsung.com> - 2016-06-08 15:50 +0200
    Re: [RFC v4 2/7] Revert "extcon: usb-gpio: switch to use pm wakeirq  apis" Roger Quadros <rogerq@ti.com> - 2016-06-09 10:10 +0200
      Re: [RFC v4 2/7] Revert  "extcon: usb-gpio: switch to use pm wakeirq apis" Krzysztof Kozlowski <k.kozlowski@samsung.com> - 2016-06-09 10:20 +0200
        Re: [RFC v4 2/7] Revert "extcon: usb-gpio: switch to use pm wakeirq  apis" Roger Quadros <rogerq@ti.com> - 2016-06-09 10:30 +0200
  [RFC v4 6/7] ARM: exynos_defconfig: Enable EXTCON_USB_GPIO for Odroid  XU3 USB OTG Krzysztof Kozlowski <k.kozlowski@samsung.com> - 2016-06-08 15:50 +0200
  [RFC v4 7/7] ARM: dts: exynos: Add extcon-usb-gpio node for Odroid XU3 Krzysztof Kozlowski <k.kozlowski@samsung.com> - 2016-06-08 15:50 +0200
  [RFC v4 1/7] Documentation: extcon: usb-gpio: update usb-gpio binding  description Krzysztof Kozlowski <k.kozlowski@samsung.com> - 2016-06-08 15:50 +0200
    Re: [RFC v4 1/7] Documentation: extcon: usb-gpio: update usb-gpio  binding description Rob Herring <robh@kernel.org> - 2016-06-10 16:10 +0200
  [RFC v4 3/7] extcon: Add raw VBUS and ID cable states Krzysztof Kozlowski <k.kozlowski@samsung.com> - 2016-06-08 16:00 +0200
  [RFC v4 4/7] extcon: usb-gpio: Add support for VBUS detection Krzysztof Kozlowski <k.kozlowski@samsung.com> - 2016-06-08 16:00 +0200
    Re: [RFC v4 4/7] extcon: usb-gpio: Add support for VBUS detection Roger Quadros <rogerq@ti.com> - 2016-06-09 10:40 +0200
      Re: [RFC v4 4/7] extcon: usb-gpio: Add support for VBUS detection Krzysztof Kozlowski <k.kozlowski@samsung.com> - 2016-06-09 10:50 +0200
        Re: [RFC v4 4/7] extcon: usb-gpio: Add support for VBUS detection Roger Quadros <rogerq@ti.com> - 2016-06-09 14:20 +0200
      Re: [RFC v4 4/7] extcon: usb-gpio: Add support for VBUS detection Roger Quadros <rogerq@ti.com> - 2016-06-09 10:50 +0200
  Re: [RFC v4 0/7] extcon: usb-gpio: fixes and improvements Chanwoo Choi <cw00.choi@samsung.com> - 2016-06-09 10:40 +0200
    Re: [RFC v4 0/7] extcon: usb-gpio: fixes and improvements Krzysztof Kozlowski <k.kozlowski@samsung.com> - 2016-06-09 10:40 +0200
      Re: [RFC v4 0/7] extcon: usb-gpio: fixes and improvements Chanwoo Choi <cw00.choi@samsung.com> - 2016-06-09 11:40 +0200

csiph-web