linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/3] add RTT support for SAM9X60
@ 2020-06-10  9:05 Claudiu Beznea
  2020-06-10  9:05 ` [PATCH v2 1/3] irqchip/atmel-aic5: add support for sam9x60 rtt fixup Claudiu Beznea
                   ` (4 more replies)
  0 siblings, 5 replies; 8+ messages in thread
From: Claudiu Beznea @ 2020-06-10  9:05 UTC (permalink / raw)
  To: a.zummo, alexandre.belloni, robh+dt, nicolas.ferre,
	ludovic.desroches, tglx, jason, maz
  Cc: linux-rtc, devicetree, linux-arm-kernel, linux-kernel, Claudiu Beznea

This series adds RTT support for SAM9X60.

Changes in v2:
- use "atmel,at91sam9260-rtt" as fallback for compatible
- in patch 1 keep only the addition of sam9x60_aic_irq_fixup
- get rid of patches 2/5 from v1
- squash patches 4/5, 5/5 from v1
- change commit title for patch "rtc: at91sam9: add microchip,sam9x60-rtt"
  from v1 into "dt-bindings: rtc: add microchip,sam9x60-rtt" and
  place it before device tree patch

Claudiu Beznea (3):
  irqchip/atmel-aic5: add support for sam9x60 rtt fixup
  dt-bindings: rtc: add microchip,sam9x60-rtt
  ARM: dts: sam9x60: add rtt

 Documentation/devicetree/bindings/rtc/atmel,at91sam9-rtc.txt | 4 +++-
 arch/arm/boot/dts/at91-sam9x60ek.dts                         | 9 +++++++++
 arch/arm/boot/dts/sam9x60.dtsi                               | 7 +++++++
 drivers/irqchip/irq-atmel-aic5.c                             | 8 +++++++-
 4 files changed, 26 insertions(+), 2 deletions(-)

-- 
2.7.4


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PATCH v2 1/3] irqchip/atmel-aic5: add support for sam9x60 rtt fixup
  2020-06-10  9:05 [PATCH v2 0/3] add RTT support for SAM9X60 Claudiu Beznea
@ 2020-06-10  9:05 ` Claudiu Beznea
  2020-06-26 20:38   ` Alexandre Belloni
  2020-06-10  9:05 ` [PATCH v2 2/3] dt-bindings: rtc: add microchip,sam9x60-rtt Claudiu Beznea
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 8+ messages in thread
From: Claudiu Beznea @ 2020-06-10  9:05 UTC (permalink / raw)
  To: a.zummo, alexandre.belloni, robh+dt, nicolas.ferre,
	ludovic.desroches, tglx, jason, maz
  Cc: linux-rtc, devicetree, linux-arm-kernel, linux-kernel, Claudiu Beznea

Add support for SAM9X60 RTT fixup.

Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
---
 drivers/irqchip/irq-atmel-aic5.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/drivers/irqchip/irq-atmel-aic5.c b/drivers/irqchip/irq-atmel-aic5.c
index fc1b3a9cdafc..fb4ad2aaa727 100644
--- a/drivers/irqchip/irq-atmel-aic5.c
+++ b/drivers/irqchip/irq-atmel-aic5.c
@@ -310,10 +310,16 @@ static void __init sama5d3_aic_irq_fixup(void)
 	aic_common_rtc_irq_fixup();
 }
 
+static void __init sam9x60_aic_irq_fixup(void)
+{
+	aic_common_rtc_irq_fixup();
+	aic_common_rtt_irq_fixup();
+}
+
 static const struct of_device_id aic5_irq_fixups[] __initconst = {
 	{ .compatible = "atmel,sama5d3", .data = sama5d3_aic_irq_fixup },
 	{ .compatible = "atmel,sama5d4", .data = sama5d3_aic_irq_fixup },
-	{ .compatible = "microchip,sam9x60", .data = sama5d3_aic_irq_fixup },
+	{ .compatible = "microchip,sam9x60", .data = sam9x60_aic_irq_fixup },
 	{ /* sentinel */ },
 };
 
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH v2 2/3] dt-bindings: rtc: add microchip,sam9x60-rtt
  2020-06-10  9:05 [PATCH v2 0/3] add RTT support for SAM9X60 Claudiu Beznea
  2020-06-10  9:05 ` [PATCH v2 1/3] irqchip/atmel-aic5: add support for sam9x60 rtt fixup Claudiu Beznea
@ 2020-06-10  9:05 ` Claudiu Beznea
  2020-06-17 22:22   ` Rob Herring
  2020-06-10  9:05 ` [PATCH v2 3/3] ARM: dts: sam9x60: add rtt Claudiu Beznea
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 8+ messages in thread
From: Claudiu Beznea @ 2020-06-10  9:05 UTC (permalink / raw)
  To: a.zummo, alexandre.belloni, robh+dt, nicolas.ferre,
	ludovic.desroches, tglx, jason, maz
  Cc: linux-rtc, devicetree, linux-arm-kernel, linux-kernel, Claudiu Beznea

Add microchip,sam9x60-rtt to compatible list.

Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
---
 Documentation/devicetree/bindings/rtc/atmel,at91sam9-rtc.txt | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/rtc/atmel,at91sam9-rtc.txt b/Documentation/devicetree/bindings/rtc/atmel,at91sam9-rtc.txt
index 6ae79d1843f3..3f0e2a5950eb 100644
--- a/Documentation/devicetree/bindings/rtc/atmel,at91sam9-rtc.txt
+++ b/Documentation/devicetree/bindings/rtc/atmel,at91sam9-rtc.txt
@@ -1,7 +1,9 @@
 Atmel AT91SAM9260 Real Time Timer
 
 Required properties:
-- compatible: should be: "atmel,at91sam9260-rtt"
+- compatible: should be one of the following:
+	- "atmel,at91sam9260-rtt"
+	- "microchip,sam9x60-rtt", "atmel,at91sam9260-rtt"
 - reg: should encode the memory region of the RTT controller
 - interrupts: rtt alarm/event interrupt
 - clocks: should contain the 32 KHz slow clk that will drive the RTT block.
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH v2 3/3] ARM: dts: sam9x60: add rtt
  2020-06-10  9:05 [PATCH v2 0/3] add RTT support for SAM9X60 Claudiu Beznea
  2020-06-10  9:05 ` [PATCH v2 1/3] irqchip/atmel-aic5: add support for sam9x60 rtt fixup Claudiu Beznea
  2020-06-10  9:05 ` [PATCH v2 2/3] dt-bindings: rtc: add microchip,sam9x60-rtt Claudiu Beznea
@ 2020-06-10  9:05 ` Claudiu Beznea
  2020-06-26 20:44 ` [PATCH v2 0/3] add RTT support for SAM9X60 Alexandre Belloni
  2020-06-27 11:08 ` Marc Zyngier
  4 siblings, 0 replies; 8+ messages in thread
From: Claudiu Beznea @ 2020-06-10  9:05 UTC (permalink / raw)
  To: a.zummo, alexandre.belloni, robh+dt, nicolas.ferre,
	ludovic.desroches, tglx, jason, maz
  Cc: linux-rtc, devicetree, linux-arm-kernel, linux-kernel, Claudiu Beznea

Add RTT. Allong with it enable GBPR as it is requested by RTT.

Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
---
 arch/arm/boot/dts/at91-sam9x60ek.dts | 9 +++++++++
 arch/arm/boot/dts/sam9x60.dtsi       | 7 +++++++
 2 files changed, 16 insertions(+)

diff --git a/arch/arm/boot/dts/at91-sam9x60ek.dts b/arch/arm/boot/dts/at91-sam9x60ek.dts
index b484745bf2d4..39d946e0a47c 100644
--- a/arch/arm/boot/dts/at91-sam9x60ek.dts
+++ b/arch/arm/boot/dts/at91-sam9x60ek.dts
@@ -309,6 +309,10 @@
 	};
 };
 
+&gpbr {
+	status = "okay";
+};
+
 &i2s {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_i2s_default>;
@@ -613,6 +617,11 @@
 	};
 };
 
+&rtt {
+	atmel,rtt-rtc-time-reg = <&gpbr 0x0>;
+	status = "okay";
+};
+
 &shutdown_controller {
 	atmel,shdwc-debouncer = <976>;
 	status = "okay";
diff --git a/arch/arm/boot/dts/sam9x60.dtsi b/arch/arm/boot/dts/sam9x60.dtsi
index 6763423d64b8..d10843da4a85 100644
--- a/arch/arm/boot/dts/sam9x60.dtsi
+++ b/arch/arm/boot/dts/sam9x60.dtsi
@@ -661,6 +661,13 @@
 				status = "disabled";
 			};
 
+			rtt: rtt@fffffe20 {
+				compatible = "microchip,sam9x60-rtt", "atmel,at91sam9260-rtt";
+				reg = <0xfffffe20 0x20>;
+				interrupts = <1 IRQ_TYPE_LEVEL_HIGH 7>;
+				clocks = <&clk32k 0>;
+			};
+
 			pit: timer@fffffe40 {
 				compatible = "atmel,at91sam9260-pit";
 				reg = <0xfffffe40 0x10>;
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PATCH v2 2/3] dt-bindings: rtc: add microchip,sam9x60-rtt
  2020-06-10  9:05 ` [PATCH v2 2/3] dt-bindings: rtc: add microchip,sam9x60-rtt Claudiu Beznea
@ 2020-06-17 22:22   ` Rob Herring
  0 siblings, 0 replies; 8+ messages in thread
From: Rob Herring @ 2020-06-17 22:22 UTC (permalink / raw)
  To: Claudiu Beznea
  Cc: linux-arm-kernel, robh+dt, ludovic.desroches, maz, jason,
	nicolas.ferre, linux-rtc, tglx, a.zummo, alexandre.belloni,
	devicetree, linux-kernel

On Wed, 10 Jun 2020 12:05:35 +0300, Claudiu Beznea wrote:
> Add microchip,sam9x60-rtt to compatible list.
> 
> Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
> ---
>  Documentation/devicetree/bindings/rtc/atmel,at91sam9-rtc.txt | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 

Acked-by: Rob Herring <robh@kernel.org>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v2 1/3] irqchip/atmel-aic5: add support for sam9x60 rtt fixup
  2020-06-10  9:05 ` [PATCH v2 1/3] irqchip/atmel-aic5: add support for sam9x60 rtt fixup Claudiu Beznea
@ 2020-06-26 20:38   ` Alexandre Belloni
  0 siblings, 0 replies; 8+ messages in thread
From: Alexandre Belloni @ 2020-06-26 20:38 UTC (permalink / raw)
  To: Claudiu Beznea
  Cc: a.zummo, robh+dt, nicolas.ferre, ludovic.desroches, tglx, jason,
	maz, linux-rtc, devicetree, linux-arm-kernel, linux-kernel

On 10/06/2020 12:05:34+0300, Claudiu Beznea wrote:
> Add support for SAM9X60 RTT fixup.
> 
> Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>

Reviewed-by: Alexandre Belloni <alexandre.belloni@bootlin.com>

> ---
>  drivers/irqchip/irq-atmel-aic5.c | 8 +++++++-
>  1 file changed, 7 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/irqchip/irq-atmel-aic5.c b/drivers/irqchip/irq-atmel-aic5.c
> index fc1b3a9cdafc..fb4ad2aaa727 100644
> --- a/drivers/irqchip/irq-atmel-aic5.c
> +++ b/drivers/irqchip/irq-atmel-aic5.c
> @@ -310,10 +310,16 @@ static void __init sama5d3_aic_irq_fixup(void)
>  	aic_common_rtc_irq_fixup();
>  }
>  
> +static void __init sam9x60_aic_irq_fixup(void)
> +{
> +	aic_common_rtc_irq_fixup();
> +	aic_common_rtt_irq_fixup();
> +}
> +
>  static const struct of_device_id aic5_irq_fixups[] __initconst = {
>  	{ .compatible = "atmel,sama5d3", .data = sama5d3_aic_irq_fixup },
>  	{ .compatible = "atmel,sama5d4", .data = sama5d3_aic_irq_fixup },
> -	{ .compatible = "microchip,sam9x60", .data = sama5d3_aic_irq_fixup },
> +	{ .compatible = "microchip,sam9x60", .data = sam9x60_aic_irq_fixup },
>  	{ /* sentinel */ },
>  };
>  
> -- 
> 2.7.4
> 

-- 
Alexandre Belloni, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v2 0/3] add RTT support for SAM9X60
  2020-06-10  9:05 [PATCH v2 0/3] add RTT support for SAM9X60 Claudiu Beznea
                   ` (2 preceding siblings ...)
  2020-06-10  9:05 ` [PATCH v2 3/3] ARM: dts: sam9x60: add rtt Claudiu Beznea
@ 2020-06-26 20:44 ` Alexandre Belloni
  2020-06-27 11:08 ` Marc Zyngier
  4 siblings, 0 replies; 8+ messages in thread
From: Alexandre Belloni @ 2020-06-26 20:44 UTC (permalink / raw)
  To: a.zummo, ludovic.desroches, Claudiu Beznea, nicolas.ferre,
	robh+dt, jason, maz, tglx
  Cc: Alexandre Belloni, linux-arm-kernel, linux-rtc, linux-kernel, devicetree

On Wed, 10 Jun 2020 12:05:33 +0300, Claudiu Beznea wrote:
> This series adds RTT support for SAM9X60.
> 
> Changes in v2:
> - use "atmel,at91sam9260-rtt" as fallback for compatible
> - in patch 1 keep only the addition of sam9x60_aic_irq_fixup
> - get rid of patches 2/5 from v1
> - squash patches 4/5, 5/5 from v1
> - change commit title for patch "rtc: at91sam9: add microchip,sam9x60-rtt"
>   from v1 into "dt-bindings: rtc: add microchip,sam9x60-rtt" and
>   place it before device tree patch
> 
> [...]

Applied 2 and 3, thanks!

[2/3] dt-bindings: rtc: add microchip,sam9x60-rtt
      commit: 73554069ded8fc6fa747423522c4295d5bbf6f52
[3/3] ARM: dts: sam9x60: add rtt
      commit: 5f6b33f463468b9595eebfed142756ba13ea2b60

Best regards,

-- 
Alexandre Belloni, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH v2 0/3] add RTT support for SAM9X60
  2020-06-10  9:05 [PATCH v2 0/3] add RTT support for SAM9X60 Claudiu Beznea
                   ` (3 preceding siblings ...)
  2020-06-26 20:44 ` [PATCH v2 0/3] add RTT support for SAM9X60 Alexandre Belloni
@ 2020-06-27 11:08 ` Marc Zyngier
  4 siblings, 0 replies; 8+ messages in thread
From: Marc Zyngier @ 2020-06-27 11:08 UTC (permalink / raw)
  To: Jason Cooper, Matthias Brugger, Bartosz Golaszewski,
	Thomas Gleixner, Claudiu Beznea, nicolas.ferre, robh+dt, a.zummo,
	alexandre.belloni, ludovic.desroches
  Cc: Andrew Perepech, linux-mediatek, Stephane Le Provost,
	linux-arm-kernel, Pedro Tsai, Bartosz Golaszewski, Fabien Parent,
	linux-kernel, devicetree, linux-rtc

On Wed, 10 Jun 2020 12:05:33 +0300, Claudiu Beznea wrote:
> This series adds RTT support for SAM9X60.
> 
> Changes in v2:
> - use "atmel,at91sam9260-rtt" as fallback for compatible
> - in patch 1 keep only the addition of sam9x60_aic_irq_fixup
> - get rid of patches 2/5 from v1
> - squash patches 4/5, 5/5 from v1
> - change commit title for patch "rtc: at91sam9: add microchip,sam9x60-rtt"
>   from v1 into "dt-bindings: rtc: add microchip,sam9x60-rtt" and
>   place it before device tree patch
> 
> [...]

Applied to irq/irqchip-5.9:

[1/3] irqchip/atmel-aic5: Add support for sam9x60 rtt fixup
      commit: 293953d60e214aa44b3261f5350b83f285a95eb4

Thanks,

	M.
-- 
Without deviation from the norm, progress is not possible.


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2020-06-27 11:08 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-10  9:05 [PATCH v2 0/3] add RTT support for SAM9X60 Claudiu Beznea
2020-06-10  9:05 ` [PATCH v2 1/3] irqchip/atmel-aic5: add support for sam9x60 rtt fixup Claudiu Beznea
2020-06-26 20:38   ` Alexandre Belloni
2020-06-10  9:05 ` [PATCH v2 2/3] dt-bindings: rtc: add microchip,sam9x60-rtt Claudiu Beznea
2020-06-17 22:22   ` Rob Herring
2020-06-10  9:05 ` [PATCH v2 3/3] ARM: dts: sam9x60: add rtt Claudiu Beznea
2020-06-26 20:44 ` [PATCH v2 0/3] add RTT support for SAM9X60 Alexandre Belloni
2020-06-27 11:08 ` Marc Zyngier

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).