mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v2] riscv: dts: starfive: correct number of external interrupts
@ 2022-07-07 18:55 Mark Kettenis
  2022-07-07 19:24 ` Conor.Dooley
  2022-08-11 21:06 ` Palmer Dabbelt
  0 siblings, 2 replies; 3+ messages in thread
From: Mark Kettenis @ 2022-07-07 18:55 UTC (permalink / raw)
  To: Conor Dooley, Rob Herring, Krzysztof Kozlowski, Paul Walmsley,
	Palmer Dabbelt, Albert Ou, Emil Renner Berthing
  Cc: Mark Kettenis, Palmer Dabbelt, devicetree, linux-riscv, linux-kernel

The PLIC integrated on the Vic_U7_Core integrated on the StarFive
JH7100 SoC actually supports 133 external interrupts.  127 of these
are exposed to the outside world; the remainder are used by other
devices that are part of the core-complex such as the L2 cache
controller.  But all 133 interrupts are external interrupts as far
as the PLIC is concerned.  Fix the property so that the driver can
manage these additional interrupts, which is important since the
interrupts for the L2 cache controller are enabled by default.

Fixes: ec85362fb121 ("RISC-V: Add initial StarFive JH7100 device tree")
Signed-off-by: Mark Kettenis <kettenis@openbsd.org>
---

ChangeLog:

v2: - Fix commit message


 arch/riscv/boot/dts/starfive/jh7100.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/riscv/boot/dts/starfive/jh7100.dtsi b/arch/riscv/boot/dts/starfive/jh7100.dtsi
index 69f22f9aad9d..f48e232a72a7 100644
--- a/arch/riscv/boot/dts/starfive/jh7100.dtsi
+++ b/arch/riscv/boot/dts/starfive/jh7100.dtsi
@@ -118,7 +118,7 @@ plic: interrupt-controller@c000000 {
 			interrupt-controller;
 			#address-cells = <0>;
 			#interrupt-cells = <1>;
-			riscv,ndev = <127>;
+			riscv,ndev = <133>;
 		};
 
 		clkgen: clock-controller@11800000 {
-- 
2.36.1


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

* Re: [PATCH v2] riscv: dts: starfive: correct number of external interrupts
  2022-07-07 18:55 [PATCH v2] riscv: dts: starfive: correct number of external interrupts Mark Kettenis
@ 2022-07-07 19:24 ` Conor.Dooley
  2022-08-11 21:06 ` Palmer Dabbelt
  1 sibling, 0 replies; 3+ messages in thread
From: Conor.Dooley @ 2022-07-07 19:24 UTC (permalink / raw)
  To: kettenis, robh+dt, krzysztof.kozlowski+dt, paul.walmsley, palmer,
	aou, kernel
  Cc: palmer, devicetree, linux-riscv, linux-kernel

On 07/07/2022 19:55, Mark Kettenis wrote:
> The PLIC integrated on the Vic_U7_Core integrated on the StarFive
> JH7100 SoC actually supports 133 external interrupts.  127 of these
> are exposed to the outside world; the remainder are used by other
> devices that are part of the core-complex such as the L2 cache
> controller.  But all 133 interrupts are external interrupts as far
> as the PLIC is concerned.  Fix the property so that the driver can
> manage these additional interrupts, which is important since the
> interrupts for the L2 cache controller are enabled by default.

The missing 4 for the l2cache controller certainly make sense &
the documentation does mention there being interrupts as far up
as 131 in Table 28.
Table 33 disagrees and has an interrupt 133.
God knows what those two are used for, but the documentation
certainly makes it look like they do exist.

Link: https://github.com/starfive-tech/JH7100_Docs/blob/main/vic_u7_manual_with_creativecommons.pdf # Page 44 & 45
Reviewed-by: Conor Dooley <conor.dooley@microchip.com>

> 
> Fixes: ec85362fb121 ("RISC-V: Add initial StarFive JH7100 device tree")
> Signed-off-by: Mark Kettenis <kettenis@openbsd.org>
> ---
> 
> ChangeLog:
> 
> v2: - Fix commit message
> 
> 
>  arch/riscv/boot/dts/starfive/jh7100.dtsi | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/riscv/boot/dts/starfive/jh7100.dtsi b/arch/riscv/boot/dts/starfive/jh7100.dtsi
> index 69f22f9aad9d..f48e232a72a7 100644
> --- a/arch/riscv/boot/dts/starfive/jh7100.dtsi
> +++ b/arch/riscv/boot/dts/starfive/jh7100.dtsi
> @@ -118,7 +118,7 @@ plic: interrupt-controller@c000000 {
>  			interrupt-controller;
>  			#address-cells = <0>;
>  			#interrupt-cells = <1>;
> -			riscv,ndev = <127>;
> +			riscv,ndev = <133>;
>  		};
>  
>  		clkgen: clock-controller@11800000 {

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

* Re: [PATCH v2] riscv: dts: starfive: correct number of external interrupts
  2022-07-07 18:55 [PATCH v2] riscv: dts: starfive: correct number of external interrupts Mark Kettenis
  2022-07-07 19:24 ` Conor.Dooley
@ 2022-08-11 21:06 ` Palmer Dabbelt
  1 sibling, 0 replies; 3+ messages in thread
From: Palmer Dabbelt @ 2022-08-11 21:06 UTC (permalink / raw)
  To: kettenis
  Cc: mail, robh+dt, krzysztof.kozlowski+dt, Paul Walmsley, aou,
	kernel, kettenis, devicetree, linux-riscv, linux-kernel

On Thu, 07 Jul 2022 11:55:28 PDT (-0700), kettenis@openbsd.org wrote:
> The PLIC integrated on the Vic_U7_Core integrated on the StarFive
> JH7100 SoC actually supports 133 external interrupts.  127 of these
> are exposed to the outside world; the remainder are used by other
> devices that are part of the core-complex such as the L2 cache
> controller.  But all 133 interrupts are external interrupts as far
> as the PLIC is concerned.  Fix the property so that the driver can
> manage these additional interrupts, which is important since the
> interrupts for the L2 cache controller are enabled by default.
>
> Fixes: ec85362fb121 ("RISC-V: Add initial StarFive JH7100 device tree")
> Signed-off-by: Mark Kettenis <kettenis@openbsd.org>
> ---
>
> ChangeLog:
>
> v2: - Fix commit message
>
>
>  arch/riscv/boot/dts/starfive/jh7100.dtsi | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/riscv/boot/dts/starfive/jh7100.dtsi b/arch/riscv/boot/dts/starfive/jh7100.dtsi
> index 69f22f9aad9d..f48e232a72a7 100644
> --- a/arch/riscv/boot/dts/starfive/jh7100.dtsi
> +++ b/arch/riscv/boot/dts/starfive/jh7100.dtsi
> @@ -118,7 +118,7 @@ plic: interrupt-controller@c000000 {
>  			interrupt-controller;
>  			#address-cells = <0>;
>  			#interrupt-cells = <1>;
> -			riscv,ndev = <127>;
> +			riscv,ndev = <133>;
>  		};
>
>  		clkgen: clock-controller@11800000 {

Thanks, this is on for-next.

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

end of thread, other threads:[~2022-08-11 21:08 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-07 18:55 [PATCH v2] riscv: dts: starfive: correct number of external interrupts Mark Kettenis
2022-07-07 19:24 ` Conor.Dooley
2022-08-11 21:06 ` Palmer Dabbelt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome