Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp148627ybv; Wed, 5 Feb 2020 03:04:37 -0800 (PST) X-Google-Smtp-Source: APXvYqwUcjDAjC6iX6iJPZhZuOMUHJe6qS4IuNsna6SXjEJ7KuGJGW3Zz7qBOMGWXT87QsBTgwyF X-Received: by 2002:aca:2109:: with SMTP id 9mr2260468oiz.119.1580900677741; Wed, 05 Feb 2020 03:04:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1580900677; cv=none; d=google.com; s=arc-20160816; b=rA32uSjbJyZoJ6V5/dbYzGTZfpeku0d3Zjcf5of1cAmreWGnOpcuaUd00WzXRMcdbj vKA6UoUOEl7VEChAhFHdt23hj3ip+C0nMVIc5y5iPYwIeFJm9gY6DysrsZfOzh/vvqcp q+pBbL/9xTBQyekpZOu0kjVxd1xL5eOLyG/1XbBYscJvXHLZ+7IbPgjjkG6HKDt1L4z1 XUct8UuX30QhtYLc+MfJP4n+9syldNWOA/42I6GZjRpDk3ZKrNySqZls9Hd/7WEBVbcI NHo4Rmy5kGitzns1KCXzUM1FYU6zsHfSX3aTnB7wGtpCIye1cziXcCPrw2IFhN9l2VAH RcCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=BQQKmxNw/IFf95CncsdIS3abBuBcGhqdQQrRUP+sOPE=; b=iyJX/OlO1igoGGiBT/ptqhGCIy5BwBTl8tnPD2MINBRh4JoCYauNUoGnmcp0wIRCrd mo4mDqiCqbSZPmO1RnJbV3W96GZMREzBlQrzkxSHpfzW6yK+YBTEmpU+lhwsEBd962xC Mu5O/Hg2GzVvUmByof4oYfGaGjecrSV32fKgo4MmNl+LniQlfe62OVZkqPLO2WRpxbbs ZevhRYCMWXhZehNYawuVHsxioQG++P11cC7IAVajhmy6pkL6Z6PTlx7AcmVeAha12HHb 3YfMP36DXwRcwK28kRlp3v6hAlHh3K/nrdPbnXzfYVD0gaU0RFwOWgYmR/Q+uC/YIDqJ /QBA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m12si11238679oim.195.2020.02.05.03.03.59; Wed, 05 Feb 2020 03:04:37 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728373AbgBELAn (ORCPT + 99 others); Wed, 5 Feb 2020 06:00:43 -0500 Received: from bhuna.collabora.co.uk ([46.235.227.227]:52062 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727562AbgBELAn (ORCPT ); Wed, 5 Feb 2020 06:00:43 -0500 Received: from localhost.localdomain (p200300CB87166A00C93B781DBBC01C5E.dip0.t-ipconnect.de [IPv6:2003:cb:8716:6a00:c93b:781d:bbc0:1c5e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: dafna) by bhuna.collabora.co.uk (Postfix) with ESMTPSA id 32C8B2913B4; Wed, 5 Feb 2020 11:00:40 +0000 (GMT) From: Dafna Hirschfeld To: devicetree@vger.kernel.org Cc: myungjoo.ham@samsung.com, cw00.choi@samsung.com, robh+dt@kernel.org, mark.rutland@arm.com, bleung@chromium.org, enric.balletbo@collabora.com, groeck@chromium.org, linux-kernel@vger.kernel.org, dafna.hirschfeld@collabora.com, helen.koike@collabora.com, ezequiel@collabora.com, kernel@collabora.com, dafna3@gmail.com Subject: [PATCH v2] dt-bindings: convert extcon-usbc-cros-ec.txt extcon-usbc-cros-ec.yaml Date: Wed, 5 Feb 2020 12:00:28 +0100 Message-Id: <20200205110029.3395-1-dafna.hirschfeld@collabora.com> X-Mailer: git-send-email 2.17.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org convert the binding file extcon-usbc-cros-ec.txt to yaml format This was tested and verified on ARM with: make dt_binding_check DT_SCHEMA_FILES=Documentation/devicetree/bindings/extcon/extcon-usbc-cros-ec.yaml make dtbs_check DT_SCHEMA_FILES=Documentation/devicetree/bindings/extcon/extcon-usbc-cros-ec.yaml Signed-off-by: Dafna Hirschfeld --- Changes since v1: 1 - changing the license to (GPL-2.0-only OR BSD-2-Clause) 2 - changing the maintainers 3 - changing the google,usb-port-id property to have minimum 0 and maximum 255 .../bindings/extcon/extcon-usbc-cros-ec.txt | 24 ---------- .../bindings/extcon/extcon-usbc-cros-ec.yaml | 45 +++++++++++++++++++ 2 files changed, 45 insertions(+), 24 deletions(-) delete mode 100644 Documentation/devicetree/bindings/extcon/extcon-usbc-cros-ec.txt create mode 100644 Documentation/devicetree/bindings/extcon/extcon-usbc-cros-ec.yaml diff --git a/Documentation/devicetree/bindings/extcon/extcon-usbc-cros-ec.txt b/Documentation/devicetree/bindings/extcon/extcon-usbc-cros-ec.txt deleted file mode 100644 index 8e8625c00dfa..000000000000 --- a/Documentation/devicetree/bindings/extcon/extcon-usbc-cros-ec.txt +++ /dev/null @@ -1,24 +0,0 @@ -ChromeOS EC USB Type-C cable and accessories detection - -On ChromeOS systems with USB Type C ports, the ChromeOS Embedded Controller is -able to detect the state of external accessories such as display adapters -or USB devices when said accessories are attached or detached. - -The node for this device must be under a cros-ec node like google,cros-ec-spi -or google,cros-ec-i2c. - -Required properties: -- compatible: Should be "google,extcon-usbc-cros-ec". -- google,usb-port-id: Specifies the USB port ID to use. - -Example: - cros-ec@0 { - compatible = "google,cros-ec-i2c"; - - ... - - extcon { - compatible = "google,extcon-usbc-cros-ec"; - google,usb-port-id = <0>; - }; - } diff --git a/Documentation/devicetree/bindings/extcon/extcon-usbc-cros-ec.yaml b/Documentation/devicetree/bindings/extcon/extcon-usbc-cros-ec.yaml new file mode 100644 index 000000000000..fd95e413d46f --- /dev/null +++ b/Documentation/devicetree/bindings/extcon/extcon-usbc-cros-ec.yaml @@ -0,0 +1,45 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/extcon/extcon-usbc-cros-ec.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: ChromeOS EC USB Type-C cable and accessories detection + +maintainers: + - Benson Leung + - Enric Balletbo i Serra + +description: | + On ChromeOS systems with USB Type C ports, the ChromeOS Embedded Controller is + able to detect the state of external accessories such as display adapters + or USB devices when said accessories are attached or detached. + The node for this device must be under a cros-ec node like google,cros-ec-spi + or google,cros-ec-i2c. + +properties: + compatible: + const: google,extcon-usbc-cros-ec + + google,usb-port-id: + allOf: + - $ref: /schemas/types.yaml#/definitions/uint32 + description: the port id + minimum: 0 + maximum: 255 + +required: + - compatible + - google,usb-port-id + +additionalProperties: false + +examples: + - | + cros-ec@0 { + compatible = "google,cros-ec-i2c"; + extcon { + compatible = "google,extcon-usbc-cros-ec"; + google,usb-port-id = <0>; + }; + }; -- 2.17.1