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

dt-bindings: Remove more cases of 'allOf' containing a '$ref'

Another wack-a-mole pass of killing off unnecessary 'allOf + $ref'
usage.

json-schema versions draft7 and earlier have a weird behavior in that
any keywords combined with a '$ref' are ignored (silently). The correct
form was to put a '$ref' under an 'allOf'. This behavior is now changed
in the 2019-09 json-schema spec and '$ref' can be mixed with other
keywords. The json-schema library doesn't yet support this, but the
tooling now does a fixup for this and either way works.

This has been a constant source of review comments, so let's change this
treewide so everyone copies the simpler syntax.

Signed-off-by: Rob Herring <robh@kernel.org>

+49 -70
+1 -2
Documentation/devicetree/bindings/display/brcm,bcm2835-hdmi.yaml
··· 32 32 - const: hdmi 33 33 34 34 ddc: 35 - allOf: 36 - - $ref: /schemas/types.yaml#/definitions/phandle 35 + $ref: /schemas/types.yaml#/definitions/phandle 37 36 description: > 38 37 Phandle of the I2C controller used for DDC EDID probing 39 38
+1 -2
Documentation/devicetree/bindings/iio/adc/qcom,spmi-vadc.yaml
··· 97 97 input signal is multiplied. For example, <1 3> indicates the signal is scaled 98 98 down to 1/3 of its value before ADC measurement. 99 99 If property is not found default value depending on chip will be used. 100 - allOf: 101 - - $ref: /schemas/types.yaml#/definitions/uint32-array 100 + $ref: /schemas/types.yaml#/definitions/uint32-array 102 101 oneOf: 103 102 - items: 104 103 - const: 1
+13 -15
Documentation/devicetree/bindings/interrupt-controller/mti,gic.yaml
··· 42 42 Specifies the list of CPU interrupt vectors to which the GIC may not 43 43 route interrupts. This property is ignored if the CPU is started in EIC 44 44 mode. 45 - allOf: 46 - - $ref: /schemas/types.yaml#definitions/uint32-array 47 - - minItems: 1 48 - maxItems: 6 49 - uniqueItems: true 50 - items: 51 - minimum: 2 52 - maximum: 7 45 + $ref: /schemas/types.yaml#definitions/uint32-array 46 + minItems: 1 47 + maxItems: 6 48 + uniqueItems: true 49 + items: 50 + minimum: 2 51 + maximum: 7 53 52 54 53 mti,reserved-ipi-vectors: 55 54 description: | ··· 56 57 It accepts two values: the 1st is the starting interrupt and the 2nd is 57 58 the size of the reserved range. If not specified, the driver will 58 59 allocate the last (2 * number of VPEs in the system). 59 - allOf: 60 - - $ref: /schemas/types.yaml#definitions/uint32-array 61 - - items: 62 - - minimum: 0 63 - maximum: 254 64 - - minimum: 2 65 - maximum: 254 60 + $ref: /schemas/types.yaml#definitions/uint32-array 61 + items: 62 + - minimum: 0 63 + maximum: 254 64 + - minimum: 2 65 + maximum: 254 66 66 67 67 timer: 68 68 type: object
+20 -23
Documentation/devicetree/bindings/media/i2c/dongwoon,dw9768.yaml
··· 38 38 dongwoon,aac-mode: 39 39 description: 40 40 Indication of AAC mode select. 41 - allOf: 42 - - $ref: "/schemas/types.yaml#/definitions/uint32" 43 - - enum: 44 - - 1 # AAC2 mode(operation time# 0.48 x Tvib) 45 - - 2 # AAC3 mode(operation time# 0.70 x Tvib) 46 - - 3 # AAC4 mode(operation time# 0.75 x Tvib) 47 - - 5 # AAC8 mode(operation time# 1.13 x Tvib) 48 - default: 2 41 + $ref: "/schemas/types.yaml#/definitions/uint32" 42 + enum: 43 + - 1 # AAC2 mode(operation time# 0.48 x Tvib) 44 + - 2 # AAC3 mode(operation time# 0.70 x Tvib) 45 + - 3 # AAC4 mode(operation time# 0.75 x Tvib) 46 + - 5 # AAC8 mode(operation time# 1.13 x Tvib) 47 + default: 2 49 48 50 49 dongwoon,aac-timing: 51 50 description: 52 51 Number of AAC Timing count that controlled by one 6-bit period of 53 52 vibration register AACT[5:0], the unit of which is 100 us. 54 - allOf: 55 - - $ref: "/schemas/types.yaml#/definitions/uint32" 56 - - default: 0x20 57 - minimum: 0x00 58 - maximum: 0x3f 53 + $ref: "/schemas/types.yaml#/definitions/uint32" 54 + default: 0x20 55 + minimum: 0x00 56 + maximum: 0x3f 59 57 60 58 dongwoon,clock-presc: 61 59 description: 62 60 Indication of VCM internal clock dividing rate select, as one multiple 63 61 factor to calculate VCM ring periodic time Tvib. 64 - allOf: 65 - - $ref: "/schemas/types.yaml#/definitions/uint32" 66 - - enum: 67 - - 0 # Dividing Rate - 2 68 - - 1 # Dividing Rate - 1 69 - - 2 # Dividing Rate - 1/2 70 - - 3 # Dividing Rate - 1/4 71 - - 4 # Dividing Rate - 8 72 - - 5 # Dividing Rate - 4 73 - default: 1 62 + $ref: "/schemas/types.yaml#/definitions/uint32" 63 + enum: 64 + - 0 # Dividing Rate - 2 65 + - 1 # Dividing Rate - 1 66 + - 2 # Dividing Rate - 1/2 67 + - 3 # Dividing Rate - 1/4 68 + - 4 # Dividing Rate - 8 69 + - 5 # Dividing Rate - 4 70 + default: 1 74 71 75 72 required: 76 73 - compatible
+1 -2
Documentation/devicetree/bindings/pci/ti,j721e-pci-ep.yaml
··· 31 31 ti,syscon-pcie-ctrl: 32 32 description: Phandle to the SYSCON entry required for configuring PCIe mode 33 33 and link speed. 34 - allOf: 35 - - $ref: /schemas/types.yaml#/definitions/phandle 34 + $ref: /schemas/types.yaml#/definitions/phandle 36 35 37 36 power-domains: 38 37 maxItems: 1
+1 -2
Documentation/devicetree/bindings/pci/ti,j721e-pci-host.yaml
··· 31 31 ti,syscon-pcie-ctrl: 32 32 description: Phandle to the SYSCON entry required for configuring PCIe mode 33 33 and link speed. 34 - allOf: 35 - - $ref: /schemas/types.yaml#/definitions/phandle 34 + $ref: /schemas/types.yaml#/definitions/phandle 36 35 37 36 power-domains: 38 37 maxItems: 1
+2 -4
Documentation/devicetree/bindings/sound/maxim,max98390.yaml
··· 18 18 description: I2C address of the device. 19 19 20 20 maxim,temperature_calib: 21 - allOf: 22 - - $ref: /schemas/types.yaml#/definitions/uint32 23 21 description: The calculated temperature data was measured while doing the calibration. 22 + $ref: /schemas/types.yaml#/definitions/uint32 24 23 minimum: 0 25 24 maximum: 65535 26 25 27 26 maxim,r0_calib: 28 - allOf: 29 - - $ref: /schemas/types.yaml#/definitions/uint32 30 27 description: This is r0 calibration data which was measured in factory mode. 28 + $ref: /schemas/types.yaml#/definitions/uint32 31 29 minimum: 1 32 30 maximum: 8388607 33 31
+1 -2
Documentation/devicetree/bindings/sound/nvidia,tegra186-dspk.yaml
··· 48 48 49 49 sound-name-prefix: 50 50 pattern: "^DSPK[1-9]$" 51 - allOf: 52 - - $ref: /schemas/types.yaml#/definitions/string 51 + $ref: /schemas/types.yaml#/definitions/string 53 52 description: 54 53 Used as prefix for sink/source names of the component. Must be a 55 54 unique string among multiple instances of the same component.
+1 -2
Documentation/devicetree/bindings/sound/nvidia,tegra210-dmic.yaml
··· 49 49 50 50 sound-name-prefix: 51 51 pattern: "^DMIC[1-9]$" 52 - allOf: 53 - - $ref: /schemas/types.yaml#/definitions/string 52 + $ref: /schemas/types.yaml#/definitions/string 54 53 description: 55 54 used as prefix for sink/source names of the component. Must be a 56 55 unique string among multiple instances of the same component.
+1 -2
Documentation/devicetree/bindings/sound/nvidia,tegra210-i2s.yaml
··· 67 67 68 68 sound-name-prefix: 69 69 pattern: "^I2S[1-9]$" 70 - allOf: 71 - - $ref: /schemas/types.yaml#/definitions/string 70 + $ref: /schemas/types.yaml#/definitions/string 72 71 description: 73 72 Used as prefix for sink/source names of the component. Must be a 74 73 unique string among multiple instances of the same component.
+2 -4
Documentation/devicetree/bindings/sound/ti,j721e-cpb-audio.yaml
··· 37 37 38 38 ti,cpb-mcasp: 39 39 description: phandle to McASP used on CPB 40 - allOf: 41 - - $ref: /schemas/types.yaml#/definitions/phandle 40 + $ref: /schemas/types.yaml#/definitions/phandle 42 41 43 42 ti,cpb-codec: 44 43 description: phandle to the pcm3168a codec used on the CPB 45 - allOf: 46 - - $ref: /schemas/types.yaml#/definitions/phandle 44 + $ref: /schemas/types.yaml#/definitions/phandle 47 45 48 46 clocks: 49 47 items:
+5 -10
Documentation/devicetree/bindings/sound/ti,j721e-cpb-ivi-audio.yaml
··· 50 50 51 51 ti,cpb-mcasp: 52 52 description: phandle to McASP used on CPB 53 - allOf: 54 - - $ref: /schemas/types.yaml#/definitions/phandle 53 + $ref: /schemas/types.yaml#/definitions/phandle 55 54 56 55 ti,cpb-codec: 57 56 description: phandle to the pcm3168a codec used on the CPB 58 - allOf: 59 - - $ref: /schemas/types.yaml#/definitions/phandle 57 + $ref: /schemas/types.yaml#/definitions/phandle 60 58 61 59 ti,ivi-mcasp: 62 60 description: phandle to McASP used on IVI 63 - allOf: 64 - - $ref: /schemas/types.yaml#/definitions/phandle 61 + $ref: /schemas/types.yaml#/definitions/phandle 65 62 66 63 ti,ivi-codec-a: 67 64 description: phandle to the pcm3168a-A codec on the expansion board 68 - allOf: 69 - - $ref: /schemas/types.yaml#/definitions/phandle 65 + $ref: /schemas/types.yaml#/definitions/phandle 70 66 71 67 ti,ivi-codec-b: 72 68 description: phandle to the pcm3168a-B codec on the expansion board 73 - allOf: 74 - - $ref: /schemas/types.yaml#/definitions/phandle 69 + $ref: /schemas/types.yaml#/definitions/phandle 75 70 76 71 clocks: 77 72 items: