From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 12971CA100B for ; Sat, 31 Aug 2024 06:33:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: Content-Type:In-Reply-To:From:References:Cc:To:Subject:MIME-Version:Date: Message-ID:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=d9Rzt+4tVyO6A7F8Bor9w2nnjow7C66ElUeqHlOKA/4=; b=QfV33aaDQjE+cu5TbGY3LbYz45 9YHogucOTBdMYnfjYWByAxzoapajLCgiEvT4GlaulSnzl3YrRkulahUHOW4HS2AaRY8g/z17TjOw3 iT7r00DQDSPvlQwAtQS1f6PiLsdZOd9MRJ8Wnxs0b4OpgOnCCZ3BCy9nU9o8Gkb612Us0C8DTEeGt EvoCbAYgk6Hn0jGrKd7iAxBWNjhbHVbT70HZS2z0JcfjiLrlroVT8ZMl0FK5RomvXU2gHzhi8j3iz MD2ec7SfmCBYq38TzLc7XevAgynb+/Z1Ae0Hvpk0Wrei0xwg+PoEjhTT1jtaiOTjLUKbZs3ie+tk6 9k/KtKSg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1skHfq-00000008kM4-17xR; Sat, 31 Aug 2024 06:33:26 +0000 Received: from dfw.source.kernel.org ([2604:1380:4641:c500::1]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1skHey-00000008kIK-38Ce for linux-arm-kernel@lists.infradead.org; Sat, 31 Aug 2024 06:32:34 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by dfw.source.kernel.org (Postfix) with ESMTP id 4D9B55C463F; Sat, 31 Aug 2024 06:32:28 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5FB4FC4CEC0; Sat, 31 Aug 2024 06:32:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1725085951; bh=0SE4Y8e9pdsbKz+fTAQYhk11k5ecqn2Bkee2i4SanNs=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=FlSKY3EOZsKQESnZ2GqpbH4Ug1leeE0TXUyRKmSH0TSrEZvtXny1YMWejSHxIu7+x 286OHg5SOkEFS9on9D52/VCfZxGkdU2ARmu6HNAlBZq8OjFpItncF1WcuxuiV+z6xE oQLqUIynd7g5NpUd+zvnJuHNxhCEDo1xQHbmhQ4YFLnI0gwPctnfSVlyLyVjn+tHms ZjZAAI6eTH/bPscxpVpSzO/tFTXwvWZ1oac5Y4zxyMzfUxTenW5wzycFMSbhEA98Yn cGFIOguWj+Pcg64NUDjWMcA/3FQRzmRihflIwSyEgt1rnydL6V4/L6VhxfZ2RS1RKP 6AEm6NZFznLbQ== Message-ID: Date: Sat, 31 Aug 2024 08:32:23 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 2/2] dt-bindings: trivial-devices: Add a reference to spi-peripheral-props.yaml To: Rob Herring , Conor Dooley Cc: Fabio Estevam , broonie@kernel.org, linux-spi@vger.kernel.org, otavio.salvador@ossystems.com.br, heiko@sntech.de, krzk+dt@kernel.org, conor+dt@kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org References: <20240829201315.3412759-1-festevam@gmail.com> <20240829201315.3412759-2-festevam@gmail.com> <20240830-anchor-glucose-f8dcc1b0fd16@spud> <20240830-rockfish-shun-da3e42b69f1d@spud> <20240830180509.GA565970-robh@kernel.org> From: Krzysztof Kozlowski Content-Language: en-US Autocrypt: addr=krzk@kernel.org; keydata= xsFNBFVDQq4BEAC6KeLOfFsAvFMBsrCrJ2bCalhPv5+KQF2PS2+iwZI8BpRZoV+Bd5kWvN79 cFgcqTTuNHjAvxtUG8pQgGTHAObYs6xeYJtjUH0ZX6ndJ33FJYf5V3yXqqjcZ30FgHzJCFUu JMp7PSyMPzpUXfU12yfcRYVEMQrmplNZssmYhiTeVicuOOypWugZKVLGNm0IweVCaZ/DJDIH gNbpvVwjcKYrx85m9cBVEBUGaQP6AT7qlVCkrf50v8bofSIyVa2xmubbAwwFA1oxoOusjPIE J3iadrwpFvsZjF5uHAKS+7wHLoW9hVzOnLbX6ajk5Hf8Pb1m+VH/E8bPBNNYKkfTtypTDUCj NYcd27tjnXfG+SDs/EXNUAIRefCyvaRG7oRYF3Ec+2RgQDRnmmjCjoQNbFrJvJkFHlPeHaeS BosGY+XWKydnmsfY7SSnjAzLUGAFhLd/XDVpb1Een2XucPpKvt9ORF+48gy12FA5GduRLhQU vK4tU7ojoem/G23PcowM1CwPurC8sAVsQb9KmwTGh7rVz3ks3w/zfGBy3+WmLg++C2Wct6nM Pd8/6CBVjEWqD06/RjI2AnjIq5fSEH/BIfXXfC68nMp9BZoy3So4ZsbOlBmtAPvMYX6U8VwD TNeBxJu5Ex0Izf1NV9CzC3nNaFUYOY8KfN01X5SExAoVTr09ewARAQABzSVLcnp5c3p0b2Yg S296bG93c2tpIDxrcnprQGtlcm5lbC5vcmc+wsGVBBMBCgA/AhsDBgsJCAcDAgYVCAIJCgsE FgIDAQIeAQIXgBYhBJvQfg4MUfjVlne3VBuTQ307QWKbBQJgPO8PBQkUX63hAAoJEBuTQ307 QWKbBn8P+QFxwl7pDsAKR1InemMAmuykCHl+XgC0LDqrsWhAH5TYeTVXGSyDsuZjHvj+FRP+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plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240830_233232_903176_4CDCFB14 X-CRM114-Status: GOOD ( 21.08 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 30/08/2024 20:05, Rob Herring wrote: > On Fri, Aug 30, 2024 at 04:17:02PM +0100, Conor Dooley wrote: >> On Fri, Aug 30, 2024 at 12:05:20PM -0300, Fabio Estevam wrote: >>> Hi Conor, >>> >>> On Fri, Aug 30, 2024 at 11:14 AM Conor Dooley wrote: >>> >>>> Since those don't come from spi-peripheral-props, not really the correct >>>> justification (although why they don't, I'm not sure). If you still saw >>>> dtbs_check complaints after the first patch, I maybe the controller >>>> schema is missing a reference to spi-controller.yaml? >>> >>> I changed the first patch as suggested: >>> >>> --- a/Documentation/devicetree/bindings/spi/spi-peripheral-props.yaml >>> +++ b/Documentation/devicetree/bindings/spi/spi-peripheral-props.yaml >>> @@ -29,6 +29,10 @@ properties: >>> description: >>> Chip select used by the device. >>> >>> + spi-cpha: true >>> + >>> + spi-cpol: true >>> + >>> spi-cs-high: >>> $ref: /schemas/types.yaml#/definitions/flag >>> description: >>> >>> spi-rockchip.yaml does reference spi-controller.yaml, but I still get >>> dtbs_check complaints after the first patch. >>> >>> $ make CHECK_DTBS=y rockchip/rv1108-elgin-r1.dtb -j12 >>> UPD include/config/kernel.release >>> SCHEMA Documentation/devicetree/bindings/processed-schema.json >>> DTC [C] arch/arm/boot/dts/rockchip/rv1108-elgin-r1.dtb >>> /home/fabio/linux-next/arch/arm/boot/dts/rockchip/rv1108-elgin-r1.dtb: >>> display@0: 'spi-cpha', 'spi-cpol' do not match any of the regexes: >>> 'pinctrl-[0-9]+' >>> from schema $id: http://devicetree.org/schemas/trivial-devices.yaml# >>> >>> I would appreciate some suggestions on how to fix this warning. >> >> Ah, I think I suggested something garbage, because I misread the diff, >> as my quoted mail evidences. I was really trying to suggest putting >> spi-cpha: true >> spi-cpol: true >> in trivial-devices.yaml, but I didn't notice that the patch was to >> spi-peripheral-props rather than trivial-devices. These properties are >> defined (for reasons I don't quite understand) in spi-controller.yaml >> and applied to children of the controller node by that binding and I >> wanted to avoid the redefinition. > > I steered Fabio wrong... > > I think we originally had these in spi-peripheral-props, but then > decided they are properties of the device, not the controller. These > properties should really only be needed if the device supports different > modes. If what a device supports is fixed, then that can be implicit. > > There's one other case I see with "dh,dhcom-board". So I guess add > spi-cpha and spi-cpol directly to trivial-devices.yaml. I responded to v2 before reaching here. Are you sure that's intended? It's almost equal to the patch here: all trivial devices will have it, even if they do not need it. For a device requiring CPOL/CPHA, not having it (or the reverse) is a bug in DTS and basically we would miss such check for all trivial devices. Best regards, Krzysztof