linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Roland Stigge <stigge@antcom.de>
To: arm@kernel.org, linux-arm-kernel@lists.infradead.org,
	thierry.reding@avionic-design.de, gregkh@linuxfoundation.org,
	linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-input@vger.kernel.org, dmitry.torokhov@gmail.com,
	axel.lin@gmail.com, broonie@opensource.wolfsonmicro.com,
	marek.vasut@gmail.com, devel@driverdev.osuosl.org,
	kevin.wells@nxp.com, srinivas.bakki@nxp.com,
	dan.carpenter@oracle.com
Cc: Roland Stigge <stigge@antcom.de>
Subject: [PATCH v3 2/10] ohci-nxp: Device tree support
Date: Wed, 18 Apr 2012 15:36:07 +0200	[thread overview]
Message-ID: <1334756176-25144-3-git-send-email-stigge@antcom.de> (raw)
In-Reply-To: <1334756176-25144-1-git-send-email-stigge@antcom.de>

This patch adds device tree support to ohci-nxp.c

Signed-off-by: Roland Stigge <stigge@antcom.de>

---

Applies to v3.4-rc3

 Documentation/devicetree/bindings/usb/ohci-nxp.txt |   16 ++++++++++++++++
 drivers/usb/host/ohci-nxp.c                        |   10 ++++++++++
 2 files changed, 26 insertions(+)

--- /dev/null
+++ linux-2.6/Documentation/devicetree/bindings/usb/ohci-nxp.txt
@@ -0,0 +1,16 @@
+* OHCI controller, NXP ohci-nxp variant
+
+Required properties:
+- compatible: must be "nxp,ohci-nxp"
+- reg: physical base address of the controller and length of memory mapped
+  region.
+- interrupts: The OHCI interrupt
+
+Example (LPC32xx):
+
+	ohci@31020000 {
+		compatible = "nxp,ohci-nxp";
+		reg = <0x31020000 0x300>;
+		interrupt-parent = <&mic>;
+		interrupts = <0x3b 0>;
+	};
--- linux-2.6.orig/drivers/usb/host/ohci-nxp.c
+++ linux-2.6/drivers/usb/host/ohci-nxp.c
@@ -22,6 +22,7 @@
 #include <linux/clk.h>
 #include <linux/platform_device.h>
 #include <linux/i2c.h>
+#include <linux/of.h>
 
 #include <mach/hardware.h>
 #include <asm/mach-types.h>
@@ -525,10 +526,19 @@ static int usb_hcd_nxp_remove(struct pla
 /* work with hotplug and coldplug */
 MODULE_ALIAS("platform:usb-ohci");
 
+#ifdef CONFIG_OF
+static const struct of_device_id usb_hcd_nxp_match[] = {
+	{ .compatible = "nxp,ohci-nxp" },
+	{},
+};
+MODULE_DEVICE_TABLE(of, usb_hcd_nxp_match);
+#endif
+
 static struct platform_driver usb_hcd_nxp_driver = {
 	.driver = {
 		.name = "usb-ohci",
 		.owner	= THIS_MODULE,
+		.of_match_table = of_match_ptr(usb_hcd_nxp_match),
 	},
 	.probe = usb_hcd_nxp_probe,
 	.remove = usb_hcd_nxp_remove,

  parent reply	other threads:[~2012-04-18 13:37 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-18 13:36 [PATCH v3 0/10] Second patchset for LPC32xx device tree conversion Roland Stigge
2012-04-18 13:36 ` [PATCH v3 1/10] ohci-nxp: Driver cleanup Roland Stigge
2012-04-18 13:36 ` Roland Stigge [this message]
2012-04-18 13:36 ` [PATCH v3 3/10] ARM: LPC32xx: clock.c cleanup Roland Stigge
2012-04-18 13:36 ` [PATCH v3 4/10] ARM: LPC32xx: clock.c dma adjustment Roland Stigge
2012-04-18 13:36 ` [PATCH v3 5/10] ARM: LPC32xx: Remove obsolete platform Kconfig Roland Stigge
2012-04-18 13:36 ` [PATCH v3 6/10] input: Device tree support for LPC32xx touchscreen Roland Stigge
2012-04-18 13:36 ` [PATCH v3 7/10] iio: lpc32xx-adc: Remove driver conflict due to device tree Roland Stigge
2012-04-18 22:02   ` Greg KH
2012-04-18 13:36 ` [PATCH v3 8/10] ARM: LPC32xx: DTS files for device tree conversion Roland Stigge
2012-04-18 13:36 ` [PATCH v3 9/10] ARM: LPC32xx: Device tree support Roland Stigge
2012-04-18 13:36 ` [PATCH v3 10/10] ARM: LPC32xx: Move common code to common.c Roland Stigge

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=1334756176-25144-3-git-send-email-stigge@antcom.de \
    --to=stigge@antcom.de \
    --cc=arm@kernel.org \
    --cc=axel.lin@gmail.com \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=dan.carpenter@oracle.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=dmitry.torokhov@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=kevin.wells@nxp.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=marek.vasut@gmail.com \
    --cc=srinivas.bakki@nxp.com \
    --cc=thierry.reding@avionic-design.de \
    /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).