dt-bindings: sound: Convert TI OMAP2+ McBSP to DT schema
Subsystems (3)
PATCH 1/1 dt-bindings: sound: Convert TI OMAP2+ McBSP to DT schema
Convert the Texas Instruments OMAP2+ McBSP (Multi-Channel Buffered Serial Port) bindings to DT schema.
During the conversion, the following updates were made:
- Documented the 'clocks', 'clock-names', 'dmas', 'dma-names', '#sound-dai-cells' and 'port' properties, which are used by the boards but were missing from the old text binding.
- Added 'dma' to the 'reg-names' enum, which the boards use alongside 'mpu' and 'sidetone'.
- Changed 'ti,hwmods' to a string array of up to two entries, as some boards pass both the base and sidetone hwmods.
- Made 'ti,hwmods' optional to resolve dtbs_check warnings. Modern OMAP platforms no longer provide this property, while older platforms still use it.
- Made 'ti,buffer-size' optional, as it only applies to OMAP2430 and newer SoCs.
--- .../devicetree/bindings/sound/omap-mcbsp.txt | 36 ------- .../bindings/sound/ti,omap2-mcbsp.yaml | 101 ++++++++++++++++++ 2 files changed, 101 insertions(+), 36 deletions(-) delete mode 100644 Documentation/devicetree/bindings/sound/omap-mcbsp.txt create mode 100644 Documentation/devicetree/bindings/sound/ti,omap2-mcbsp.yaml
Documentation/devicetree/bindings/sound/omap-mcbsp.txt deleted +0 -36
@@ -1,36 +0,0 @@ -* Texas Instruments OMAP2+ McBSP module - -Required properties: -- compatible: "ti,omap2420-mcbsp" for McBSP on OMAP2420 - "ti,omap2430-mcbsp" for McBSP on OMAP2430 - "ti,omap3-mcbsp" for McBSP on OMAP3 - "ti,omap4-mcbsp" for McBSP on OMAP4 and newer SoC -- reg: Register location and size, for OMAP4+ as an array: - <MPU access base address, size>, - <L3 interconnect address, size>; -- reg-names: Array of strings associated with the address space -- interrupts: Interrupt numbers for the McBSP port, as an array in case the - McBSP IP have more interrupt lines: - <OCP compliant irq>, - <TX irq>, - <RX irq>; -- interrupt-names: Array of strings associated with the interrupt numbers -- ti,buffer-size: Size of the FIFO on the port (OMAP2430 and newer SoC) -- ti,hwmods: Name of the hwmod associated to the McBSP port - -Example: - -mcbsp2: mcbsp@49022000 { - compatible = "ti,omap3-mcbsp"; - reg = <0x49022000 0xff>, - <0x49028000 0xff>; - reg-names = "mpu", "sidetone"; - interrupts = <0 17 0x4>, /* OCP compliant interrupt */ - <0 62 0x4>, /* TX interrupt */ - <0 63 0x4>, /* RX interrupt */ - <0 4 0x4>; /* Sidetone */ - interrupt-names = "common", "tx", "rx", "sidetone"; - interrupt-parent = <&intc>; - ti,buffer-size = <1280>; - ti,hwmods = "mcbsp2"; -};
Documentation/devicetree/bindings/sound/ti,omap2-mcbsp.yaml new file +101 -0
101 lines not on this page · raw message
Signature · 1 line
2.43.0
[email protected]
AI reviewThank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider: - [Low] The newly introduced device tree schema incorrectly restricts `interrupt-names`, causing validation…
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] The newly introduced device tree schema incorrectly restricts interrupt-names, causing validation failures for existing device trees. --
--- Patch [1]: [PATCH] dt-bindings: sound: Convert TI OMAP2+ McBSP to DT schema --- commit 76198b04e7315bea741fd54b86bf3bc924be8575
Author: Eduard Bostina <[email protected]>
dt-bindings: sound: Convert TI OMAP2+ McBSP to DT schema
Convert the Texas Instruments OMAP2+ McBSP (Multi-Channel Buffered Serial Port) bindings to DT schema.
Quoted 5 lines
Documentation/devicetree/bindings/sound/ti,omap2-mcbsp.yaml new file +0
-0
[ ... ]
Documentation/devicetree/bindings/sound/ti,omap2-mcbsp.yaml line 42
Quoted 9 lines
Documentation/devicetree/bindings/sound/ti,omap2-mcbsp.yaml new file +9
-0+ interrupts: + minItems: 1 + maxItems: 4 + + interrupt-names: + minItems: 1 + maxItems: 4 + items: + enum: [common, tx, rx, sidetone]
[Severity: Low]
Does this enum incorrectly restrict the allowed interrupt names?
Looking at arch/arm/boot/dts/ti/omap/omap2430.dtsi, the mcbsp1 node legitimately uses an rx_overflow interrupt name:
interrupt-names = "common", "tx", "rx", "rx_overflow";
Since rx_overflow is omitted from the allowed items in this binding, will this cause dtbs_check validation failures for existing device trees?
Signature · 1 line
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=1
Mark Brown
maintainerQuoted 2 lines · Eduard Bostina
Convert the Texas Instruments OMAP2+ McBSP (Multi-Channel Buffered Serial Port) bindings to DT schema.
Please submit patches using subject lines reflecting the style for the subsystem, this makes it easier for people to identify relevant patches. Look at what existing commits in the area you're changing are doing and make sure your subject lines visually resemble what they're doing. There's no need to resubmit to fix this alone.