Add support for PECI Nuvoton
Subsystems (3)
Iwona Winiarska
maintainercover Add support for PECI Nuvoton
Hi!
This series is based on patches that were sent by Tomer Maimon from Nuvoton [1].
Similar to Aspeed driver, I removed vendor-specific properties that were not used (as in, default values were used in all of the available DTS files). If there is a use-case for such properties, they can be added in a separate series.
I wasn't able to test it on a real hardware so I would like to ask for help to test it on Nuvoton systems.
Thanks
-Iwona
[1] https://lore.kernel.org/openbmc/CAP6Zq1jnbQ8k9VEyf9WgVq5DRrEzf5V6kaYP30S7g9BV9jKtaQ@mail.gmail.com/
Iwona Winiarska (2):
ARM: dts: nuvoton: Add PECI controller node
arm64: dts: nuvoton: Add PECI controller node
Tomer Maimon (2):
dt-bindings: Add bindings for peci-npcm
peci: Add peci-npcm controller driver
.../devicetree/bindings/peci/peci-npcm.yaml | 56 ++++ arch/arm/boot/dts/nuvoton-common-npcm7xx.dtsi | 9 + .../dts/nuvoton/nuvoton-common-npcm8xx.dtsi | 9 + drivers/peci/controller/Kconfig | 16 + drivers/peci/controller/Makefile | 1 + drivers/peci/controller/peci-npcm.c | 298 ++++++++++++++++++ 6 files changed, 389 insertions(+) create mode 100644 Documentation/devicetree/bindings/peci/peci-npcm.yaml create mode 100644 drivers/peci/controller/peci-npcm.c
Signature · 1 line
2.40.1
Iwona Winiarska
maintainerPATCH 1/4 dt-bindings: Add bindings for peci-npcm
From: Tomer Maimon <[email protected]>
Add device tree bindings for the peci-npcm controller driver.
--- .../devicetree/bindings/peci/peci-npcm.yaml | 56 +++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 Documentation/devicetree/bindings/peci/peci-npcm.yaml
Documentation/devicetree/bindings/peci/peci-npcm.yaml new file +56 -0
@@ -0,0 +1,56 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/peci/peci-npcm.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Nuvoton PECI Bus + +maintainers: + - Tomer Maimon <[email protected]> + +allOf: + - $ref: peci-controller.yaml# + +properties: + compatible: + enum: + - nuvoton,npcm750-peci + - nuvoton,npcm845-peci + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + clocks: + description: + Clock source for PECI controller. Should reference the APB clock. + maxItems: 1 + + cmd-timeout-ms: + minimum: 1 + maximum: 1000 + default: 1000 + +required: + - compatible + - reg + - interrupts + - clocks + +additionalProperties: false + +examples: + - | + #include <dt-bindings/clock/nuvoton,npcm7xx-clock.h> + #include <dt-bindings/interrupt-controller/arm-gic.h> + peci-controller@f0100000 { + compatible = "nuvoton,npcm750-peci"; + reg = <0xf0100000 0x200>; + interrupts = <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&clk NPCM7XX_CLK_APB3>; + cmd-timeout-ms = <1000>; + }; +...
Signature · 1 line
2.40.1
Re: [RFT PATCH 1/4] dt-bindings: Add bindings for peci-npcm
Quoted 8 lines · Iwona Winiarska
From: Tomer Maimon <[email protected]>
Add device tree bindings for the peci-npcm controller driver.
Signed-off-by Tomer Maimon <[email protected]>Signed-off-by kfting <[email protected]>Co-developed-by Iwona Winiarska <[email protected]>Signed-off-by Iwona Winiarska <[email protected]>
Please use scripts/get_maintainers.pl to get a list of necessary people and lists to CC. It might happen, that command when run on an older kernel, gives you outdated entries. Therefore please be sure you base your patches on recent Linux kernel.
You missed at least DT list (maybe more), so this won't be tested by our tools. Performing review on untested code might be a waste of time, thus I will skip this patch entirely till you follow the process allowing the patch to be tested.
Please kindly resend and include all necessary To/Cc entries.
Best regards,
Krzysztof
Winiarska, Iwona
maintainerRe: [RFT PATCH 1/4] dt-bindings: Add bindings for peci-npcm
Quoted 15 lines · Krzysztof Kozlowski
Quoted 8 lines · Iwona Winiarska
From: Tomer Maimon <[email protected]>
Add device tree bindings for the peci-npcm controller driver.
Signed-off-by Tomer Maimon <[email protected]>Signed-off-by kfting <[email protected]>Co-developed-by Iwona Winiarska <[email protected]>Signed-off-by Iwona Winiarska <[email protected]>Please use
scripts/get_maintainers.plto get a list of necessary people and lists to CC. It might happen, that command when run on an older kernel, gives you outdated entries. Therefore please be sure you base your patches on recent Linux kernel.
Quoted 4 lines
You missed at least DT list (maybe more), so this won't be tested by our tools. Performing review on untested code might be a waste of time, thus I will skip this patch entirely till you follow the process allowing the patch to be tested.
That was the idea behind marking it as "RFT", adding a note that "I wasn't able to test it on a real hardware so I would like to ask for help to test it on Nuvoton systems." in the cover letter, and sending it exclusively to OpenBMC mailinglist - to avoid wasting time on review before someone has a chance to run it on Nuvoton hardware.
-Iwona
Quoted 7 lines
Please kindly resend and include all necessary To/Cc entries.
Best regards,
Krzysztof
Re: [RFT PATCH 1/4] dt-bindings: Add bindings for peci-npcm
Quoted 16 lines · Iwona
Quoted 15 lines · Krzysztof Kozlowski
Quoted 8 lines · Iwona Winiarska
From: Tomer Maimon <[email protected]>
Add device tree bindings for the peci-npcm controller driver.
Signed-off-by Tomer Maimon <[email protected]>Signed-off-by kfting <[email protected]>Co-developed-by Iwona Winiarska <[email protected]>Signed-off-by Iwona Winiarska <[email protected]>Please use
scripts/get_maintainers.plto get a list of necessary people and lists to CC. It might happen, that command when run on an older kernel, gives you outdated entries. Therefore please be sure you base your patches on recent Linux kernel.
Quoted 8 lines
Quoted 4 lines
You missed at least DT list (maybe more), so this won't be tested by our tools. Performing review on untested code might be a waste of time, thus I will skip this patch entirely till you follow the process allowing the patch to be tested.
That was the idea behind marking it as "RFT", adding a note that "I wasn't able to test it on a real hardware so I would like to ask for help to test it on Nuvoton systems."
Which does not explain sending patch incorrect patch or patch which automation cannot test.
Quoted 3 lines
in the cover letter, and sending it exclusively to OpenBMC mailinglist - to avoid wasting time on review before someone has a chance to run it on Nuvoton hardware.
Usually such patches after receiving tested tags are immediately applied, so in that case your patch would be applied without review and our automation testing.
Anyway, fine, to be clear it cannot be applied:
NAK, patch is not correct
Best regards,
Krzysztof
Iwona Winiarska
maintainerPATCH 2/4 peci: Add peci-npcm controller driver
In reply to Iwona WiniarskaFrom: Tomer Maimon <[email protected]>
Add support for Nuvoton NPCM BMC hardware to the Platform Environment Control Interface (PECI) subsystem.
--- drivers/peci/controller/Kconfig | 16 ++ drivers/peci/controller/Makefile | 1 + drivers/peci/controller/peci-npcm.c | 298 ++++++++++++++++++++++++++++ 3 files changed, 315 insertions(+) create mode 100644 drivers/peci/controller/peci-npcm.c
drivers/peci/controller/Kconfig +16 -0
@@ -16,3 +16,19 @@ config PECI_ASPEED This driver can also be built as a module. If so, the module will be called peci-aspeed. + +config PECI_NPCM + tristate "Nuvoton NPCM PECI support" + depends on ARCH_NPCM || COMPILE_TEST + depends on OF + select REGMAP_MMIO + help + This option enables PECI controller driver for Nuvoton NPCM7XX + and NPCM8XX SoCs. It allows BMC to discover devices connected + to it and communicate with them using PECI protocol. + + Say Y here if you want support for the Platform Environment Control + Interface (PECI) bus adapter driver on the Nuvoton NPCM SoCs. + + This support is also available as a module. If so, the module + will be called peci-npcm.
drivers/peci/controller/Makefile +1 -0
@@ -1,3 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only obj-$(CONFIG_PECI_ASPEED) += peci-aspeed.o +obj-$(CONFIG_PECI_NPCM) += peci-npcm.o
drivers/peci/controller/peci-npcm.c new file +298 -0
298 lines not on this page · raw message
Signature · 1 line
2.40.1
Re: [RFT PATCH 2/4] peci: Add peci-npcm controller driver
Quoted 9 lines · Iwona Winiarska
From: Tomer Maimon <[email protected]>
Add support for Nuvoton NPCM BMC hardware to the Platform Environment Control Interface (PECI) subsystem.
Signed-off-by Tomer Maimon <[email protected]>Signed-off-by kfting <[email protected]>Co-developed-by Iwona Winiarska <[email protected]>Signed-off-by Iwona Winiarska <[email protected]>
...
drivers/peci/controller/peci-npcm.c line 281
Quoted 7 lines
drivers/peci/controller/peci-npcm.c new file +7
-0+ +return 0 ; +} + +static const struct of_device_id npcm_peci_of_table[] = { + { .compatible ="nuvoton,npcm750-peci" , }, + { .compatible ="nuvoton,npcm845-peci" , },
So they are compatible? Binding did not say that.
Best regards,
Krzysztof
Iwona Winiarska
maintainerPATCH 3/4 ARM: dts: nuvoton: Add PECI controller node
In reply to Iwona WiniarskaAdd PECI controller node with all required information.
--- arch/arm/boot/dts/nuvoton-common-npcm7xx.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+)
arch/arm/boot/dts/nuvoton-common-npcm7xx.dtsi +9 -0
@@ -220,6 +220,15 @@ kcs3: kcs3@0 { }; }; + peci0: peci-controller@f0100000 { + compatible = "nuvoton,npcm750-peci"; + reg = <0xf0100000 0x200>; + interrupts = <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&clk NPCM7XX_CLK_APB3>; + cmd-timeout-ms = <1000>; + status = "disabled"; + }; + spi0: spi@200000 { compatible = "nuvoton,npcm750-pspi"; reg = <0x200000 0x1000>;
Signature · 1 line
2.40.1
Iwona Winiarska
maintainerPATCH 4/4 arm64: dts: nuvoton: Add PECI controller node
In reply to Iwona WiniarskaAdd PECI controller node with all required information.
--- arch/arm64/boot/dts/nuvoton/nuvoton-common-npcm8xx.dtsi | 9 +++++++++ 1 file changed, 9 insertions(+)
arch/arm64/boot/dts/nuvoton/nuvoton-common-npcm8xx.dtsi +9 -0
@@ -68,6 +68,15 @@ apb { ranges = <0x0 0x0 0xf0000000 0x00300000>, <0xfff00000 0x0 0xfff00000 0x00016000>; + peci0: peci-controller@100000 { + compatible = "nuvoton,npcm845-peci"; + reg = <0x100000 0x1000>; + interrupts = <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&clk NPCM8XX_CLK_APB3>; + cmd-timeout-ms = <1000>; + status = "disabled"; + }; + timer0: timer@8000 { compatible = "nuvoton,npcm845-timer"; interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_HIGH>;
Signature · 1 line
2.40.1
Tomer Maimon
maintainerHi Iwona,
Thanks a lot for upstream Nuvoton PECI driver.
We will test the driver in a day or two and let you know.
Best regards,
Tomer
Quoted 38 lines · Iwona Winiarska
Hi!
This series is based on patches that were sent by Tomer Maimon from Nuvoton [1].
Similar to Aspeed driver, I removed vendor-specific properties that were not used (as in, default values were used in all of the available DTS files). If there is a use-case for such properties, they can be added in a separate series.
I wasn't able to test it on a real hardware so I would like to ask for help to test it on Nuvoton systems.Thanks
-Iwona[1] https://lore.kernel.org/openbmc/CAP6Zq1jnbQ8k9VEyf9WgVq5DRrEzf5V6kaYP30S7g9BV9jKtaQ@mail.gmail.com/
Iwona Winiarska (2):
ARM: dts: nuvoton: Add PECI controller node
arm64: dts: nuvoton: Add PECI controller nodeTomer Maimon (2):
dt-bindings: Add bindings for peci-npcm
peci: Add peci-npcm controller driver.../devicetree/bindings/peci/peci-npcm.yaml | 56 ++++ arch/arm/boot/dts/nuvoton-common-npcm7xx.dtsi | 9 + .../dts/nuvoton/nuvoton-common-npcm8xx.dtsi | 9 + drivers/peci/controller/Kconfig | 16 + drivers/peci/controller/Makefile | 1 + drivers/peci/controller/peci-npcm.c | 298 ++++++++++++++++++ 6 files changed, 389 insertions(+) create mode 100644 Documentation/devicetree/bindings/peci/peci-npcm.yaml create mode 100644 drivers/peci/controller/peci-npcm.c--
2.40.1
Tomer Maimon
maintainerHi Iwona,
The PECI driver has been tested on the NPCM750 Olympus system.
Please let me know if you need anything else.
Best regards,
Tomer
Quoted 50 lines · Tomer Maimon
Hi Iwona,
Thanks a lot for upstream Nuvoton PECI driver.
We will test the driver in a day or two and let you know.
Best regards,
Tomer
Quoted 38 lines · Iwona Winiarska
Hi!
This series is based on patches that were sent by Tomer Maimon from Nuvoton [1].
Similar to Aspeed driver, I removed vendor-specific properties that were not used (as in, default values were used in all of the available DTS files). If there is a use-case for such properties, they can be added in a separate series.
I wasn't able to test it on a real hardware so I would like to ask for help to test it on Nuvoton systems.Thanks
-Iwona[1] https://lore.kernel.org/openbmc/CAP6Zq1jnbQ8k9VEyf9WgVq5DRrEzf5V6kaYP30S7g9BV9jKtaQ@mail.gmail.com/
Iwona Winiarska (2):
ARM: dts: nuvoton: Add PECI controller node
arm64: dts: nuvoton: Add PECI controller nodeTomer Maimon (2):
dt-bindings: Add bindings for peci-npcm
peci: Add peci-npcm controller driver.../devicetree/bindings/peci/peci-npcm.yaml | 56 ++++ arch/arm/boot/dts/nuvoton-common-npcm7xx.dtsi | 9 + .../dts/nuvoton/nuvoton-common-npcm8xx.dtsi | 9 + drivers/peci/controller/Kconfig | 16 + drivers/peci/controller/Makefile | 1 + drivers/peci/controller/peci-npcm.c | 298 ++++++++++++++++++ 6 files changed, 389 insertions(+) create mode 100644 Documentation/devicetree/bindings/peci/peci-npcm.yaml create mode 100644 drivers/peci/controller/peci-npcm.c--
2.40.1