diff mbox

[2/2] ARM: OMAP2+: Remove dmm device creation

Message ID 1363754624-5209-3-git-send-email-andy.gross@ti.com (mailing list archive)
State New, archived
Headers show

Commit Message

Andy Gross March 20, 2013, 4:43 a.m. UTC
Remove DMM device creation via the hwmod entry.  The DMM device will
now be enumerated as part of the device tree information for the
processor.

Signed-off-by: Andy Gross <andy.gross@ti.com>
---
 Documentation/devicetree/bindings/arm/omap/dmm.txt |   16 ++++++++++++++++
 arch/arm/mach-omap2/drm.c                          |   12 ------------
 2 files changed, 16 insertions(+), 12 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/arm/omap/dmm.txt

Comments

Santosh Shilimkar March 20, 2013, 5:56 a.m. UTC | #1
On Wednesday 20 March 2013 10:13 AM, Andy Gross wrote:
> Remove DMM device creation via the hwmod entry.  The DMM device will
> now be enumerated as part of the device tree information for the
> processor.
> 
> Signed-off-by: Andy Gross <andy.gross@ti.com>
> ---
OMAP4 is still not made DT only so I suggest you to hold on for this patch
till that happens.

Regards,
Santosh
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
archit taneja March 20, 2013, 6:16 a.m. UTC | #2
On Wednesday 20 March 2013 11:26 AM, Santosh Shilimkar wrote:
> On Wednesday 20 March 2013 10:13 AM, Andy Gross wrote:
>> Remove DMM device creation via the hwmod entry.  The DMM device will
>> now be enumerated as part of the device tree information for the
>> processor.
>>
>> Signed-off-by: Andy Gross <andy.gross@ti.com>
>> ---
> OMAP4 is still not made DT only so I suggest you to hold on for this patch
> till that happens.

Wouldn't we need to at least prevent building the platform device using 
omap_device_build() when we are using DT?

Archit

>
> Regards,
> Santosh
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
>

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Santosh Shilimkar March 20, 2013, 6:22 a.m. UTC | #3
On Wednesday 20 March 2013 11:46 AM, Archit Taneja wrote:
> On Wednesday 20 March 2013 11:26 AM, Santosh Shilimkar wrote:
>> On Wednesday 20 March 2013 10:13 AM, Andy Gross wrote:
>>> Remove DMM device creation via the hwmod entry.  The DMM device will
>>> now be enumerated as part of the device tree information for the
>>> processor.
>>>
>>> Signed-off-by: Andy Gross <andy.gross@ti.com>
>>> ---
>> OMAP4 is still not made DT only so I suggest you to hold on for this patch
>> till that happens.
> 
> Wouldn't we need to at least prevent building the platform device using omap_device_build() when we are using DT?
> 
Yes. I assumed Andy will do that once he decides to keep the
non-dt support :)

Regards,
Santosh

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Andy Gross March 20, 2013, 6:28 a.m. UTC | #4
Yes ill fix it up and move the doc to the other patch and send a v2
diff mbox

Patch

diff --git a/Documentation/devicetree/bindings/arm/omap/dmm.txt b/Documentation/devicetree/bindings/arm/omap/dmm.txt
new file mode 100644
index 0000000..5fd1134
--- /dev/null
+++ b/Documentation/devicetree/bindings/arm/omap/dmm.txt
@@ -0,0 +1,16 @@ 
+OMAP Dynamic Memory Manager (DMM) bindings
+
+Required properties:
+- compatible:	Must be "ti,dmm" for OMAP processors containing DMM block
+- reg:		Contains timer register address range (base address and length)
+- interrupts:	Contains interrupt information (source, etc) for the DMM IRQ
+- ti,hwmods:	Name of the hwmod associated to the counter, which is typically
+		"dmm"
+
+Example:
+
+dmm: dmm@4e000000 {
+	compatible = "ti,dmm";
+	reg = <0x4e000000 0x800>;
+	ti,hwmods = "dmm";
+};
diff --git a/arch/arm/mach-omap2/drm.c b/arch/arm/mach-omap2/drm.c
index 59a4af7..1fd0487 100644
--- a/arch/arm/mach-omap2/drm.c
+++ b/arch/arm/mach-omap2/drm.c
@@ -44,18 +44,6 @@  static struct platform_device omap_drm_device = {
 
 static int __init omap_init_drm(void)
 {
-	struct omap_hwmod *oh = NULL;
-	struct platform_device *pdev;
-
-	/* lookup and populate the DMM information, if present - OMAP4+ */
-	oh = omap_hwmod_lookup("dmm");
-
-	if (oh) {
-		pdev = omap_device_build(oh->name, -1, oh, NULL, 0);
-		WARN(IS_ERR(pdev), "Could not build omap_device for %s\n",
-			oh->name);
-	}
-
 	platform_data.omaprev = GET_OMAP_TYPE;
 
 	return platform_device_register(&omap_drm_device);