On Sat, 31 Oct 2020 17:58:36 +0100 Lukas Wunner <lukas@xxxxxxxxx> wrote: > On Sat, Oct 31, 2020 at 01:40:57PM +0000, Jonathan Cameron wrote: > > + spi-cpha: true > > + spi-cpol: > > + description: > > + Should be either spi-cpha, or spi-cpol but not both. > > Do the YAML files follow RFC 2119 terminology? If so, this is a > "must", not a "should". (As it was in the txt file.) I'll fix that whilst applying if it is all we have outstanding. This is an information comment only as the actual enforcement is below. > > > > +required: > > + - compatible > > + - reg > > + - vref-supply > > This is missing "spi-cpha xor spi-cpol", not sure if it can be > specified here using the xor YAML trick. It has to be specified in a separate block as far as I can tell. That is done further down the file. I've tested all the combinations and xor is enforced. +allOf: + - $ref: '#/definitions/cpolXORcpha' + +definitions: + cpolXORcpha: + not: + required: [spi-cpha, spi-cpol] + oneOf: + - required: + - spi-cpha + - required: + - spi-cpol + > > Thanks, > > Lukas