From patchwork Mon Mar 27 16:41:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mukesh Ojha X-Patchwork-Id: 13189625 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 F164CC6FD1D for ; Mon, 27 Mar 2023 16:41:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229934AbjC0Qlo (ORCPT ); Mon, 27 Mar 2023 12:41:44 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56396 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230288AbjC0Qln (ORCPT ); Mon, 27 Mar 2023 12:41:43 -0400 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9AF7B2698; Mon, 27 Mar 2023 09:41:40 -0700 (PDT) Received: from pps.filterd (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 32RAJPq6017673; Mon, 27 Mar 2023 16:41:37 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=from : to : cc : subject : date : message-id : mime-version : content-type; s=qcppdkim1; bh=v/KL0iSUouRlg6RgT5Qvg2Zi5Xz08E6+7OtUkJxKRHs=; b=YbtVmWZUx8R3LbZejel+pw8KJspWkU6FVTM+AVsk9P2HcVPB7V62KsEQMbNJzNjr6FpL iYIb1Z5HMoKLYy45jR7+52tJn5LyHRK1UAEt8+9MxUUWvPDjg/6DhQJLf3nSHK/GVmrq 1PGuUQzeJH1QiFir2eon51o0ZD5xrFYRnteCzXP6dVyLRKksp1aZLFKfkl7yz5Pe26Q1 6eksSDLxu/49oEGf2ZyO+0OhpgIh+SPNcp0G0vW0sIUmBIFuTURjoyLI1lg37x/tAL0Y gnzX52jbMMxESzPs+yI4UMUCkFPp/U/S5PqUDlQHSshZANd3mnhV0YHVfTJz3XDJW0Hf MA== Received: from nasanppmta04.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3pht50w0jn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 27 Mar 2023 16:41:37 +0000 Received: from nasanex01c.na.qualcomm.com (nasanex01c.na.qualcomm.com [10.45.79.139]) by NASANPPMTA04.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 32RGfaMe014561 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 27 Mar 2023 16:41:36 GMT Received: from hu-mojha-hyd.qualcomm.com (10.80.80.8) by nasanex01c.na.qualcomm.com (10.45.79.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.41; Mon, 27 Mar 2023 09:41:34 -0700 From: Mukesh Ojha To: , , , CC: , , , Mukesh Ojha Subject: [PATCH v4 0/5] Refactor to support multiple download mode Date: Mon, 27 Mar 2023 22:11:16 +0530 Message-ID: <1679935281-18445-1-git-send-email-quic_mojha@quicinc.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nasanex01c.na.qualcomm.com (10.45.79.139) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-GUID: D0E0CndYBxcDNuNPFYJW038u7tWRBghv X-Proofpoint-ORIG-GUID: D0E0CndYBxcDNuNPFYJW038u7tWRBghv X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.254,Aquarius:18.0.942,Hydra:6.0.573,FMLib:17.11.170.22 definitions=2023-03-24_11,2023-03-27_02,2023-02-09_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 mlxlogscore=999 lowpriorityscore=0 suspectscore=0 priorityscore=1501 spamscore=0 malwarescore=0 impostorscore=0 adultscore=0 phishscore=0 clxscore=1015 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2303200000 definitions=main-2303270134 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Intention of this series to support multiple download mode and only modify the required bits during setting tcsr register. Other download modes are minidump, bothdump (full dump + minidump). Latest minidump kernel driver patches has been sent here https://lore.kernel.org/lkml/1679491817-2498-1-git-send-email-quic_mojha@quicinc.com/ Also, this series should be applied on https://lore.kernel.org/lkml/1678979666-551-1-git-send-email-quic_mojha@quicinc.com/ Changes in v4: - val should be shifted within the function [srinivas.kandagatla] i.e new = (old & ~mask) | (val << ffs(mask) - 1); - Added Acked-by [linus.walleij] on pinctrl change. Changes in v3 : https://lore.kernel.org/lkml/1679070482-8391-1-git-send-email-quic_mojha@quicinc.com/ - Removed [1] from the series and sent as a separate patch[2], although this series should be applied on top [2]. [1] https://lore.kernel.org/lkml/1677664555-30191-2-git-send-email-quic_mojha@quicinc.com/ [2] https://lore.kernel.org/lkml/1678979666-551-1-git-send-email-quic_mojha@quicinc.com/ - Introduce new exported symbol on suggestion from [srinivas.kandagatla] - Use the symbol from drivers/pinctrl/qcom/pinctrl-msm.c. - Addressed comment given by [dmitry.baryshkov] - Converted non-standard Originally-by to Signed-off-by. Changes in v2: https://lore.kernel.org/lkml/1677664555-30191-1-git-send-email-quic_mojha@quicinc.com/ - Addressed comment made by [bjorn] - Added download mask. - Passed download mode as parameter - Accept human accepatable download mode string. - enable = !!dload_mode - Shifted module param callback to somewhere down in the file so that it no longer need to know the prototype of qcom_scm_set_download_mode() - updated commit text. Mukesh Ojha (5): firmware: qcom_scm: provide a read-modify-write function pinctrl: qcom: Use qcom_scm_io_update_field() firmware: scm: Modify only the download bits in TCSR register firmware: qcom_scm: Refactor code to support multiple download mode firmware: qcom_scm: Add multiple download mode support drivers/firmware/Kconfig | 11 ----- drivers/firmware/qcom_scm.c | 89 +++++++++++++++++++++++++++++++--- drivers/pinctrl/qcom/pinctrl-msm.c | 11 ++--- include/linux/firmware/qcom/qcom_scm.h | 2 + 4 files changed, 87 insertions(+), 26 deletions(-)