Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: ipmi: Convert ASPEED KCS binding to schema

Given the deprecated binding, improve the ability to detect issues in
the platform devicetrees. Further, a subsequent patch will introduce a
new interrupts property for specifying SerIRQ behaviour, so convert
before we do any further additions.

Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
Reviewed-by: Rob Herring <robh@kernel.org>
Reviewed-by: Zev Weiss <zweiss@equinix.com>
Message-Id: <20210608104757.582199-13-andrew@aj.id.au>
Signed-off-by: Corey Minyard <cminyard@mvista.com>

authored by

Andrew Jeffery and committed by
Corey Minyard
e880275c 3a3d2f6a

+92 -33
+92
Documentation/devicetree/bindings/ipmi/aspeed,ast2400-kcs-bmc.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/ipmi/aspeed,ast2400-kcs-bmc.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: ASPEED BMC KCS Devices 8 + 9 + maintainers: 10 + - Andrew Jeffery <andrew@aj.id.au> 11 + 12 + description: | 13 + The Aspeed BMC SoCs typically use the Keyboard-Controller-Style (KCS) 14 + interfaces on the LPC bus for in-band IPMI communication with their host. 15 + 16 + properties: 17 + compatible: 18 + oneOf: 19 + - description: Channel ID derived from reg 20 + items: 21 + enum: 22 + - aspeed,ast2400-kcs-bmc-v2 23 + - aspeed,ast2500-kcs-bmc-v2 24 + - aspeed,ast2600-kcs-bmc 25 + 26 + - description: Old-style with explicit channel ID, no reg 27 + deprecated: true 28 + items: 29 + enum: 30 + - aspeed,ast2400-kcs-bmc 31 + - aspeed,ast2500-kcs-bmc 32 + 33 + interrupts: 34 + maxItems: 1 35 + 36 + reg: 37 + # maxItems: 3 38 + items: 39 + - description: IDR register 40 + - description: ODR register 41 + - description: STR register 42 + 43 + aspeed,lpc-io-reg: 44 + $ref: '/schemas/types.yaml#/definitions/uint32-array' 45 + minItems: 1 46 + maxItems: 2 47 + description: | 48 + The host CPU LPC IO data and status addresses for the device. For most 49 + channels the status address is derived from the data address, but the 50 + status address may be optionally provided. 51 + 52 + kcs_chan: 53 + deprecated: true 54 + $ref: '/schemas/types.yaml#/definitions/uint32' 55 + description: The LPC channel number in the controller 56 + 57 + kcs_addr: 58 + deprecated: true 59 + $ref: '/schemas/types.yaml#/definitions/uint32' 60 + description: The host CPU IO map address 61 + 62 + required: 63 + - compatible 64 + - interrupts 65 + 66 + additionalProperties: false 67 + 68 + allOf: 69 + - if: 70 + properties: 71 + compatible: 72 + contains: 73 + enum: 74 + - aspeed,ast2400-kcs-bmc 75 + - aspeed,ast2500-kcs-bmc 76 + then: 77 + required: 78 + - kcs_chan 79 + - kcs_addr 80 + else: 81 + required: 82 + - reg 83 + - aspeed,lpc-io-reg 84 + 85 + examples: 86 + - | 87 + kcs3: kcs@24 { 88 + compatible = "aspeed,ast2600-kcs-bmc"; 89 + reg = <0x24 0x1>, <0x30 0x1>, <0x3c 0x1>; 90 + aspeed,lpc-io-reg = <0xca2>; 91 + interrupts = <8>; 92 + };
-33
Documentation/devicetree/bindings/ipmi/aspeed-kcs-bmc.txt
··· 1 - # Aspeed KCS (Keyboard Controller Style) IPMI interface 2 - 3 - The Aspeed SOCs (AST2400 and AST2500) are commonly used as BMCs 4 - (Baseboard Management Controllers) and the KCS interface can be 5 - used to perform in-band IPMI communication with their host. 6 - 7 - ## v1 8 - Required properties: 9 - - compatible : should be one of 10 - "aspeed,ast2400-kcs-bmc" 11 - "aspeed,ast2500-kcs-bmc" 12 - - interrupts : interrupt generated by the controller 13 - - kcs_chan : The LPC channel number in the controller 14 - - kcs_addr : The host CPU IO map address 15 - 16 - ## v2 17 - Required properties: 18 - - compatible : should be one of 19 - "aspeed,ast2400-kcs-bmc-v2" 20 - "aspeed,ast2500-kcs-bmc-v2" 21 - - reg : The address and size of the IDR, ODR and STR registers 22 - - interrupts : interrupt generated by the controller 23 - - aspeed,lpc-io-reg : The host CPU LPC IO address for the device 24 - 25 - Example: 26 - 27 - kcs3: kcs@24 { 28 - compatible = "aspeed,ast2500-kcs-bmc-v2"; 29 - reg = <0x24 0x1>, <0x30 0x1>, <0x3c 0x1>; 30 - aspeed,lpc-reg = <0xca2>; 31 - interrupts = <8>; 32 - status = "okay"; 33 - };