MIPS: JZ4740: dts: Add bindings for the jz4740-wdt driver
authorPaul Cercueil <paul@crapouillou.net>
Thu, 10 May 2018 18:47:48 +0000 (20:47 +0200)
committerJames Hogan <jhogan@kernel.org>
Mon, 14 May 2018 22:58:23 +0000 (23:58 +0100)
Also remove the watchdog platform_device from platform.c, since it
wasn't used anywhere anyway.

Signed-off-by: Paul Cercueil <paul@crapouillou.net>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Guenter Roeck <linux@roeck-us.net>
Cc: Wim Van Sebroeck <wim@linux-watchdog.org>
Cc: Rob Herring <robh+dt@kernel.org>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Mathieu Malaterre <malat@debian.org>
Cc: linux-mips@linux-mips.org
Cc: linux-watchdog@vger.kernel.org
Cc: devicetree@vger.kernel.org
[jhogan@kernel.org: Drop jz4740_wdt_device declaration from header]
Signed-off-by: James Hogan <jhogan@kernel.org>
arch/mips/boot/dts/ingenic/jz4740.dtsi
arch/mips/include/asm/mach-jz4740/platform.h
arch/mips/jz4740/platform.c

index cd5185bb90ae47222eab9e54570b498503e9c81d..26c6b561d6f721228a01256e9084d258be65479c 100644 (file)
                #clock-cells = <1>;
        };
 
+       watchdog: watchdog@10002000 {
+               compatible = "ingenic,jz4740-watchdog";
+               reg = <0x10002000 0x10>;
+
+               clocks = <&cgu JZ4740_CLK_RTC>;
+               clock-names = "rtc";
+       };
+
        rtc_dev: rtc@10003000 {
                compatible = "ingenic,jz4740-rtc";
                reg = <0x10003000 0x40>;
index 3645974b7f6595ed1f5d6729621b3763b4399e87..c0c932ac72a71fb65c6e38b69e67fe806edcca78 100644 (file)
@@ -29,7 +29,6 @@ extern struct platform_device jz4740_i2s_device;
 extern struct platform_device jz4740_pcm_device;
 extern struct platform_device jz4740_codec_device;
 extern struct platform_device jz4740_adc_device;
-extern struct platform_device jz4740_wdt_device;
 extern struct platform_device jz4740_pwm_device;
 extern struct platform_device jz4740_dma_device;
 
index 5b7cdd67a9d95b624d52d780ab736f779e551904..cbc5f8e87230972c85c775ef043eebe9c500811b 100644 (file)
@@ -233,22 +233,6 @@ struct platform_device jz4740_adc_device = {
        .resource       = jz4740_adc_resources,
 };
 
-/* Watchdog */
-static struct resource jz4740_wdt_resources[] = {
-       {
-               .start = JZ4740_WDT_BASE_ADDR,
-               .end   = JZ4740_WDT_BASE_ADDR + 0x10 - 1,
-               .flags = IORESOURCE_MEM,
-       },
-};
-
-struct platform_device jz4740_wdt_device = {
-       .name          = "jz4740-wdt",
-       .id            = -1,
-       .num_resources = ARRAY_SIZE(jz4740_wdt_resources),
-       .resource      = jz4740_wdt_resources,
-};
-
 /* PWM */
 struct platform_device jz4740_pwm_device = {
        .name = "jz4740-pwm",