Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp1411165pxk; Thu, 10 Sep 2020 14:50:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxLPkfsDBWBSd8SPlw8OY4dqSKy034u7uuOjZk3NSumw5qxBRL33regVmSMIC1ceA6exry5 X-Received: by 2002:a17:906:a251:: with SMTP id bi17mr10804738ejb.526.1599774643727; Thu, 10 Sep 2020 14:50:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599774643; cv=none; d=google.com; s=arc-20160816; b=VqOUP/5uaN9Gvb4ePjXR1X3axsOYayPLLUy8MkwU3sLqQRMPHkzzMc0oWhXvGOJ4b9 zbqOWYao8EiUK1nuyUXxT0QkA7d8cs5JWgRk1t3WalG5lqBP1i62SI4IbgUku+GLRKdf buhUQR/pUu267doKyL9aCXgIU5lp7i3PCi3GL5Xo7fbZQ/bmS73OnUaawIbMqzwFrRHl P+Gb3Cyha3AE1748vpqL8dC3mr1xiq1YQ/+hozKT1C5MxGM1wW/+CrcfxSsUL4MdrG4y FzfBHW+aU99eCqF57m5ZX7Nfo1+MXVrZPETw2OjBQQqAZ2b1ymBjtPHaVGJZQ6cOuWCp RQ1Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=KdxAmy3KpsyIoUeNdOX9rvuUo0F0R1AFc/cMthukhEs=; b=DF7ceVQzIgg+HtwfOiVvCujH+rRU8CLaK9eF4G1ye38+vu2udTTEDxVPETpEa2cok/ wRvSh3ep4OIEMAIThQP67lifXjmGFWj9ejTYG0Y3Rwq+1PbC2C5GS6rMvpcgjf5YNj4C ZHLRTN9ZRmfiUxbRIWb4V65KWBwmFjY7T/+TvnGRi4NqHmIkzzJ0W2fVbRoywDIJ2cBP OoeEGDyHmmWSRr4pynPa/mn2dwnljq6cPmdwD3m2J/wQezUJThlviNQ0J0xiOiET2Etv eNd6OZyUY3VpgcAbD11fkOW2JpTfL6MjYHyJYOjno0VxLRpy7B4VV8W31T7Dqw00Fck6 Cl2g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id qc23si4380589ejb.25.2020.09.10.14.50.21; Thu, 10 Sep 2020 14:50:43 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728804AbgIJVof (ORCPT + 99 others); Thu, 10 Sep 2020 17:44:35 -0400 Received: from alexa-out.qualcomm.com ([129.46.98.28]:32804 "EHLO alexa-out.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730553AbgIJMy7 (ORCPT ); Thu, 10 Sep 2020 08:54:59 -0400 Received: from ironmsg07-lv.qualcomm.com (HELO ironmsg07-lv.qulacomm.com) ([10.47.202.151]) by alexa-out.qualcomm.com with ESMTP; 10 Sep 2020 05:54:58 -0700 Received: from ironmsg01-blr.qualcomm.com ([10.86.208.130]) by ironmsg07-lv.qulacomm.com with ESMTP/TLS/AES256-SHA; 10 Sep 2020 05:54:56 -0700 Received: from c-skakit-linux.ap.qualcomm.com (HELO c-skakit-linux.qualcomm.com) ([10.242.51.242]) by ironmsg01-blr.qualcomm.com with ESMTP; 10 Sep 2020 18:24:31 +0530 Received: by c-skakit-linux.qualcomm.com (Postfix, from userid 2344709) id 794584401; Thu, 10 Sep 2020 18:24:30 +0530 (IST) From: satya priya To: Bjorn Andersson Cc: Matthias Kaehlcke , gregkh@linuxfoundation.org, Andy Gross , Rob Herring , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, akashast@codeaurora.org, rojay@codeaurora.org, msavaliy@qti.qualcomm.com, dianders@chromium.org, satya priya Subject: [PATCH V5 3/4] arm64: dts: qcom: sc7180-trogdor: Add pinctrl and interrupt config for BT UART Date: Thu, 10 Sep 2020 18:23:57 +0530 Message-Id: <1599742438-16811-4-git-send-email-skakit@codeaurora.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1599742438-16811-1-git-send-email-skakit@codeaurora.org> References: <1599742438-16811-1-git-send-email-skakit@codeaurora.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add a suitable sleep configuration for uart3 to support Bluetooth wakeup. If QUP function is selected in sleep state, UART RTS/RFR is pulled high during suspend and BT SoC not able to send wakeup bytes. So, configure GPIO mode in sleep state to keep it low during suspend. Signed-off-by: satya priya --- Changes in V5: - Newly added in V5. This patch adds wakeup support for trogdor board files. arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi | 48 ++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi b/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi index a6b9beb..96b5331 100644 --- a/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi +++ b/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi @@ -792,6 +792,11 @@ ap_spi_fp: &spi10 { #include &uart3 { + pinctrl-names = "default", "sleep"; + pinctrl-1 = <&qup_uart3_sleep>; + interrupts-extended = <&intc GIC_SPI 604 IRQ_TYPE_LEVEL_HIGH>, + <&tlmm 41 IRQ_TYPE_EDGE_FALLING>; + status = "okay"; bluetooth: bluetooth { @@ -1345,4 +1350,47 @@ ap_spi_fp: &spi10 { drive-strength = <2>; }; }; + + qup_uart3_sleep: qup-uart3-sleep { + pinmux { + pins = "gpio38", "gpio39", + "gpio40", "gpio41"; + function = "gpio"; + }; + + pinconf-cts { + /* + * Configure a pull-down on CTS to match the pull of + * the Bluetooth module. + */ + pins = "gpio38"; + bias-pull-down; + }; + + pinconf-rts { + /* + * Configure pull-down on RTS to make sure that the BT SoC can + * wake up the system by sending wakeup bytes during suspend. + */ + pins = "gpio39"; + bias-pull-down; + }; + + pinconf-tx { + /* Configure pull-up on TX when it isn't actively driven */ + pins = "gpio40"; + bias-pull-up; + }; + + pinconf-rx { + /* + * Configure a pull-up on RX. This is needed to avoid + * garbage data when the TX pin of the Bluetooth module is + * in tri-state (module powered off or not driving the + * signal yet). + */ + pins = "gpio41"; + bias-pull-up; + }; + }; }; -- QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by The Linux Foundation