From patchwork Mon Mar 20 07:59:41 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Baolin Wang X-Patchwork-Id: 740831 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@bilbo.ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 3vmpKr49tjz9s2s for ; Mon, 20 Mar 2017 19:01:04 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="QAP8yQIJ"; dkim-atps=neutral Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752346AbdCTIBC (ORCPT ); Mon, 20 Mar 2017 04:01:02 -0400 Received: from mail-pg0-f49.google.com ([74.125.83.49]:34922 "EHLO mail-pg0-f49.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751149AbdCTIBB (ORCPT ); Mon, 20 Mar 2017 04:01:01 -0400 Received: by mail-pg0-f49.google.com with SMTP id t143so7499010pgb.2 for ; Mon, 20 Mar 2017 01:00:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=V8/s/HS/Vwf8k8elw20N3dYsEQLLOFmeOma8xyKemWA=; b=QAP8yQIJ08a5ayW8dcN9M21KBklKkIdxbipuqaReMTqb5Pemx6Szh4nG/bCMQfLQYT Y3BOk3bYSa2NTE86qOFp170kctyFnOpaQBxvKrU7fyxpOz73V87mFfgbiDP0M6Kx5grp 4unYdraMdJcyw1MkC9GJnlyk7w24n1XyZPO2I= 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; bh=V8/s/HS/Vwf8k8elw20N3dYsEQLLOFmeOma8xyKemWA=; b=ijcw2PX0Qyq0klmt0hbMrABvCbDZMFDxePjgBb2CkBKrJj/VOJQoGwv8cH2Mn/Y5xM Mm0wXvBEN60/fhsmXM3cDj4vu7OFt+SvsCtohEsC11H8t8nnYdCHDB4UxESjvTJzwAk5 bbLMvI8W2CgSaI5Ev7tSNyptyRM0QNUWHUJ0mKQnXJWqP7Q2cYZRmOjbX9+JSwjOjCEk oF5BbhbByhjAswRC03XK5/M0d13iEehanaX5FnbLI7e9NpK6wPP3MQvl+X5MP9vpt/90 NVloKxNCzeydr5V4SRYTzzwcGBipC4cMMhxpoha1rOiPSrZ9sejHGCeJ2uMO6t8N0CHE tQNw== X-Gm-Message-State: AFeK/H2O+u6CHiWur1jv5IoGYJHXUAIuTfrvJl9xK84NUnDrRXDVaR95JsDrqIHNYvlzjuHX X-Received: by 10.84.177.36 with SMTP id w33mr37550041plb.105.1489996805969; Mon, 20 Mar 2017 01:00:05 -0700 (PDT) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.82]) by smtp.gmail.com with ESMTPSA id j62sm31406340pgc.54.2017.03.20.01.00.02 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 20 Mar 2017 01:00:05 -0700 (PDT) From: Baolin Wang To: myungjoo.ham@samsung.com, cw00.choi@samsung.com, robh+dt@kernel.org, mark.rutland@arm.com Cc: broonie@kernel.org, baolin.wang@linaro.org, linaro-kernel@lists.linaro.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org Subject: [PATCH 1/2] extcon: usb-gpio: Add level trigger support Date: Mon, 20 Mar 2017 15:59:41 +0800 Message-Id: <0db99bd509c94ea8a80f633022d15235a99391a9.1489995966.git.baolin.wang@linaro.org> X-Mailer: git-send-email 1.7.9.5 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Now extcon-usb-gpio only supports for GPIO egdge trigger, but VBUS/ID gpios' detection can be triggered by the level trigger on some platforms. Thus intoduce one property 'extcon-gpio,level-trigger' to identify this situation. Signed-off-by: Baolin Wang --- .../devicetree/bindings/extcon/extcon-usb-gpio.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Documentation/devicetree/bindings/extcon/extcon-usb-gpio.txt b/Documentation/devicetree/bindings/extcon/extcon-usb-gpio.txt index dfc14f7..191504b 100644 --- a/Documentation/devicetree/bindings/extcon/extcon-usb-gpio.txt +++ b/Documentation/devicetree/bindings/extcon/extcon-usb-gpio.txt @@ -9,6 +9,9 @@ Required properties: Either one of id-gpio or vbus-gpio must be present. Both can be present as well. - id-gpio: gpio for USB ID pin. See gpio binding. - vbus-gpio: gpio for USB VBUS pin. +- extcon-gpio,level-trigger: Boolean, set this gpio's interrupt flag to +level trigger. If not specified defaults to false, gpio's interrupt flag +defaults to edge trigger. Example: Examples of extcon-usb-gpio node in dra7-evm.dts as listed below: extcon_usb1 {