Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp721752rwd; Thu, 15 Jun 2023 00:46:41 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7DuqSOnVtO5ZtLdST+0dCpQUkO7DmvzwxYF0lxKRDq1ry39CoQoLeVC7HpvvJasYXU1U7I X-Received: by 2002:a17:903:258c:b0:1b3:fb76:215b with SMTP id jb12-20020a170903258c00b001b3fb76215bmr4436366plb.48.1686815201608; Thu, 15 Jun 2023 00:46:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686815201; cv=none; d=google.com; s=arc-20160816; b=0iSag3KFi5+VTJld7gso11iIQ0Q5Dii+fC04qaFi50AonlnBV8CT+qNOJSVw2XiHbw +2Q//VcUSQw8/HlRH8x5f7PwVictepkx4gaw85+Z03P9F8yxtPYAOeTVAAe9D+WykTpD exdhkRDak6lkUfYhDLxF7TNfmnMgSjXVz7EPscyIhad6QkgTVxON1oNvResaLN/voKkg vQ0x/894lQ6gahhn6FbCKrokdZSUKhdGrpm1cpa6Tr+Hk980BdhMdAv3SkNA/fRUOr6f xNtk2Ek+4gGrOgPRj59xsPY1AtGUQaggx3iCKIq08FPN4guLsQy2MCnxReWewNhgoBLP hVng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=bLNHzr8/HqOIp+2UTEW26YdDjjwket4zHoeu/hL6Cnw=; b=0ln2R5e9VFhWadJ3DjEJc4WC0f+SZ1vo5+UaFnc8ER0o21rPQrsgtUJj4fFvkmROZH xZFv0fV6/T1nvJMJObir31OozzCiCSOb6bdi/g+d+I8Nm1mUiDsRwG9QvA1hRu8MY6Th zOZRhBdSYKNR5q/DlWnSrBlrvlBBucDTe/qtQOHq7SKdStUwl5YjwMCjRzi369jMD683 6OUYC26yujsjMH8Z0jDaMjHYDTI51TTnjtPNdFl+PCk19j7ubirDXFtNTBchGYNTcZin nUzqKNPB795/Vb11XVXXPUIwHZJKFe59LwHCHXVfOuzSiqp87QVhX9AK/xM9iiJWjsxT QMEg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=Z1ayBZoX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id n3-20020a170903110300b001b3d7f53224si6744140plh.463.2023.06.15.00.46.27; Thu, 15 Jun 2023 00:46:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=Z1ayBZoX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244475AbjFOHKa (ORCPT + 99 others); Thu, 15 Jun 2023 03:10:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36492 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244632AbjFOHJk (ORCPT ); Thu, 15 Jun 2023 03:09:40 -0400 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5B41D10D8; Thu, 15 Jun 2023 00:08:15 -0700 (PDT) Received: from pps.filterd (m0279872.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 35F5LM77007464; Thu, 15 Jun 2023 07:08:12 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-type; s=qcppdkim1; bh=bLNHzr8/HqOIp+2UTEW26YdDjjwket4zHoeu/hL6Cnw=; b=Z1ayBZoXcfGo8eJNYql9iYYHjDiIURbdRLFi6emN3KrMLPfUVoo2X3aEZg0Z3x6OjiMG BFGA6MTkvh+SOn9vqW2vjwkOqYyjkhrXiOuu51a0UGr9fG8pwAHVjVwspzFTeSVPyANM 64mXAytsLFCveshvErh39Wb25Kr+jjmxmY98Nca2YIGG86SBXj4g0RAgCB6VOKcZaCnP 2YwZa7FvURMBx+rmN0LU10ca/hIc7hrnGkGXy6NVaUnuI3dO9MMh4Wsl95gQrV5VXGA7 kHK06gCiBjUqo5cKBkvHoOiREd05NdM2zLsa1WbMgI4l4tZuA4IkhZBTSqxYuRVzDcQi cA== Received: from nalasppmta04.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3r78c7ast0-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 15 Jun 2023 07:08:12 +0000 Received: from nalasex01c.na.qualcomm.com (nalasex01c.na.qualcomm.com [10.47.97.35]) by NALASPPMTA04.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 35F78B4J027469 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 15 Jun 2023 07:08:11 GMT Received: from hu-ptalari-hyd.qualcomm.com (10.80.80.8) by nalasex01c.na.qualcomm.com (10.47.97.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.42; Thu, 15 Jun 2023 00:08:06 -0700 From: Praveen Talari To: , , , , , , , , , CC: , , , , Praveen Talari Subject: [PATCH v2 1/3] soc: qcom: geni-se: Add SPI SLAVE mode support for GENI based QuPv3 Date: Thu, 15 Jun 2023 12:37:04 +0530 Message-ID: <20230615070706.18322-2-quic_ptalari@quicinc.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20230615070706.18322-1-quic_ptalari@quicinc.com> References: <20230615070706.18322-1-quic_ptalari@quicinc.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01a.na.qualcomm.com (10.52.223.231) To nalasex01c.na.qualcomm.com (10.47.97.35) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-GUID: i__Ik9VJ41aOM06jrn4pOiIYZvD6XJOk X-Proofpoint-ORIG-GUID: i__Ik9VJ41aOM06jrn4pOiIYZvD6XJOk X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.254,Aquarius:18.0.957,Hydra:6.0.573,FMLib:17.11.176.26 definitions=2023-06-15_04,2023-06-14_02,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 impostorscore=0 malwarescore=0 lowpriorityscore=0 mlxscore=0 spamscore=0 suspectscore=0 clxscore=1015 adultscore=0 phishscore=0 bulkscore=0 mlxlogscore=913 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2305260000 definitions=main-2306150058 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add slave mode support related registers and masks. Signed-off-by: Praveen Talari --- v1 -> v2: - modified commit message --- --- include/linux/soc/qcom/geni-se.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/include/linux/soc/qcom/geni-se.h b/include/linux/soc/qcom/geni-se.h index 821a19135bb6..29e06905bc1f 100644 --- a/include/linux/soc/qcom/geni-se.h +++ b/include/linux/soc/qcom/geni-se.h @@ -35,6 +35,7 @@ enum geni_se_protocol_type { GENI_SE_UART, GENI_SE_I2C, GENI_SE_I3C, + GENI_SE_SPI_SLAVE, }; struct geni_wrapper; @@ -73,12 +74,14 @@ struct geni_se { /* Common SE registers */ #define GENI_FORCE_DEFAULT_REG 0x20 +#define GENI_OUTPUT_CTRL 0x24 #define SE_GENI_STATUS 0x40 #define GENI_SER_M_CLK_CFG 0x48 #define GENI_SER_S_CLK_CFG 0x4c #define GENI_IF_DISABLE_RO 0x64 #define GENI_FW_REVISION_RO 0x68 #define SE_GENI_CLK_SEL 0x7c +#define SE_GENI_CFG_SEQ_START 0x84 #define SE_GENI_DMA_MODE_EN 0x258 #define SE_GENI_M_CMD0 0x600 #define SE_GENI_M_CMD_CTRL_REG 0x604 @@ -111,6 +114,9 @@ struct geni_se { /* GENI_FORCE_DEFAULT_REG fields */ #define FORCE_DEFAULT BIT(0) +/* GENI_OUTPUT_CTRL fields */ +#define GENI_IO_MUX_0_EN BIT(0) + /* GENI_STATUS fields */ #define M_GENI_CMD_ACTIVE BIT(0) #define S_GENI_CMD_ACTIVE BIT(12) @@ -130,6 +136,9 @@ struct geni_se { /* GENI_CLK_SEL fields */ #define CLK_SEL_MSK GENMASK(2, 0) +/* SE_GENI_CFG_SEQ_START fields */ +#define START_TRIGGER BIT(0) + /* SE_GENI_DMA_MODE_EN */ #define GENI_DMA_MODE_EN BIT(0) -- 2.17.1