summaryrefslogtreecommitdiffstats
path: root/drivers/usb/renesas_usbhs/common.h
diff options
context:
space:
mode:
authorSergei Shtylyov <sergei.shtylyov@cogentembedded.com>2014-12-16 01:42:13 +0300
committerFelipe Balbi <balbi@ti.com>2015-01-12 15:36:28 -0600
commitd7b3968dbcbb620acf92164752031fa276917db9 (patch)
treed0be8a758d4d321643680beb331e91cf8dcf9bae /drivers/usb/renesas_usbhs/common.h
parent6d713c1531638df8d459d248a89948318cbeec4c (diff)
downloadblackbird-obmc-linux-d7b3968dbcbb620acf92164752031fa276917db9.tar.gz
blackbird-obmc-linux-d7b3968dbcbb620acf92164752031fa276917db9.zip
usb: renesas_usbhs: add OTG ID signal sensing
On the Renesas R8A7791 SoC based boards there's MAX3355 USB OTG chip and mini-AB USB connector corresponding to USB port 0 driven either by EHCI/OHCI or Renesas USBHS gadget controller. And we'd like the host/gadget drivers to work based on the cable type connected. An 'extcon' driver for MAX3355 has been written, so we only need to bind to it via device tree which I'm doing in this patch. (Perhaps, it would also make sense to use OTG HNP when the USBHS host mode is active and a B-cable is connected but I don't have access to host-capable USBHS, so wouldn't be able to test it.) Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/renesas_usbhs/common.h')
-rw-r--r--drivers/usb/renesas_usbhs/common.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/usb/renesas_usbhs/common.h b/drivers/usb/renesas_usbhs/common.h
index 0427cdd1a483..fc96e924edc4 100644
--- a/drivers/usb/renesas_usbhs/common.h
+++ b/drivers/usb/renesas_usbhs/common.h
@@ -17,6 +17,7 @@
#ifndef RENESAS_USB_DRIVER_H
#define RENESAS_USB_DRIVER_H
+#include <linux/extcon.h>
#include <linux/platform_device.h>
#include <linux/usb/renesas_usbhs.h>
@@ -254,6 +255,8 @@ struct usbhs_priv {
struct delayed_work notify_hotplug_work;
struct platform_device *pdev;
+ struct extcon_dev *edev;
+
spinlock_t lock;
u32 flags;
OpenPOWER on IntegriCloud