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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 80668C433FE for ; Mon, 21 Feb 2022 11:31:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231432AbiBULbi (ORCPT ); Mon, 21 Feb 2022 06:31:38 -0500 Received: from mxb-00190b01.gslb.pphosted.com ([23.128.96.19]:47680 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1356454AbiBULbh (ORCPT ); Mon, 21 Feb 2022 06:31:37 -0500 Received: from smtp.domeneshop.no (smtp.domeneshop.no [IPv6:2a01:5b40:0:3005::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2D139CEC for ; Mon, 21 Feb 2022 03:31:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tronnes.org ; s=ds202112; h=Content-Transfer-Encoding:Content-Type:In-Reply-To:From: References:Cc:To:Subject:MIME-Version:Date:Message-ID:Sender:Reply-To: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=PoQ+bvT1gJMpzNe35fopScMyxUJOkfvO5PCdK+gnnEM=; b=qLjHJB+KR/MYJHLVQr7mDaDR9y DGb9qYDMQDQz+w09js3fUwR2+rmsBhnLG+zmTe1C/HrGYUZVpsbhGSytlzzO5sOuPqWW/4I7N+6uL 05jubqMQp66xrRgvQ4OB1HPxkB+EAldHog9lGSRa7/LN6w5ADX1vJKjw4kua2G3ZROYKgfAEVfXcn b6K5914ecsDd7rfN3EFJosJLPxHW6rlbCG8Kfh8n7SluJJt25wNBAYCT0wsSkarVUKuzY6+DPCUAa HHVyqaAsHFMhZneIZ3xpwU22z4PcYk2CrsI5TbpfXjwW0in8JvBZRVuy6U3BHeHa/frUwzhhgqxAm nA0aP92w==; Received: from [2a01:799:95e:a400:cca0:57ac:c55d:a485] (port=56049) by smtp.domeneshop.no with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nM6uN-0000bi-AQ; Mon, 21 Feb 2022 12:31:11 +0100 Message-ID: Date: Mon, 21 Feb 2022 12:31:08 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.5.1 Subject: Re: [PATCH v4 1/3] dt-bindings: display: add bindings for MIPI DBI compatible SPI panels To: robh+dt@kernel.org, maxime@cerno.tech Cc: sam@ravnborg.org, dave.stevenson@raspberrypi.com, david@lechnology.com, devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org, thierry.reding@gmail.com, =?UTF-8?Q?Noralf_Tr=c3=b8nnes?= References: <20220218151110.11316-1-noralf@tronnes.org> <20220218151110.11316-2-noralf@tronnes.org> From: =?UTF-8?Q?Noralf_Tr=c3=b8nnes?= In-Reply-To: <20220218151110.11316-2-noralf@tronnes.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Den 18.02.2022 16.11, skrev Noralf Trønnes: > Add binding for MIPI DBI compatible SPI panels. > > v4: > - There should only be two compatible (Maxime) > - s/panel-dbi-spi/panel-mipi-dbi-spi/in compatible > > v3: > - Move properties to Device Tree (Maxime) > - Use contains for compatible (Maxime) > - Add backlight property to example > - Flesh out description > > v2: > - Fix path for panel-common.yaml > - Use unevaluatedProperties > - Drop properties which are in the allOf section > - Drop model property (Rob) > > Acked-by: Maxime Ripard > Signed-off-by: Noralf Trønnes > --- > .../display/panel/panel-mipi-dbi-spi.yaml | 125 ++++++++++++++++++ > 1 file changed, 125 insertions(+) > create mode 100644 Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.yaml > > diff --git a/Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.yaml b/Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.yaml > new file mode 100644 > index 000000000000..748c09113168 > --- /dev/null > +++ b/Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.yaml > +allOf: > + - $ref: panel-common.yaml# > + - $ref: /schemas/spi/spi-peripheral-props.yaml# > + > +properties: > + compatible: > + items: > + - {} # Panel Specific Compatible > + - const: panel-mipi-dbi-spi > + Rob's bot uses a -m flag I didn't use, and with that the compatible fails: $ make DT_CHECKER_FLAGS=-m dt_binding_check DT_SCHEMA_FILES=Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.yaml CHKDT Documentation/devicetree/bindings/processed-schema-examples.json SCHEMA Documentation/devicetree/bindings/processed-schema-examples.json DTEX Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.example.dts DTC Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.example.dt.yaml CHECK Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.example.dt.yaml Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.example.dt.yaml:0:0: /example-0/spi/display@0: failed to match any schema with compatible: ['sainsmart18', 'panel-mipi-dbi-spi'] How can I write the compatible property to make the checker happy? Noralf. > + write-only: > + type: boolean > + description: > + Controller is not readable (ie. MISO is not wired up). > + > + dc-gpios: > + maxItems: 1 > + description: | > + Controller data/command selection (D/CX) in 4-line SPI mode. > + If not set, the controller is in 3-line SPI mode. > + > +required: > + - compatible > + - reg > + - panel-timing > + > +unevaluatedProperties: false > + > +examples: > + - | > + #include > + > + spi { > + #address-cells = <1>; > + #size-cells = <0>; > + > + display@0{ > + compatible = "sainsmart18", "panel-mipi-dbi-spi"; > + reg = <0>; > + spi-max-frequency = <40000000>; > + > + dc-gpios = <&gpio 24 GPIO_ACTIVE_HIGH>; > + reset-gpios = <&gpio 25 GPIO_ACTIVE_HIGH>; > + write-only; > + > + backlight = <&backlight>; > + > + width-mm = <35>; > + height-mm = <28>; > + > + panel-timing { > + hactive = <160>; > + vactive = <128>; > + hback-porch = <0>; > + vback-porch = <0>; > + > + clock-frequency = <0>; > + hfront-porch = <0>; > + hsync-len = <0>; > + vfront-porch = <0>; > + vsync-len = <0>; > + }; > + }; > + }; > + > +... 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (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 35BD1C433F5 for ; Mon, 21 Feb 2022 11:31:16 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 4836510E312; Mon, 21 Feb 2022 11:31:15 +0000 (UTC) Received: from smtp.domeneshop.no (smtp.domeneshop.no [IPv6:2a01:5b40:0:3005::1]) by gabe.freedesktop.org (Postfix) with ESMTPS id C426710E312 for ; Mon, 21 Feb 2022 11:31:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tronnes.org ; s=ds202112; h=Content-Transfer-Encoding:Content-Type:In-Reply-To:From: References:Cc:To:Subject:MIME-Version:Date:Message-ID:Sender:Reply-To: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=PoQ+bvT1gJMpzNe35fopScMyxUJOkfvO5PCdK+gnnEM=; b=qLjHJB+KR/MYJHLVQr7mDaDR9y DGb9qYDMQDQz+w09js3fUwR2+rmsBhnLG+zmTe1C/HrGYUZVpsbhGSytlzzO5sOuPqWW/4I7N+6uL 05jubqMQp66xrRgvQ4OB1HPxkB+EAldHog9lGSRa7/LN6w5ADX1vJKjw4kua2G3ZROYKgfAEVfXcn b6K5914ecsDd7rfN3EFJosJLPxHW6rlbCG8Kfh8n7SluJJt25wNBAYCT0wsSkarVUKuzY6+DPCUAa HHVyqaAsHFMhZneIZ3xpwU22z4PcYk2CrsI5TbpfXjwW0in8JvBZRVuy6U3BHeHa/frUwzhhgqxAm nA0aP92w==; Received: from [2a01:799:95e:a400:cca0:57ac:c55d:a485] (port=56049) by smtp.domeneshop.no with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nM6uN-0000bi-AQ; Mon, 21 Feb 2022 12:31:11 +0100 Message-ID: Date: Mon, 21 Feb 2022 12:31:08 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.5.1 Subject: Re: [PATCH v4 1/3] dt-bindings: display: add bindings for MIPI DBI compatible SPI panels To: robh+dt@kernel.org, maxime@cerno.tech References: <20220218151110.11316-1-noralf@tronnes.org> <20220218151110.11316-2-noralf@tronnes.org> From: =?UTF-8?Q?Noralf_Tr=c3=b8nnes?= In-Reply-To: <20220218151110.11316-2-noralf@tronnes.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, =?UTF-8?Q?Noralf_Tr=c3=b8nnes?= , david@lechnology.com, dave.stevenson@raspberrypi.com, dri-devel@lists.freedesktop.org, thierry.reding@gmail.com, sam@ravnborg.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Den 18.02.2022 16.11, skrev Noralf Trønnes: > Add binding for MIPI DBI compatible SPI panels. > > v4: > - There should only be two compatible (Maxime) > - s/panel-dbi-spi/panel-mipi-dbi-spi/in compatible > > v3: > - Move properties to Device Tree (Maxime) > - Use contains for compatible (Maxime) > - Add backlight property to example > - Flesh out description > > v2: > - Fix path for panel-common.yaml > - Use unevaluatedProperties > - Drop properties which are in the allOf section > - Drop model property (Rob) > > Acked-by: Maxime Ripard > Signed-off-by: Noralf Trønnes > --- > .../display/panel/panel-mipi-dbi-spi.yaml | 125 ++++++++++++++++++ > 1 file changed, 125 insertions(+) > create mode 100644 Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.yaml > > diff --git a/Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.yaml b/Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.yaml > new file mode 100644 > index 000000000000..748c09113168 > --- /dev/null > +++ b/Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.yaml > +allOf: > + - $ref: panel-common.yaml# > + - $ref: /schemas/spi/spi-peripheral-props.yaml# > + > +properties: > + compatible: > + items: > + - {} # Panel Specific Compatible > + - const: panel-mipi-dbi-spi > + Rob's bot uses a -m flag I didn't use, and with that the compatible fails: $ make DT_CHECKER_FLAGS=-m dt_binding_check DT_SCHEMA_FILES=Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.yaml CHKDT Documentation/devicetree/bindings/processed-schema-examples.json SCHEMA Documentation/devicetree/bindings/processed-schema-examples.json DTEX Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.example.dts DTC Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.example.dt.yaml CHECK Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.example.dt.yaml Documentation/devicetree/bindings/display/panel/panel-mipi-dbi-spi.example.dt.yaml:0:0: /example-0/spi/display@0: failed to match any schema with compatible: ['sainsmart18', 'panel-mipi-dbi-spi'] How can I write the compatible property to make the checker happy? Noralf. > + write-only: > + type: boolean > + description: > + Controller is not readable (ie. MISO is not wired up). > + > + dc-gpios: > + maxItems: 1 > + description: | > + Controller data/command selection (D/CX) in 4-line SPI mode. > + If not set, the controller is in 3-line SPI mode. > + > +required: > + - compatible > + - reg > + - panel-timing > + > +unevaluatedProperties: false > + > +examples: > + - | > + #include > + > + spi { > + #address-cells = <1>; > + #size-cells = <0>; > + > + display@0{ > + compatible = "sainsmart18", "panel-mipi-dbi-spi"; > + reg = <0>; > + spi-max-frequency = <40000000>; > + > + dc-gpios = <&gpio 24 GPIO_ACTIVE_HIGH>; > + reset-gpios = <&gpio 25 GPIO_ACTIVE_HIGH>; > + write-only; > + > + backlight = <&backlight>; > + > + width-mm = <35>; > + height-mm = <28>; > + > + panel-timing { > + hactive = <160>; > + vactive = <128>; > + hback-porch = <0>; > + vback-porch = <0>; > + > + clock-frequency = <0>; > + hfront-porch = <0>; > + hsync-len = <0>; > + vfront-porch = <0>; > + vsync-len = <0>; > + }; > + }; > + }; > + > +...