From patchwork Wed Jun 9 22:02:45 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Matthias Kaehlcke X-Patchwork-Id: 12311315 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-19.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A509AC48BD1 for ; Wed, 9 Jun 2021 22:04:13 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 87C80613F0 for ; Wed, 9 Jun 2021 22:04:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230246AbhFIWGH (ORCPT ); Wed, 9 Jun 2021 18:06:07 -0400 Received: from mail-pj1-f44.google.com ([209.85.216.44]:54207 "EHLO mail-pj1-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230152AbhFIWGB (ORCPT ); Wed, 9 Jun 2021 18:06:01 -0400 Received: by mail-pj1-f44.google.com with SMTP id ei4so2424142pjb.3 for ; Wed, 09 Jun 2021 15:03:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=6jiGScDFO2XxYhEoC2Vrk3Dt4e+9N07hRnYEMTleq1g=; b=VxhQIFEat/MDncMzO8pwQfVxbz3PC8IhkcSk8KIYf701sftcSmC8mm3OmtLGLndCTR 2JPChSv7H8fTqs5lxXSbD58Co0KdcUf+TpYYWm53ysLpWIz5kM8SFtz03zyPJ5oyLOpP +jn6+xgOxqlINHz88qaHcFpaOMnI7Txpjya64= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=6jiGScDFO2XxYhEoC2Vrk3Dt4e+9N07hRnYEMTleq1g=; b=bxUXsvhfdqJlZJ7eT234a5KBPYlVdZ52/6ONLBue26RCoXLWLds2VzSBq2jhk+8b+g eZFWy7chSDYXdGXlvCxF9fFiZfBQQsKBKFWGl1XRLf9NQGTZ7JQJ9mJ7tvPX9s+geGxw z69LmW4uOsVytEL9YeHbtU7rhQGCq6HKet+KFbQBjol0Qjg6fU9mXtoQhOxZ6qcrzLhs Nwg5ZB14GgOzAXZkszdAj0YFdP8BPzfkgx3AYA7hGFW1G8OTMcNHUOZgf8ndOyJP2Uwt HUaoVPZydbT+f90ooNv6CEYqRwLqeEDPO1sMIrCyKcpwm3LmTTyNYSrPiVCeHXXOqTXH AKJA== X-Gm-Message-State: AOAM5316l8B6NJ+2replVmF+mVXdd7LHaBccn6XMtJi1BixwhDjznfhb uoFJPLTtLz++YhrN97cr6jtPNQ== X-Google-Smtp-Source: ABdhPJx8yb5+ef4dZCcV2CIiXFNoL3tpQpThfz0vUQsyHCfBjgmVO6eF+3b2JxPtrhxukptDdMe0cA== X-Received: by 2002:a17:90a:fa4f:: with SMTP id dt15mr13028928pjb.30.1623276174580; Wed, 09 Jun 2021 15:02:54 -0700 (PDT) Received: from localhost ([2620:15c:202:201:cedb:c2b5:f22c:760]) by smtp.gmail.com with UTF8SMTPSA id x20sm436916pfu.205.2021.06.09.15.02.53 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 09 Jun 2021 15:02:54 -0700 (PDT) From: Matthias Kaehlcke To: Greg Kroah-Hartman , Alan Stern , Rob Herring , Frank Rowand , Mathias Nyman Cc: Peter Chen , Bastien Nocera , linux-usb@vger.kernel.org, devicetree@vger.kernel.org, Ravi Chandra Sadineni , Stephen Boyd , linux-kernel@vger.kernel.org, Michal Simek , Krzysztof Kozlowski , Douglas Anderson , Matthias Kaehlcke , Rob Herring Subject: [PATCH v12 1/5] dt-bindings: usb: Add binding for Realtek RTS5411 hub controller Date: Wed, 9 Jun 2021 15:02:45 -0700 Message-Id: <20210609150159.v12.1.I248292623d3d0f6a4f0c5bc58478ca3c0062b49a@changeid> X-Mailer: git-send-email 2.32.0.rc1.229.g3e70b5a671-goog In-Reply-To: <20210609220249.86061-1-mka@chromium.org> References: <20210609220249.86061-1-mka@chromium.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org The Realtek RTS5411 is a USB 3.0 hub controller with 4 ports. This initial version of the binding only describes USB related aspects of the RTS5411, it does not cover the option of connecting the controller as an i2c slave. Signed-off-by: Matthias Kaehlcke Reviewed-by: Rob Herring --- Changes in v12: - none Changes in v11: - none Changes in v10: - none Changes in v9: - added Rob's 'Reviewed-by' tag Changes in v8: - added entry for 'reg' - marked 'companion-hub' as required - changed node name of USB controller to 'usb' Changes in v7: - added type ref for 'companion-hub' property Changes in v6: - Realtek binding instead of generic onboard_usb_hub - added 'companion-hub' property - added reference to 'usb-device.yaml' - 'fixed' indentation of compatible entries to keep yamllint happy - added 'additionalProperties' entry - updated commit message Changes in v5: - updated 'title' - only use standard USB compatible strings - deleted 'usb_hub' node - renamed 'usb_controller' node to 'usb-controller' - removed labels from USB nodes - added 'vdd-supply' to USB nodes Changes in v4: - none Changes in v3: - updated commit message - removed recursive reference to $self - adjusted 'compatible' definition to support multiple entries - changed USB controller phandle to be a node Changes in v2: - removed 'wakeup-source' and 'power-off-in-suspend' properties - consistently use spaces for indentation in example .../bindings/usb/realtek,rts5411.yaml | 62 +++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 Documentation/devicetree/bindings/usb/realtek,rts5411.yaml diff --git a/Documentation/devicetree/bindings/usb/realtek,rts5411.yaml b/Documentation/devicetree/bindings/usb/realtek,rts5411.yaml new file mode 100644 index 000000000000..04ee255eb4f0 --- /dev/null +++ b/Documentation/devicetree/bindings/usb/realtek,rts5411.yaml @@ -0,0 +1,62 @@ +# SPDX-License-Identifier: GPL-2.0-only or BSD-2-Clause +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/usb/realtek,rts5411.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Binding for the Realtek RTS5411 USB 3.0 hub controller + +maintainers: + - Matthias Kaehlcke + +allOf: + - $ref: usb-device.yaml# + +properties: + compatible: + items: + - enum: + - usbbda,5411 + - usbbda,411 + + reg: true + + vdd-supply: + description: + phandle to the regulator that provides power to the hub. + + companion-hub: + $ref: '/schemas/types.yaml#/definitions/phandle' + description: + phandle to the companion hub on the controller. + +required: + - companion-hub + - compatible + - reg + +additionalProperties: false + +examples: + - | + usb { + dr_mode = "host"; + #address-cells = <1>; + #size-cells = <0>; + + /* 2.0 hub on port 1 */ + hub_2_0: hub@1 { + compatible = "usbbda,5411"; + reg = <1>; + vdd-supply = <&pp3300_hub>; + companion-hub = <&hub_3_0>; + }; + + /* 3.0 hub on port 2 */ + hub_3_0: hub@2 { + compatible = "usbbda,411"; + reg = <2>; + vdd-supply = <&pp3300_hub>; + companion-hub = <&hub_2_0>; + }; + };