Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp1858625ybh; Thu, 23 Jul 2020 21:00:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzfWQ0uS/xPyJ+MQGFszw7Ek90VEG7CeNEvhtsYQ99pNxarfmi5Mp1L5o1fd7fT/mz3PPGt X-Received: by 2002:aa7:c545:: with SMTP id s5mr7067860edr.19.1595563202119; Thu, 23 Jul 2020 21:00:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595563202; cv=none; d=google.com; s=arc-20160816; b=ZqzJJBy7lAy/g00D8+oA9cxvOVXpi312TK6R3YKNop9Rxi/ZL1Q4BxLGblbLjoFWmh SmENc/wwdFjHbN7MLmd5ObG/PW29pQh4WQH5ojXhn9S9PRWANbEmthhbVjaO9mj6m0yX KAt0adJH6MW/uArS3Kmu1nX897iS12Rqennv3rQE1r/0ZAmAp3WbJ6D3K5ew9URWO3ty 2fsAOYMhtdpaMXaJzTbwmaxiZJbv/C1oN9fAyUUfxzqC0itb4N8tSUG7s/odZR8Bmn69 GNa8sJp7rwsOKj4xH+X5w93pyGFAyydzYFZvv7+kdaprh9bVA4TcvkoGPwhhtZbB3hQl T+mw== 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=KSOMKRyIi6nzjk6Xv83URL+/yJvlS6Qyi4u2Aei/mzs=; b=np8iy1TY2k46d53b4kdUtysTeMYps+mTHJx53za4ruS9Wxv0Kc4qiL0duGq5dCE7+i 55smA6hdIpjDlclLgx/6cj2/AAs69RMrxdWPdnfmXN5WEl0c41m1xEjJxN8YgFKkWBuR rEGYTf+1a7E/hZcPt/Sff5G4Jfn+PyCZR8sCK0AG07nuAyQQABN/9/G62Ahzl2UkfJJS N5lDjJv/K9mmdP0QIumsTcGDhG24CWk8ouVP7h1jF8Iys+2duUGdO58XT/fqm7f7hOos Kdrw15kbATxMdZy6PVBMic2XzGqttcHiS7YkMYQnfuL7hansJz8ekx1uu4Xg1Iu9hWPD Tzhw== 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 a9si3207467ejx.271.2020.07.23.20.59.39; Thu, 23 Jul 2020 21:00:02 -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 S1726719AbgGXD6q (ORCPT + 99 others); Thu, 23 Jul 2020 23:58:46 -0400 Received: from alexa-out.qualcomm.com ([129.46.98.28]:38295 "EHLO alexa-out.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726503AbgGXD6q (ORCPT ); Thu, 23 Jul 2020 23:58:46 -0400 Received: from ironmsg07-lv.qualcomm.com (HELO ironmsg07-lv.qulacomm.com) ([10.47.202.151]) by alexa-out.qualcomm.com with ESMTP; 23 Jul 2020 20:58:46 -0700 Received: from ironmsg02-blr.qualcomm.com ([10.86.208.131]) by ironmsg07-lv.qulacomm.com with ESMTP/TLS/AES256-SHA; 23 Jul 2020 20:58:44 -0700 Received: from c-skakit-linux.ap.qualcomm.com (HELO c-skakit-linux.qualcomm.com) ([10.242.51.242]) by ironmsg02-blr.qualcomm.com with ESMTP; 24 Jul 2020 09:28:24 +0530 Received: by c-skakit-linux.qualcomm.com (Postfix, from userid 2344709) id 2CF344272; Fri, 24 Jul 2020 09:28:23 +0530 (IST) From: satya priya To: Bjorn Andersson , gregkh@linuxfoundation.org Cc: Andy Gross , Rob Herring , Matthias Kaehlcke , 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, satya priya Subject: [PATCH V2 3/3] tty: serial: qcom_geni_serial: Fix the UART wakeup issue Date: Fri, 24 Jul 2020 09:28:02 +0530 Message-Id: <1595563082-2353-4-git-send-email-skakit@codeaurora.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1595563082-2353-1-git-send-email-skakit@codeaurora.org> References: <1595563082-2353-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 As a part of system suspend we call uart_port_suspend from the Serial driver, which calls set_mctrl passing mctrl as NULL. This makes RFR high(NOT_READY) during suspend. Due to this BT SoC is not able to send wakeup bytes to UART during suspend. Included if check for non-suspend case to keep RFR low during suspend. Signed-off-by: satya priya --- Changes in V2: - This patch fixes the UART flow control issue during suspend. Newly added in V2. drivers/tty/serial/qcom_geni_serial.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/tty/serial/qcom_geni_serial.c b/drivers/tty/serial/qcom_geni_serial.c index 07b7b6b..7108dfc 100644 --- a/drivers/tty/serial/qcom_geni_serial.c +++ b/drivers/tty/serial/qcom_geni_serial.c @@ -242,7 +242,7 @@ static void qcom_geni_serial_set_mctrl(struct uart_port *uport, if (mctrl & TIOCM_LOOP) port->loopback = RX_TX_CTS_RTS_SORTED; - if (!(mctrl & TIOCM_RTS)) + if ((!(mctrl & TIOCM_RTS)) && (!(uport->suspended))) uart_manual_rfr = UART_MANUAL_RFR_EN | UART_RFR_NOT_READY; writel(uart_manual_rfr, uport->membase + SE_UART_MANUAL_RFR); } -- QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by The Linux Foundation