soc: add NPCM BPC driver support
Subsystems (3)
Tomer Maimon
maintainerv3 cover soc: add NPCM BPC driver support
This patch set adds BIOS Post code (BPC) support for the Nuvoton NPCM Baseboard Management Controller (BMC).
Nuvoton BMC NPCM BIOS Post Code (BPC) monitoring two configurable I/O addresses written by the host on the bus, the capture data stored in 128-word FIFO.
NPCM BPC can support capture double words.
The NPCM BPC driver tested on NPCM750 Olympus board.
Addressed comments from:
- Krzysztof Kozlowski : https://www.spinics.net/lists/kernel/msg5035188.html
- Conor Dooley : https://www.spinics.net/lists/kernel/msg5034239.html
- kernel test robot : https://www.spinics.net/lists/kernel/msg5034970.html
Changes since version 2:
- Modify compatible bindings.
- Add more details to nuvoton,bpc-en-dwcapture parameter.
- Using _is_visible() function to support NPCM8XX.
- add __poll_t custom.
Changes since version 1:
- Remove LPC present from the BPC driver.
- Modify dt-bindings message header.
- Add vendor to the file name.
- Modify incorrect spelling.
Tomer Maimon (3):
dt-bindings: soc: nuvoton: Add NPCM BPC
soc: nuvoton: add configuration menu
soc: nuvoton: add NPCM BPC driver
.../soc/nuvoton/nuvoton,npcm-bpc.yaml | 65 +++ drivers/soc/nuvoton/Kconfig | 16 +- drivers/soc/nuvoton/Makefile | 1 + drivers/soc/nuvoton/npcm-bpc.c | 387 ++++++++++++++++++ 4 files changed, 468 insertions(+), 1 deletion(-) create mode 100644 Documentation/devicetree/bindings/soc/nuvoton/nuvoton,npcm-bpc.yaml create mode 100644 drivers/soc/nuvoton/npcm-bpc.c
Signature · 1 line
2.34.1
Tomer Maimon
maintainerPATCH v3 1/3 dt-bindings: soc: nuvoton: Add NPCM BPC
Added device tree binding documentation for Nuvoton BMC NPCM BIOS Post Code (BPC).
The NPCM BPC monitoring two configurable I/O addresses written by the host on the bus.
--- .../soc/nuvoton/nuvoton,npcm-bpc.yaml | 65 +++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 Documentation/devicetree/bindings/soc/nuvoton/nuvoton,npcm-bpc.yaml
Documentation/devicetree/bindings/soc/nuvoton/nuvoton,npcm-bpc.yaml new file +65 -0
@@ -0,0 +1,65 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/soc/nuvoton/nuvoton,npcm-bpc.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Nuvoton BMC NPCM BIOS Post Code (BPC) controller + +maintainers: + - Tomer Maimon <[email protected]> + +description: + Nuvoton BMC NPCM BIOS Post Code (BPC) monitoring two configurable I/O + addresses written by the host on the bus, the capture data stored in + 128-word FIFO. + + NPCM BPC supports capture double words, when using capture + double word only I/O address 1 is monitored. + +properties: + compatible: + items: + - enum: + - nuvoton,npcm845-bpc + - nuvoton,npcm750-bpc + - const: nuvoton,npcm-bpc + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + nuvoton,monitor-ports: + $ref: /schemas/types.yaml#/definitions/uint32-array + description: + Contain monitor I/O addresses on the bus, at least one monitor I/O + address required. + + nuvoton,bpc-en-dwcapture: + description: + Set DWCAPTURE bit in BPCFEN register that enable double words capture + according to the first address setting. + type: boolean + +required: + - compatible + - reg + - interrupts + - nuvoton,monitor-ports + +additionalProperties: false + +examples: + - | + #include <dt-bindings/interrupt-controller/irq.h> + #include <dt-bindings/interrupt-controller/arm-gic.h> + + bpc: bpc@f0007040 { + compatible = "nuvoton,npcm750-bpc", "nuvoton,npcm-bpc"; + reg = <0xf0007040 0x20>; + interrupts = <GIC_SPI 9 IRQ_TYPE_LEVEL_HIGH>; + nuvoton,monitor-ports = <0x80>; + }; +...
Signature · 1 line
2.34.1
Re: [PATCH v3 1/3] dt-bindings: soc: nuvoton: Add NPCM BPC
Quoted 6 lines · Tomer Maimon
Added device tree binding documentation for Nuvoton BMC NPCM BIOS Post Code (BPC).
The NPCM BPC monitoring two configurable I/O addresses written by the host on the bus.
You sent multiple same patchsets, so to make it clear:
NAK
Best regards,
Krzysztof
Tomer Maimon
maintainerPATCH v3 2/3 soc: nuvoton: add configuration menu
In reply to Tomer MaimonAdd menu configuration to Nuvoton SoC drivers.
--- drivers/soc/nuvoton/Kconfig | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
drivers/soc/nuvoton/Kconfig +6 -1
@@ -1,5 +1,8 @@ # SPDX-License-Identifier: GPL-2.0 -menuconfig WPCM450_SOC + +menu "NUVOTON SoC drivers" + +config WPCM450_SOC tristate "Nuvoton WPCM450 SoC driver" default y if ARCH_WPCM450 select SOC_BUS
@@ -9,3 +12,5 @@ menuconfig WPCM450_SOC This driver provides information such as the SoC model and revision. + +endmenu
Signature · 1 line
2.34.1
Tomer Maimon
maintainerPATCH v3 3/3 soc: nuvoton: add NPCM BPC driver
In reply to Tomer MaimonAdd Nuvoton BMC NPCM BIOS post code (BPC) driver.
The NPCM BPC monitoring two configurable I/O address written by the host on the bus.
--- drivers/soc/nuvoton/Kconfig | 9 + drivers/soc/nuvoton/Makefile | 1 + drivers/soc/nuvoton/npcm-bpc.c | 387 +++++++++++++++++++++++++++++++++ 3 files changed, 397 insertions(+) create mode 100644 drivers/soc/nuvoton/npcm-bpc.c
drivers/soc/nuvoton/Kconfig +9 -0
@@ -2,6 +2,15 @@ menu "NUVOTON SoC drivers" +config NPCM_BPC + tristate "NPCM BIOS Post Code support" + depends on (ARCH_NPCM || COMPILE_TEST) + help + Provides NPCM driver to control the BIOS Post Code + interface which allows the BMC to monitor and save + the data written by the host to an arbitrary I/O port, + the BPC is connected to the host thourgh LPC or eSPI bus. + config WPCM450_SOC tristate "Nuvoton WPCM450 SoC driver" default y if ARCH_WPCM450
drivers/soc/nuvoton/Makefile +1 -0
@@ -1,2 +1,3 @@ # SPDX-License-Identifier: GPL-2.0-only +obj-$(CONFIG_NPCM_BPC) += npcm-bpc.o obj-$(CONFIG_WPCM450_SOC) += wpcm450-soc.o
drivers/soc/nuvoton/npcm-bpc.c new file +387 -0
387 lines not on this page · raw message
Signature · 1 line
2.34.1