Message ID | aeacbc87b583289f729c04feb1168a690714dbc4.1669839847.git.quic_asutoshd@quicinc.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp1139942wrr; Wed, 30 Nov 2022 12:41:45 -0800 (PST) X-Google-Smtp-Source: AA0mqf7EdH0J6Uk+UePlQyN7aOUYI1dCbklFrtP6/bxsHMZUNsDfPicjfqCAjJLTj57DaphNGJde X-Received: by 2002:a17:907:d68b:b0:7b9:dff1:b26e with SMTP id wf11-20020a170907d68b00b007b9dff1b26emr33195750ejc.289.1669840904839; Wed, 30 Nov 2022 12:41:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669840904; cv=none; d=google.com; s=arc-20160816; b=LJrLIs/G9GO0GsAPjmXMf/I0xk9LyfMwDoDIX+PoUMYao0Asx5NlzNoRdjxRj0o97/ U6AyPz01sDjZmWTGM8GVo1+pt6jiykrB+p7CQ7Cwf6c1QfFgSQQgljEhM8raXg74xL4x PfQHy88tK9o5b25pqtlD1cd93MuELGGmLH/bcqVsaFxdhh1o5AEZpESe+049mH3+rWoc S7BoCTInakHsJ/BRC67qu9Gnijnd4okktkCaXoWx/TS5hYmke5sXhUE2b1H66k2dU/g3 o9jGzayf06fxlkuJ3HqStqPQVu5y3G9/6Babup2RVUaq93PAv3JUuhreDWLcTbtAuy3D Vumw== 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=bUx2F1njbYad5/Bph/yve0YlzZuGc9YGQi5bG0PZGWI=; b=zHkwoocCbYNU3c7eC0Xrn9j6Dp/b6ZdfBWV+n/IUomXygC9apRt3OwpJxjxKicRLGQ BSw2yIA9BhWwmmKRy9CGyXtgr1t3he1hKDeHS7GEiurjLPO1cBc3ogMijDUKVIVmEnDU DDwg3zEUloGVhHU4OdWt5Clz+UkPFWTPiLxKoDYjgC98Sy3D6HD5tGuZBPVnh0diUBIJ THDvI683Z5ZHtYVaTGHO573I5rMKwAkQFm3W8qIv5w7wZN5nngfiSc8Pfew+3/57lD1W cA9khSJOEGIqiHjV7+IqNLnGnpGgsPf7+4p4h5ZQ0SQFj+30r8qOAxp5OrNVC0H2rAg2 T2rA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=juW3plSX; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hz5-20020a1709072ce500b007416e100f3dsi2143478ejc.986.2022.11.30.12.41.21; Wed, 30 Nov 2022 12:41:44 -0800 (PST) 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=juW3plSX; 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 S230077AbiK3UdD (ORCPT <rfc822;heyuhang3455@gmail.com> + 99 others); Wed, 30 Nov 2022 15:33:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44042 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230252AbiK3Uci (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Wed, 30 Nov 2022 15:32:38 -0500 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8605D94545; Wed, 30 Nov 2022 12:31:37 -0800 (PST) Received: from pps.filterd (m0279869.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 2AUBxnkG021761; Wed, 30 Nov 2022 20:31:04 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=bUx2F1njbYad5/Bph/yve0YlzZuGc9YGQi5bG0PZGWI=; b=juW3plSXVKNVOSWNf7B22zoJniKiGtqawSOYdOhYz2UAot/IGjGVcB3Y99w7ohtUXRp2 YmPUt22K6V8B7zLYzPXw/DXjzYB2hTtcVkvQkymSxr2Q1GFtmiOUfDFK65kJkQLw1353 6+3QA2i7UlCD5vvj1BtL/Em70QjRfoTPZdmNvSa6l90XLjdYmfjcdejVwdP8P6JNgc69 snzq6K7mDCDO1YqmgRnRniLt9V4BvYbQUsmyasjpzT5OPc7k0+TqLxW0epvmC4c+f5W6 GF791z3ixMA4vJcNDKWf0uJRjxsqrmrCj2Srmosx8kvdBPAYqvtvUwpK3Fv54GG6yQhj hg== Received: from nasanppmta02.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3m616haq9w-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 30 Nov 2022 20:31:03 +0000 Received: from nasanex01a.na.qualcomm.com (corens_vlan604_snip.qualcomm.com [10.53.140.1]) by NASANPPMTA02.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 2AUKV2gn016380 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 30 Nov 2022 20:31:02 GMT Received: from asutoshd-linux1.qualcomm.com (10.80.80.8) by nasanex01a.na.qualcomm.com (10.52.223.231) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.36; Wed, 30 Nov 2022 12:31:02 -0800 From: Asutosh Das <quic_asutoshd@quicinc.com> To: <quic_cang@quicinc.com>, <martin.petersen@oracle.com>, <linux-scsi@vger.kernel.org> CC: <quic_nguyenb@quicinc.com>, <quic_xiaosenh@quicinc.com>, <stanley.chu@mediatek.com>, <eddie.huang@mediatek.com>, <daejun7.park@samsung.com>, <bvanassche@acm.org>, <avri.altman@wdc.com>, <mani@kernel.org>, <beanhuo@micron.com>, Asutosh Das <quic_asutoshd@quicinc.com>, <linux-arm-msm@vger.kernel.org>, Alim Akhtar <alim.akhtar@samsung.com>, "James E.J. Bottomley" <jejb@linux.ibm.com>, Jinyoung Choi <j-young.choi@samsung.com>, open list <linux-kernel@vger.kernel.org> Subject: [PATCH v8 16/16] ufs: core: mcq: Enable Multi Circular Queue Date: Wed, 30 Nov 2022 12:27:57 -0800 Message-ID: <aeacbc87b583289f729c04feb1168a690714dbc4.1669839847.git.quic_asutoshd@quicinc.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <cover.1669839847.git.quic_asutoshd@quicinc.com> References: <cover.1669839847.git.quic_asutoshd@quicinc.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nasanex01a.na.qualcomm.com (10.52.223.231) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-GUID: mAuGLyEWZmGEGoF5M_J_-yrWJWMqDe19 X-Proofpoint-ORIG-GUID: mAuGLyEWZmGEGoF5M_J_-yrWJWMqDe19 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.219,Aquarius:18.0.895,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2022-11-30_04,2022-11-30_02,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 malwarescore=0 bulkscore=0 phishscore=0 mlxscore=0 adultscore=0 mlxlogscore=999 clxscore=1015 suspectscore=0 priorityscore=1501 lowpriorityscore=0 spamscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2210170000 definitions=main-2211300143 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1750955096933752935?= X-GMAIL-MSGID: =?utf-8?q?1750955096933752935?= |
Series |
[v8,01/16] ufs: core: Optimize duplicate code to read extended feature
|
|
Commit Message
Asutosh Das
Nov. 30, 2022, 8:27 p.m. UTC
Enable MCQ in the Host Controller. Signed-off-by: Asutosh Das <quic_asutoshd@quicinc.com> Reviewed-by: Bart Van Assche <bvanassche@acm.org> Reviewed-by: Manivannan Sadhasivam <mani@kernel.org> --- drivers/ufs/core/ufshcd.c | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/drivers/ufs/core/ufshcd.c b/drivers/ufs/core/ufshcd.c index adf3597..e9d6891 100644 --- a/drivers/ufs/core/ufshcd.c +++ b/drivers/ufs/core/ufshcd.c @@ -8381,6 +8381,12 @@ static void ufshcd_config_mcq(struct ufs_hba *hba) hba->host->can_queue = hba->nutrs - UFSHCD_NUM_RESERVED; hba->reserved_slot = hba->nutrs - UFSHCD_NUM_RESERVED; + + /* Select MCQ mode */ + ufshcd_writel(hba, ufshcd_readl(hba, REG_UFS_MEM_CFG) | 0x1, + REG_UFS_MEM_CFG); + hba->mcq_enabled = true; + dev_info(hba->dev, "MCQ configured, nr_queues=%d, io_queues=%d, read_queue=%d, poll_queues=%d, queue_depth=%d\n", hba->nr_hw_queues, hba->nr_queues[HCTX_TYPE_DEFAULT], hba->nr_queues[HCTX_TYPE_READ], hba->nr_queues[HCTX_TYPE_POLL],