Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp2308266rwl; Thu, 6 Apr 2023 08:29:11 -0700 (PDT) X-Google-Smtp-Source: AKy350YtYq1tYyOP0Lwggjzmv3gZ23Aeo74rGsYS36K2bkR/lYMn6IiSy1XxU1Q6RWfTMH8/OJWu X-Received: by 2002:a17:906:4a12:b0:931:d36f:8965 with SMTP id w18-20020a1709064a1200b00931d36f8965mr7275399eju.13.1680794951191; Thu, 06 Apr 2023 08:29:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680794951; cv=none; d=google.com; s=arc-20160816; b=nC8sCazPpc0GsPB1jyZV+emi5zTtvFlHPRZKR7g6/LsCHG3yjdYVZtpaU3gZATnaju XgP1AnUGgAKxF7i6DJBu9bRu4MqwoIJ2It0wSHlpzuFWqAp5SvznpYCOX4mchi5BqEi4 vMNA/NMcB8RPOTeA6Oq4gfHtYSmBdzb1wiKhTj9cDb85iyjMh4eGqB6Zn9azmfXGe9W/ o6w7Y+eX8ROqbVfNXvyv4jA4k/93M6kNVXg6AVWiSd99rhiYpAmSUcljUZhrsFIgfyMl de/KO2RKwS7ZD8RUZtdGFlVYIVnwG2ybpqPXqFZo5XSv4uYB6qwqhg/MhaCcCEgxiRRg iEUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=DaH4L1i/JuWu0RboKl6tYhjCF4zs4iv94Q8hNFPaJg4=; b=hLYpz4t2NiQAS8r4ewALX4sjwTCGL7IuRe7dmk0Oe3oPbF/tksjlDPhxgbaAobVbOw NcTS+sWvxir6XLMJN+6HqWnfQPjreseljUqt0pfIgPsLuzfThZtKOJHdC5Q9/3JaI+i0 RgKeKap+xB48kHMs+iYrfsa5OFgPnf4sMMspYuA6PcHJ4XCUpDo5V90neJN7c89dz4xG kkbxxlhF0ZLHgOTqPKTC//q01KRYMBYccBvMEKuQYUpkvEqMv6IFfKS5fYTjW4QffSHW /7xXDjswunHFMRC84KHBprmXvjkRduU1JuyXccNZCwGsCMRbJ4TGJobDdZ0RN/GWemMQ y0ow== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z12-20020a170906434c00b009476f9ececesi1327160ejm.890.2023.04.06.08.28.46; Thu, 06 Apr 2023 08:29:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239702AbjDFPPz (ORCPT + 99 others); Thu, 6 Apr 2023 11:15:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42440 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238190AbjDFPPu (ORCPT ); Thu, 6 Apr 2023 11:15:50 -0400 Received: from mail-oa1-f44.google.com (mail-oa1-f44.google.com [209.85.160.44]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id ECFA87EC9; Thu, 6 Apr 2023 08:15:45 -0700 (PDT) Received: by mail-oa1-f44.google.com with SMTP id 586e51a60fabf-177b78067ffso42688284fac.7; Thu, 06 Apr 2023 08:15:45 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1680794145; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=DaH4L1i/JuWu0RboKl6tYhjCF4zs4iv94Q8hNFPaJg4=; b=Ni32ixHq/ooPoHREelgq4e9FUcf0mKIMeRT8G2bvQcJlNUt2xwHCmJphM/teKS1Dhp myRr1PKo/U8frsVp+kBUJvVa3P/gittQWykcxS9SzDNQA2fcbzBhWdPOgjMeuEmqaEAk d+DDv0Q7fnMr9UgqI2VZHopEIbUorZa9aDWlqThoyts8wUb1HK2D4eA0pxqm2pT0G749 Qgv82Qg6M5ig7hSMRUkWVG6N+dOmknGZOhelcgxjMJ8i7Uw5fzmYZ1zO4HNFsFE5B1DV 9UqgpHF+ll3Vzwr+TPYiXYWSgTLB0iHrCmrPbsJIa0B3i3zSHApqSz99UYdrXrDZVa8x HTlw== X-Gm-Message-State: AAQBX9duozU6YGZ9aA5e/2bhg+idMq9njIK3RFfmvp1H9nnx6L5JZp4d x/37r4hgfXxsIkedvkSl4g== X-Received: by 2002:a05:6871:14d:b0:17a:f6df:7f21 with SMTP id z13-20020a056871014d00b0017af6df7f21mr5346178oab.2.1680794144957; Thu, 06 Apr 2023 08:15:44 -0700 (PDT) Received: from robh_at_kernel.org (66-90-144-107.dyn.grandenetworks.net. [66.90.144.107]) by smtp.gmail.com with ESMTPSA id f11-20020a9d7b4b000000b0069d602841e7sm755208oto.72.2023.04.06.08.15.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 06 Apr 2023 08:15:44 -0700 (PDT) Received: (nullmailer pid 3114304 invoked by uid 1000); Thu, 06 Apr 2023 15:15:43 -0000 Date: Thu, 6 Apr 2023 10:15:43 -0500 From: Rob Herring To: Pin-yen Lin Cc: Andrzej Hajda , Neil Armstrong , Robert Foss , Laurent Pinchart , Jonas Karlman , Jernej Skrabec , David Airlie , Daniel Vetter , Krzysztof Kozlowski , Andy Shevchenko , Daniel Scally , Heikki Krogerus , Sakari Ailus , Greg Kroah-Hartman , "Rafael J . Wysocki" , Prashant Malani , Benson Leung , Guenter Roeck , Xin Ji , Marek Vasut , Hsin-Yi Wang , Thomas Zimmermann , AngeloGioacchino Del Regno , Lyude Paul , devicetree@vger.kernel.org, Stephen Boyd , dri-devel@lists.freedesktop.org, linux-acpi@vger.kernel.org, chrome-platform@lists.linux.dev, =?UTF-8?B?TsOtY29sYXMgRiAuIFIgLiBBIC4gUHJhZG8=?= , Javier Martinez Canillas , linux-kernel@vger.kernel.org, Allen Chen Subject: Re: [PATCH v15 08/10] dt-bindings: display: bridge: it6505: Add mode-switch support Message-ID: <20230406151543.GA3098002-robh@kernel.org> References: <20230331091145.737305-1-treapking@chromium.org> <20230331091145.737305-9-treapking@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230331091145.737305-9-treapking@chromium.org> X-Spam-Status: No, score=0.7 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 31, 2023 at 05:11:43PM +0800, Pin-yen Lin wrote: > ITE IT6505 can be used in systems to switch the DP traffic between > two downstreams, which can be USB Type-C DisplayPort alternate mode > lane or regular DisplayPort output ports. > > Update the binding to accommodate this usage by introducing a > data-lanes and a mode-switch property on endpoints. > > Signed-off-by: Pin-yen Lin > > --- > > (no changes since v12) > > Changes in v12: > - Fixed the schema of "data-lanes" property for it6505 > - Reworded the description of the mode-switch property > > Changes in v11: > - Updated the description of the endpoints in the bindings > - Referenced video-interfaces.yaml instead for the endpoints binding > - Removed duplicated definitions from inherited schema > > Changes in v9: > - Fixed subject prefix again > - Changed the naming of the example node for it6505 > > Changes in v8: > - Updated bindings for data-lanes property > - Fixed subject prefix > > Changes in v7: > - Fixed issues reported by dt_binding_check. > - Updated the schema and the example dts for data-lanes. > - Changed to generic naming for the example dts node. > > Changes in v6: > - Remove switches node and use endpoints and data-lanes property to > describe the connections. > > .../bindings/display/bridge/ite,it6505.yaml | 101 +++++++++++++++--- > 1 file changed, 88 insertions(+), 13 deletions(-) > > diff --git a/Documentation/devicetree/bindings/display/bridge/ite,it6505.yaml b/Documentation/devicetree/bindings/display/bridge/ite,it6505.yaml > index c9a882ee6d98..348b02f26041 100644 > --- a/Documentation/devicetree/bindings/display/bridge/ite,it6505.yaml > +++ b/Documentation/devicetree/bindings/display/bridge/ite,it6505.yaml > @@ -75,22 +75,49 @@ properties: > port@1: > $ref: /schemas/graph.yaml#/$defs/port-base > unevaluatedProperties: false > - description: Video port for DP output > + description: > + Video port for DP output. Each endpoint connects to a video output > + downstream, and the "data-lanes" property is used to describe the pin > + connections. 0, 1, 2, 3 in "data-lanes" maps to TX0, TX1, TX2, TX3, > + respectively. > > - properties: > - endpoint: > - $ref: /schemas/graph.yaml#/$defs/endpoint-base > + > + patternProperties: > + "^endpoint@[01]$": > + $ref: /schemas/media/video-interfaces.yaml# > unevaluatedProperties: false > > properties: > + reg: true > + > + remote-endpoint: true You don't need to list these 2. > + > data-lanes: > - minItems: 1 > - uniqueItems: true > - items: > - - enum: [ 0, 1 ] > - - const: 1 > - - const: 2 > - - const: 3 > + oneOf: > + - items: > + - enum: [0, 3] Only lane 1 wasn't valid? If so, mention that in the commit message. > + > + - items: > + - const: 0 > + - const: 1 > + > + - items: > + - const: 3 > + - const: 2 > + > + - items: > + - const: 0 > + - const: 1 > + - const: 2 > + - const: 3 Isn't this the default if 'data-lanes' is omitted. > + > + mode-switch: > + type: boolean > + description: Serves as Type-C mode switch if present. > + > + required: > + - reg > + - remote-endpoint required can be dropped. > > required: > - port@0 > @@ -102,7 +129,6 @@ required: > - pwr18-supply > - interrupts > - reset-gpios > - - extcon > - ports > > additionalProperties: false > @@ -139,8 +165,11 @@ examples: > }; > > port@1 { > + #address-cells = <1>; > + #size-cells = <0>; > reg = <1>; > - it6505_out: endpoint { > + it6505_out: endpoint@0 { > + reg = <0>; > remote-endpoint = <&dp_in>; > data-lanes = <0 1>; > }; > @@ -148,3 +177,49 @@ examples: > }; > }; > }; > + - | > + #include > + > + i2c { Why do we need a whole new example? Just extend the existing example with new properties/nodes. Rob