From patchwork Wed Sep 7 15:31:42 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vijaya Krishna Nivarthi X-Patchwork-Id: 603399 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id AA66AC6FA86 for ; Wed, 7 Sep 2022 15:32:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229500AbiIGPcK (ORCPT ); Wed, 7 Sep 2022 11:32:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52316 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229451AbiIGPcJ (ORCPT ); Wed, 7 Sep 2022 11:32:09 -0400 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2835A6F277; Wed, 7 Sep 2022 08:32:05 -0700 (PDT) Received: from pps.filterd (m0279871.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 287BDfD0009129; Wed, 7 Sep 2022 15:31:52 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=from : to : cc : subject : date : message-id; s=qcppdkim1; bh=vb4Q9bKoRnQ1hrAVSSM3Lubd23SP5rGhgMFJBZZ6gu0=; b=Qg1cZVm77Qv5iilhaXvDaHBbj/nK4KR4G7rAA7m91e8s4ec7LBWtYUoz7cfiGOFfJa2I glLdjJybD5iBwZhjCxTd9FglBF0CjThwWMDN+HuQxXWGj0Wcaz5/FKBxBXQWwFVsgeCy 2TMGLTkbQ/Wx4f0x4gf0xjNTlQEE03jfWvJXRJg+BOaX4Z9eMNkDZUTi67NFhalioKB1 LDxCYRgIZ0U5u5jsf6NYx+cFNaK2FymfybBFKumrb5ogvGCbNiQY+uj9i54vs7HsR19W Ld9zr4m9YUUX8fItrVU2ldFXhnKtnfcEkM+rKt+AhqouMXRnM+bITioEJgLg0rMEuH2E Ew== Received: from apblrppmta02.qualcomm.com (blr-bdr-fw-01_GlobalNAT_AllZones-Outside.qualcomm.com [103.229.18.19]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3jefntaa1a-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 07 Sep 2022 15:31:52 +0000 Received: from pps.filterd (APBLRPPMTA02.qualcomm.com [127.0.0.1]) by APBLRPPMTA02.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTP id 287FVmdm004198; Wed, 7 Sep 2022 15:31:48 GMT Received: from pps.reinject (localhost [127.0.0.1]) by APBLRPPMTA02.qualcomm.com (PPS) with ESMTP id 3jc00kynxs-1; Wed, 07 Sep 2022 15:31:48 +0000 Received: from APBLRPPMTA02.qualcomm.com (APBLRPPMTA02.qualcomm.com [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 287FVlK1004193; Wed, 7 Sep 2022 15:31:47 GMT Received: from hu-sgudaval-hyd.qualcomm.com (hu-vnivarth-hyd.qualcomm.com [10.213.111.166]) by APBLRPPMTA02.qualcomm.com (PPS) with ESMTP id 287FVlTi004191; Wed, 07 Sep 2022 15:31:47 +0000 Received: by hu-sgudaval-hyd.qualcomm.com (Postfix, from userid 3994820) id E1CF53F9A; Wed, 7 Sep 2022 21:01:46 +0530 (+0530) From: Vijaya Krishna Nivarthi To: agross@kernel.org, andersson@kernel.org, konrad.dybcio@somainline.org, gregkh@linuxfoundation.org, jirislaby@kernel.org, linux-arm-msm@vger.kernel.org, linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org Cc: quic_msavaliy@quicinc.com, dianders@chromium.org, mka@chromium.org, swboyd@chromium.org, Vijaya Krishna Nivarthi Subject: [PATCH] tty: serial: qcom-geni-serial: Replace hardcoded icc flags with macros. Date: Wed, 7 Sep 2022 21:01:42 +0530 Message-Id: <1662564702-7253-1-git-send-email-quic_vnivarth@quicinc.com> X-Mailer: git-send-email 2.7.4 X-QCInternal: smtphost X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: zEhDfI2K3rCrAT9xfcFGvZWltVt_49oK X-Proofpoint-GUID: zEhDfI2K3rCrAT9xfcFGvZWltVt_49oK X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.895,Hydra:6.0.528,FMLib:17.11.122.1 definitions=2022-09-07_08,2022-09-07_02,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 spamscore=0 adultscore=0 malwarescore=0 priorityscore=1501 mlxlogscore=760 lowpriorityscore=0 phishscore=0 mlxscore=0 bulkscore=0 clxscore=1011 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2207270000 definitions=main-2209070060 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org In suspend/resume routines, icc flags are hardcoded. Replace the hardcodes with macros available from header. Signed-off-by: Vijaya Krishna Nivarthi Reviewed-by: Stephen Boyd --- drivers/tty/serial/qcom_geni_serial.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/tty/serial/qcom_geni_serial.c b/drivers/tty/serial/qcom_geni_serial.c index 52182f6..83b66b7 100644 --- a/drivers/tty/serial/qcom_geni_serial.c +++ b/drivers/tty/serial/qcom_geni_serial.c @@ -22,6 +22,7 @@ #include #include #include +#include /* UART specific GENI registers */ #define SE_UART_LOOPBACK_CFG 0x22c @@ -1525,7 +1526,7 @@ static int __maybe_unused qcom_geni_serial_sys_suspend(struct device *dev) * even with no_console_suspend */ if (uart_console(uport)) { - geni_icc_set_tag(&port->se, 0x3); + geni_icc_set_tag(&port->se, QCOM_ICC_TAG_ACTIVE_ONLY); geni_icc_set_bw(&port->se); } return uart_suspend_port(private_data->drv, uport); @@ -1540,7 +1541,7 @@ static int __maybe_unused qcom_geni_serial_sys_resume(struct device *dev) ret = uart_resume_port(private_data->drv, uport); if (uart_console(uport)) { - geni_icc_set_tag(&port->se, 0x7); + geni_icc_set_tag(&port->se, QCOM_ICC_TAG_ALWAYS); geni_icc_set_bw(&port->se); } return ret;