From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-oi1-f177.google.com (mail-oi1-f177.google.com [209.85.167.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C84DB3C943E for ; Thu, 19 Mar 2026 14:58:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.177 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773932333; cv=none; b=EENui3/J6G4cObN1FnKmf8PHx5jjOgwwP5ZPV4WTUlMzCqAjVZmaVzNpUSBPX9soGqwpGSmXNI1FwvfRsdDJZVxb4pK7uRAQZflpbE4JqZWxLGjQPyYBLY/C3qULh1KSMlwjtzVMet8LlhM3LilmYHW3WtQRd4TkWaP+cRfqXbs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773932333; c=relaxed/simple; bh=mM0Qjq+/PhARnJ1OuOTZXrhsKNJy65FaO78/hLNdAgw=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=Ws7mg52T/yxT1LASh3spGvr1UnyEWTNG6tzf48YCB0QMkH5H8yl9WJa7NLdiQMo7D/4H4DWM29HEhs7ryKGRR1KD99q5GtD1S0Nrzy9cl/pvnoRpC8I5g77ku+PfZvaMs23XyPOGREPdCihUUGjBcR/e67wnI4ery/C3qMX2ZEg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=ZSOfnffm; arc=none smtp.client-ip=209.85.167.177 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="ZSOfnffm" Received: by mail-oi1-f177.google.com with SMTP id 5614622812f47-4670676ba03so309497b6e.1 for ; Thu, 19 Mar 2026 07:58:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1773932329; x=1774537129; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=PamUifGDxzKgYduTgi5+Bz1Hbj65Bi8zeh///fvaP8k=; b=ZSOfnffmH/dkxGYvWQoDZm6CezWNuce5MrgNhq9DdbZtYOxzl2PiC7WgovRE+RNbPq cybRtCbsgDJHUDg1PkmGa9WaWe+CF8KdgCL7qKhkdVlVpt+6vuNjkz6opKLcL9SHxLbN 0KDcK82KR/pyAMmCQEnEr8EQQHyUZI5qVMK0H4SLXN1STT9uVO6r4C4J8Ce+oyORbEQW LbUB0O9wvfMQPnxJzYVRitSK9PLpToAMZm6JpGNkxVNTDbqdCuxJ9Ed3tmpGSxvobMEM wMpI6tsBNom6r/mHSvs0oKculL3wbUtssG4tBqxiltvdt7MQfhKOEBX4VYEnmLkBfHO0 F62g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1773932329; x=1774537129; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=PamUifGDxzKgYduTgi5+Bz1Hbj65Bi8zeh///fvaP8k=; b=fTurVPa80oaFs6ztqR3tRW4ELCIqa5fQy5hjZYiMuNWAH9wxAhkJdt7/8s0n013yyA LDFOCdZrKeDTtVgsIJ+ToT5x7mCgSnSAk/K7lFRSuHUzk2IlUqHm4MMu876tSBXJsLzL GwKxSEF/HIo6EoLmpnUZ9OPTZi/0rtj5j6/WiEldY3gf+aRBaJP0FYm+NbY9WULQVBFG VovhRKao+nIbnsgHjomvF6fhrQS/3Gj10f0yPRygq0jGQg4Z2vH4VqWxidkRgqzN9jP9 ZaYhiAfKJoLh0hM+ERY1dUHdX9KYab/bx7sGNYfk62ukB2McnaOeh4m6n8pmv4B1PvjR PfGA== X-Forwarded-Encrypted: i=1; AJvYcCX34/4+vTf/l1A/DLVG7c7o4snbw6gfe2dPg5MCVHq93qHm06u8xJlWqyNA/7cypI/e2Px97fsH7DGxUxQ=@vger.kernel.org X-Gm-Message-State: AOJu0YyXwV0Qk23JxMsUXJjXys02n26WFrP+SgklrW2g+Mz6sJP4RWXS xONY+1EXso6JYAkU8tqZw0GeDjogm12Be+wytxUQpIJ0euBMT+KiU75foZ0eZ/tXvik= X-Gm-Gg: ATEYQzxjGouF7q/snuufXsksga067bmRj09GNI+/A61RITj0/XereoDVOgYQd9BC9sk d4rYdFZolh/A6f0O5TKwncKDyU6p5O7ANBgMUfvUp2XyiI4pPTQeTUOPrD4Dxf14I8OVx7xVyP8 fa5LWFGINikRc8XF30hMjgnweascpvYWJJgpxulFNk/k2HdBinFc42Bgm8xdxsBk8SqH9kCwbXF kZtc+Ik3aRzIc5E51IjjXFcUIDClmUJlCts8+hsRucMpIGOV218r3vFSse4iGIlm5mjp6EX6eN3 ZDU4RHTWvdddi5g099tMDIX6dIYztelLUm9u/5/LPzxJnupIU9hNsxhbZYqx02MizfUcJB15Ym4 tZVJBCvdce/yNoO+FC9il7XdE1gwW8yFPGPgJe+ECyC2fpM51ghezCwA4dnSAN5gY3lWTbHYIIn Cqu3Ta1g8adCmmaIc8BJznh2wLVBrO0GuY+1lxPENt7pfN6xbHtmUWu/bApeHeanQJkx5yGd6FI j8XA9Pw9HQk X-Received: by 2002:a05:6808:1451:b0:467:1cf5:7684 with SMTP id 5614622812f47-467ba15eaddmr4227888b6e.6.1773932328449; Thu, 19 Mar 2026 07:58:48 -0700 (PDT) Received: from ?IPV6:2600:8803:e7e4:500:244c:fc8c:8216:1344? ([2600:8803:e7e4:500:244c:fc8c:8216:1344]) by smtp.gmail.com with ESMTPSA id 586e51a60fabf-41bd22dee78sm6087744fac.0.2026.03.19.07.58.47 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 19 Mar 2026 07:58:47 -0700 (PDT) Message-ID: Date: Thu, 19 Mar 2026 09:58:46 -0500 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 5/5] dt-bindings: iio: adc: xilinx-xadc: convert to YAML format To: Sai Krishna Potthuri , Krzysztof Kozlowski Cc: Jonathan Cameron , Nuno Sa , Andy Shevchenko , Michal Simek , Rob Herring , Krzysztof Kozlowski , Conor Dooley , linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, saikrishna12468@gmail.com, git@amd.com References: <20260220053941.611415-1-sai.krishna.potthuri@amd.com> <20260220053941.611415-6-sai.krishna.potthuri@amd.com> <20260221-dancing-papaya-wolverine-db8afd@quoll> <21d425bc-9406-401b-9817-7255ba3d31fc@baylibre.com> Content-Language: en-US From: David Lechner In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit On 3/19/26 9:49 AM, Sai Krishna Potthuri wrote: > Hi David Lechner, > > On 3/19/2026 7:53 PM, David Lechner wrote: >> On 3/19/26 8:52 AM, Sai Krishna Potthuri wrote: >>> Hi Krzysztof, >>> >>> On 2/21/2026 4:08 PM, Krzysztof Kozlowski wrote: >>>> On Fri, Feb 20, 2026 at 11:09:41AM +0530, Sai Krishna Potthuri wrote: >>>>> Convert the xilinx-xadc.txt Devicetree binding to a YAML schema format >>>>> and remove the old text binding. >>>>> >>>>> + >>>>> +  xlnx,channels: >>>>> +    $ref: '#/$defs/channels' >>>>> + >>>>> +allOf: >>>> >>>> Missing ref since you use unevaluatedProperties... >>>> >>>>> +  - if: >>>>> +      required: >>>>> +        - xlnx,external-mux >>>>> +      properties: >>>>> +        xlnx,external-mux: >>>>> +          enum: >>>>> +            - single >>>>> +            - dual >>>>> +    then: >>>>> +      required: >>>>> +        - xlnx,external-mux-channel >>>>> + >>>>> +required: >>>>> +  - compatible >>>>> +  - reg >>>>> + >>>>> +unevaluatedProperties: false >>>> >>>> or you meant additionalProperties? >>>> >>>>> + >>>>> +$defs: >>>> >>>> Why this is a def, not used directly? I see only one usage of this def. >>> >>> I am getting the below error if i define the patternProperties directly. >>> Seems like complex vendor peroperties should be referenced via $ref. >>> Please suggest if there is any better way to deal this. >> >> It is hard to say without seeing the new version of what you wrote. > > In v1 series, i created $def and referenced this in xlnx,channels to avoid the error that i mentioned. Is the code below the code that causes the error? > > v1 code: >   xlnx,channels: >     $ref: '#/$defs/channels' > >   $defs: >   channels: Is this indent bug just from copying to email or does it exist in the source that is causing the error? >     type: object >     description: List of external channels that are connected to the ADC >     properties: >       '#address-cells': >         const: 1 >       '#size-cells': >         const: 0 > >     patternProperties: >       "^channel@([0-9]|1[0-6])$": >         type: object >         properties: >           reg: >             minimum: 0 >             maximum: 16 >             description: | >               Pair of pins the channel is connected to: >                 0: VP/VN >                 1-16: VAUXP[0-15]/VAUXN[0-15] >               Note each channel number should only be used at most once. > >           xlnx,bipolar: >             type: boolean >             description: If set, the channel is used in bipolar mode > >         required: >           - reg > >         unevaluatedProperties: false > >     required: >       - '#address-cells' >       - '#size-cells' > >     unevaluatedProperties: false > > > Regards > Sai krishna > > >> >> >> >>> >>> linux-xlnx/Documentation/devicetree/bindings/iio/adc/xilinx-xadc.yaml: properties:xlnx,channels:type: 'boolean' was expected >>>      hint: A vendor boolean property can use "type: boolean" >>>      from schema $id: http://devicetree.org/meta-schemas/vendor-props.yaml# >>>    LINT    ../Documentation/devicetree/bindings >>>    DTEX    Documentation/devicetree/bindings/iio/adc/xilinx-xadc.example.dts >>>    DTC [C] Documentation/devicetree/bindings/iio/adc/xilinx-xadc.example.dtb >>> >>> >>> Regards >>> Sai Krishna >>> >>>> >>>>> +  channels: >>>>> +    type: object >>>>> +    description: List of external channels that are connected to the ADC >>>>> +    properties: >>>>> +      '#address-cells': >>>>> +        const: 1 >>>>> +      '#size-cells': >>>>> +        const: 0 >>>>> + >>>>> +    patternProperties: >>>>> +      "^channel@([0-9]|1[0-6])$": >>>>> +        type: object >>>>> +        properties: >>>>> +          reg: >>>>> +            minimum: 0 >>>>> +            maximum: 16 >>>>> +            description: | >>>>> +              Pair of pins the channel is connected to: >>>>> +                0: VP/VN >>>>> +                1-16: VAUXP[0-15]/VAUXN[0-15] >>>>> +              Note each channel number should only be used at most once. >>>>> + >>>>> +          xlnx,bipolar: >>>>> +            type: boolean >>>>> +            description: If set, the channel is used in bipolar mode >>>>> + >>>>> +        required: >>>>> +          - reg >>>>> + >>>>> +        unevaluatedProperties: false >>>> >