devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Roger Quadros <rogerq@ti.com>
To: sameo@linux.intel.com
Cc: balbi@ti.com, b-cousson@ti.com, mark.rutland@arm.com,
	linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org,
	linux-omap@vger.kernel.org, devicetree-discuss@lists.ozlabs.org,
	rogerq@ti.com
Subject: [PATCH 5/6] mfd: omap-usb-tll: Add device tree support and binding information
Date: Tue, 12 Mar 2013 12:25:39 +0200	[thread overview]
Message-ID: <1363083940-20050-6-git-send-email-rogerq@ti.com> (raw)
In-Reply-To: <1363083940-20050-1-git-send-email-rogerq@ti.com>

Allows the OMAP USB TLL module to be specified via device tree.

Signed-off-by: Roger Quadros <rogerq@ti.com>
---
 .../devicetree/bindings/mfd/omap-usb-tll.txt       |   17 +++++++++++++++++
 drivers/mfd/omap-usb-tll.c                         |   10 ++++++++++
 2 files changed, 27 insertions(+), 0 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/mfd/omap-usb-tll.txt

diff --git a/Documentation/devicetree/bindings/mfd/omap-usb-tll.txt b/Documentation/devicetree/bindings/mfd/omap-usb-tll.txt
new file mode 100644
index 0000000..62fe697
--- /dev/null
+++ b/Documentation/devicetree/bindings/mfd/omap-usb-tll.txt
@@ -0,0 +1,17 @@
+OMAP HS USB Host TLL (Transceiver-Less Interface)
+
+Required properties:
+
+- compatible : should be "ti,usbhs-tll"
+- reg : should contain one register range i.e. start and length
+- interrupts : should contain the TLL module's interrupt
+- ti,hwmod : must contain "usb_tll_hs"
+
+Example:
+
+	usbhstll: usbhstll@4a062000 {
+		compatible = "ti,usbhs-tll";
+		reg = <0x4a062000 0x1000>;
+		interrupts = <78>;
+		ti,hwmods = "usb_tll_hs";
+	  };
diff --git a/drivers/mfd/omap-usb-tll.c b/drivers/mfd/omap-usb-tll.c
index f7d2568..8f4d5a1 100644
--- a/drivers/mfd/omap-usb-tll.c
+++ b/drivers/mfd/omap-usb-tll.c
@@ -28,6 +28,7 @@
 #include <linux/err.h>
 #include <linux/pm_runtime.h>
 #include <linux/platform_data/usb-omap.h>
+#include <linux/of.h>
 
 #define USBTLL_DRIVER_NAME	"usbhs_tll"
 
@@ -311,10 +312,18 @@ static int usbtll_omap_remove(struct platform_device *pdev)
 	return 0;
 }
 
+static const struct of_device_id usbtll_omap_dt_ids[] = {
+	{ .compatible = "ti,usbhs-tll" },
+	{ }
+};
+
+MODULE_DEVICE_TABLE(of, usbtll_omap_dt_ids);
+
 static struct platform_driver usbtll_omap_driver = {
 	.driver = {
 		.name		= (char *)usbtll_driver_name,
 		.owner		= THIS_MODULE,
+		.of_match_table = of_match_ptr(usbtll_omap_dt_ids),
 	},
 	.probe		= usbtll_omap_probe,
 	.remove		= usbtll_omap_remove,
@@ -467,6 +476,7 @@ int omap_tll_disable(struct usbhs_omap_platform_data *pdata)
 EXPORT_SYMBOL_GPL(omap_tll_disable);
 
 MODULE_AUTHOR("Keshava Munegowda <keshava_mgowda@ti.com>");
+MODULE_AUTHOR("Roger Quadros <rogerq@ti.com>");
 MODULE_ALIAS("platform:" USBHS_DRIVER_NAME);
 MODULE_LICENSE("GPL v2");
 MODULE_DESCRIPTION("usb tll driver for TI OMAP EHCI and OHCI controllers");
-- 
1.7.4.1

  parent reply	other threads:[~2013-03-12 10:25 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-12 10:25 [PATCH 0/6] mfd: omap-usb-host: Device tree support for 3.10 Roger Quadros
2013-03-12 10:25 ` [PATCH 2/6] mfd: omap-usb-host: Remove PHY reset handling code Roger Quadros
2013-03-12 10:25 ` [PATCH 3/6] mfd: omap-usb-host: Actually update hostconfig Roger Quadros
     [not found]   ` <1363083940-20050-4-git-send-email-rogerq-l0cyMroinI0@public.gmane.org>
2013-03-14 14:03     ` Felipe Balbi
2013-03-12 10:25 ` [PATCH 4/6] mfd: omap-usb-tll: move configuration code to omap_tll_init() Roger Quadros
2013-03-12 10:25 ` Roger Quadros [this message]
     [not found] ` <1363083940-20050-1-git-send-email-rogerq-l0cyMroinI0@public.gmane.org>
2013-03-12 10:25   ` [PATCH 1/6] mfd: omap-usb-host: update nports in platform_data Roger Quadros
2013-03-12 10:25   ` [PATCH 6/6] mfd: omap-usb-host: Add device tree support and binding information Roger Quadros
2013-03-25 10:42 ` [PATCH 0/6] mfd: omap-usb-host: Device tree support for 3.10 Roger Quadros
2013-04-09  7:54   ` Samuel Ortiz
2013-04-09  8:39     ` Roger Quadros
     [not found]       ` <1365496758-16287-1-git-send-email-rogerq-l0cyMroinI0@public.gmane.org>
2013-04-09  8:39         ` [PATCH 1/2] mfd: omap-usb-host: Remove PHY reset handling code Roger Quadros
2013-04-09  8:39         ` [PATCH 2/2] mfd: omap-usb-host: Add device tree support and binding information Roger Quadros
2013-04-09  9:00         ` [PATCH 0/6] mfd: omap-usb-host: Device tree support for 3.10 Samuel Ortiz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1363083940-20050-6-git-send-email-rogerq@ti.com \
    --to=rogerq@ti.com \
    --cc=b-cousson@ti.com \
    --cc=balbi@ti.com \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=sameo@linux.intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).