Message ID | fcb750c102b9ba7ee69acf1e81fd2775376c2466.1669684648.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 q4csp57798wrr; Mon, 28 Nov 2022 17:28:40 -0800 (PST) X-Google-Smtp-Source: AA0mqf4qQeAkxrvevu1qH/N05ND8OGrFv5u4ZZQnfbZAyN11wpqwH4xin/SzDG4gkM1mw45RsF3S X-Received: by 2002:a17:902:be17:b0:188:fbc5:b734 with SMTP id r23-20020a170902be1700b00188fbc5b734mr35429941pls.170.1669685319981; Mon, 28 Nov 2022 17:28:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669685319; cv=none; d=google.com; s=arc-20160816; b=mBzT3AZLUlOEk7W09B1Gan9G0JeKx7a4KQpXj5v0HnM00NMEQcpQSYvSYrgXSZLer1 5ZtiHqQdiC4S01ZP+BhxQ/RT1sE7ZaI25Hw1nWoq4keL1rxJhB7/I5EGlryyzlRoK09e rehy9kjJksZW60lx4BMTe2MGnq1yuHHMsT9g/CYTitrcM9G27lscWkhOFQjQLwmx5G6J Dnoi+XhxbWpClXzdH70T5ZGTDNo61RhKtI4swF24SrzQBqsQPb63XQpPJQgq2wLwaGUA OmKOmsc4P/bf+1bd3kio8tbzVvugW3LuSsIUIWPGyYhMUbcJgq+4UEwTLt7cDfw5+AnV UQcw== 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=sNWMuIwowPbx7oM4EoLs9xgSuZe4p/1yy6+EB77veFEpE5MSVFJtdENkRlsIHo2Xps ja1NEeUo7mnbiz81nwFkpkyiTLlEhh50HzH2Q9GqKE+cFDEYsyGGVq3+mbz/uUD8muC4 Vi6FbsdOzXbfz4Xf9WOPTtDqox9tHtee/TuJtn/GB4HSQNJ8dC0gDks8nWpRrQIhpwJz 4xDRXtKjuyKd286mIKg8wIoNFXiGkUijsymyPqWWhhwdDX4yogFKRrFXymaJJ3KaPhdK 5xYIQGxvDpIfY1UMKGOsiEha7Az8NvKQJGfExa6HIQK13EwjqC85JH2SsuATh/L7cVin 8tEA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=ltAAK175; 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 t5-20020a635345000000b00477a5b7d52asi13359779pgl.607.2022.11.28.17.28.26; Mon, 28 Nov 2022 17:28:39 -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=ltAAK175; 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 S235173AbiK2BZm (ORCPT <rfc822;gah0developer@gmail.com> + 99 others); Mon, 28 Nov 2022 20:25:42 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53162 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235028AbiK2BZJ (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 28 Nov 2022 20:25:09 -0500 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E46A247312; Mon, 28 Nov 2022 17:24:23 -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 2ASNRbiR013671; Tue, 29 Nov 2022 01:24:11 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=ltAAK175CmvgNLFfySzjtA+BPi4tayoq+cVE6fzPYwodz6ujjYUDdl+WkG/BOiceYR2P FJc8jlsbE04vsGA7h2aB+SYRQZTSb2Vd7APv+hBYw38mSZkeiv6S6EoakPlUxqNqzsFG wc1j0f3GKljgcBnrzlFeVtgE3Za0a1/sT3fXFB8o5fauWn/PfXNLN/llDKc4tLZYym84 tI2lpriX7MVSfKsw6fzdGAma4d0LJFuvQ0h9QHeYF6SPUxc5d+77cTpObEDnrIO0VCQu R2lNmIG0FKkaTQV4kWABJJ7istngOiOz+WfMEHF7qSLnFF4NFlKoaGiwE23tMOR0GqZ7 fg== Received: from nasanppmta04.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3m39tg5j15-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 29 Nov 2022 01:24:11 +0000 Received: from nasanex01a.na.qualcomm.com ([10.52.223.231]) by NASANPPMTA04.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 2AT1OAwI010419 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 29 Nov 2022 01:24:10 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; Mon, 28 Nov 2022 17:24:10 -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 v6 16/16] ufs: core: mcq: Enable Multi Circular Queue Date: Mon, 28 Nov 2022 17:20:57 -0800 Message-ID: <fcb750c102b9ba7ee69acf1e81fd2775376c2466.1669684648.git.quic_asutoshd@quicinc.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <cover.1669684648.git.quic_asutoshd@quicinc.com> References: <cover.1669684648.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: UokaQh5Cujl0684lK1QMxe6SoWo-NkO0 X-Proofpoint-ORIG-GUID: UokaQh5Cujl0684lK1QMxe6SoWo-NkO0 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-29_01,2022-11-28_02,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 suspectscore=0 adultscore=0 spamscore=0 lowpriorityscore=0 malwarescore=0 mlxlogscore=999 mlxscore=0 phishscore=0 impostorscore=0 priorityscore=1501 clxscore=1015 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2210170000 definitions=main-2211290006 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?1750791954062141570?= X-GMAIL-MSGID: =?utf-8?q?1750791954062141570?= |
Series |
[v6,01/16] ufs: core: Optimize duplicate code to read extended feature
|
|
Commit Message
Asutosh Das
Nov. 29, 2022, 1:20 a.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],