From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 533C231618C for ; Fri, 29 May 2026 08:43:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.180.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780044184; cv=none; b=Zac3sVgYAoByh3sJy0cgGKnCOUC0yC0WpE0pbPkSZI+c7vnLWtX0aoO9g8/51c1o251od80v0n/1sQwOzObUU+sqA3O2bYNcykHPCivlZs193xWaGDIBbm2QUCBqP1+PKiO9dkV/kc6AgSBj9A5h9PU2bcpqCqu0IYRUkmSRCBE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780044184; c=relaxed/simple; bh=H2R1rAAC2qP2s6RXU1ks0J1r6HVE8RZDjOliU6dTxjs=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=YvMcGn1WL2qbETRO8h8NpBf2ps+pDI+CP6NlnNUs28JM8mVSbcHyse3JHe64GCiaOxPmaufk9DzZyX51Y1BcbGB9ra0Q69FPi0BQyx69sHl0v4V6OZyrvp8Ty1y+6QumH+NVK0SCReX74HnJ79v6UhgKC4U2w7r7fGPbsyZxhhw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=kqN992Ug; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=Rw9chLWE; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="kqN992Ug"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="Rw9chLWE" Received: from pps.filterd (m0279871.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 64T6fpp31388067 for ; Fri, 29 May 2026 08:43:02 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= +O4THh1DQwVCJTT5A1E+2yOFluHVMghLlE26G57FGbk=; b=kqN992Ugst/rSc0C VVCL7GpUAW5C/qSUpK/fFe2HI9zkkjm/SwGt83i3AMeFbUNLCN9BtAZphqPuqfgL IbRtazw7RtMEHa8kyiio/HdGdb7eBtgX7yeUHo2NzhjZnNHzcTEAlaKnKty3rmTE gVBVxMUUnZVk7ycL9ARoVoElHf7TVic33Z6ZWiYHLY9SmHhlTimKvLy/trCIWVDc OjU58u5tpqbOmYKocR4FaUSx/a6MnczuT0wswFEG+zo1zm4emyUCUrqgNHHQ7Noj QfSByeL7wbEygGM5IRwUpPyqBvCt5FZ9GougagMMfiJQk/r3mue3mqmezmmm6eOn d1lqUg== Received: from mail-pl1-f199.google.com (mail-pl1-f199.google.com [209.85.214.199]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4eevumtkw2-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Fri, 29 May 2026 08:43:02 +0000 (GMT) Received: by mail-pl1-f199.google.com with SMTP id d9443c01a7336-2bf243973c2so3311875ad.1 for ; Fri, 29 May 2026 01:43:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1780044181; x=1780648981; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=+O4THh1DQwVCJTT5A1E+2yOFluHVMghLlE26G57FGbk=; b=Rw9chLWEPImk/1l6LjfYLFmiImOOUJgKuoDD8/19UD0b+PA2bh7eqVIldrsbxLu+9J fzst4oT4uwzzW7Yh+Kfb677lh0WwZkf16UHqPqz+3Kia/wpf133+q1jd4AD4XqpYxXjN ljtmQj3+39skRzbgDjoeCmwUm7FZzXtnMt/NyjPwia17SBSLG/MCgtusQ7KHZ+2ClOOZ glCoqjqqKL2T2YMAYcexUp6TX86DTu63bC2fDJk6fm2cwjRcOnajnVyYwgQ2DBjb7UIo 0KFB5KMkNs+yowpqYaPfNHqw51kUTCbBt5pWi5XMSnm/+pGo9uBoLoSkfsxLbYLDHxFj 2kZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1780044181; x=1780648981; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=+O4THh1DQwVCJTT5A1E+2yOFluHVMghLlE26G57FGbk=; b=hT8yoA49/E0jYhnMMq5irW5DC//cY6LfZxI7LEwCa3Gc6YgUOQndAW/E53poUVLqzx RTaLYPuVyA3l7Phl949Pzjp+rWerSB3u6fClGMm7nWiZOy8WJYiXVxY4aagedY9Z6TJg FkaFwBG3F0J3rZWrfcZo8UfKBkoE3wx65fOf5SSQwEZ4vGZfJMYzXHqNnlp0QCJBSKK/ WLx/ZHRlpUj1AnEpffS8Ysog9CdxHyewsyAZCFEbBXhHpycmNH436hAvm8IWXvxEuLuS WOtHg3WnbQ/HXm44cV2sqDMdyH+G+bsZxUB5hemKqEcpVa81pIyR5QIiS1zkxhsLLAUY 9/PQ== X-Forwarded-Encrypted: i=1; AFNElJ8GOwO8Cs9pr5iqQjTUf9WY8h89TIkmjTR6ezPKv7SWvWp+CFiiR8TQGVSRW6ocj38DJlUfT1Y1OvfqvJI=@vger.kernel.org X-Gm-Message-State: AOJu0YzQQ5aJraOewmKWFhA3WL1eud8yIgWtyaEjcrLvZ1PblWHXW1hG l5HZhczrP4/WALClFiDPX+opsL3GvgY1PW13TuX+apuFiAo5APt+RoGKdA8CR9d6Y9pK/XZO6Bc p42AB1xwNEpLzKYEKZiiLtRLBljOza1Et6fc20LvGIc6vQXDaU178FXUrjQASmMkrFTs= X-Gm-Gg: Acq92OFp4KJ7PabCRdU3TEjJRH848Mne79dmDaADU2+IjxMCc2LQAsX2e35pAitHm42 amkDjm5ctG/SIPVKkREovPUtwnL1FzXEe2eOq1y4gR963kQHhIsdW6UDjIVFweFu0+d7azINkXK LM9n+4MnnFLaAwDLZSCoGnyzUucV1dcMDZKGDvHZYfdFVw+FAWMvtMYMPPp/fnwmecbhZNT9+4t TNSId9zVurHo17i9eesS2K97Ks6LX8GunNi8gOcAUh4XK05JrlSOR/wG3Jx9dua0Od8V4Zmq4gt o7NlT8iau7JnCDtp8fzglbQo0JxcpMo2nGRMmbRYGUPvXeKMesMap8In+vBREYnuiK1I1duuorF 5Wej8Qp4Kt8mJiLSYyCQVuUCW8CTK1B7LXXB3WT1r4XNVKGq406H9Ay0rOP10y2oNpMsU64WAnH j6w5MtaTzjwG+jLWi/cClBeQ== X-Received: by 2002:a17:903:350c:b0:2b2:67ca:5ff9 with SMTP id d9443c01a7336-2bf203dbc13mr26419305ad.0.1780044179251; Fri, 29 May 2026 01:42:59 -0700 (PDT) X-Received: by 2002:a17:903:350c:b0:2b2:67ca:5ff9 with SMTP id d9443c01a7336-2bf203dbc13mr26415845ad.0.1780044173663; Fri, 29 May 2026 01:42:53 -0700 (PDT) Received: from [10.133.33.247] (tpe-colo-wan-fw-bordernet.qualcomm.com. [103.229.16.4]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2bf23c2da36sm15253425ad.69.2026.05.29.01.42.50 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 29 May 2026 01:42:53 -0700 (PDT) Message-ID: <0e3c4e21-0c54-42b5-8863-8604f1b698a8@oss.qualcomm.com> Date: Fri, 29 May 2026 16:42:49 +0800 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v5 2/2] scsi: ufs: core: Add support for static TX Equalization settings To: =?UTF-8?B?UGV0ZXIgV2FuZyAo546L5L+h5Y+LKQ==?= , "beanhuo@micron.com" , "mani@kernel.org" , "bvanassche@acm.org" , "martin.petersen@oracle.com" Cc: "linux-scsi@vger.kernel.org" , "quic_nitirawa@quicinc.com" , "James.Bottomley@HansenPartnership.com" , "linux-kernel@vger.kernel.org" , "alim.akhtar@samsung.com" , "quic_rdwivedi@quicinc.com" , "avri.altman@wdc.com" References: <20260529011421.462046-1-can.guo@oss.qualcomm.com> <20260529011421.462046-3-can.guo@oss.qualcomm.com> <1e432db04abc12c4109754788ab36a09111cf3e9.camel@mediatek.com> <7f2f9a0a-03e9-4a0e-ae57-2b0c557e029f@oss.qualcomm.com> Content-Language: en-US From: Can Guo In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Proofpoint-GUID: fHvvxkFA6lL8IXEY4_TPbpueO1lZUGdU X-Proofpoint-ORIG-GUID: fHvvxkFA6lL8IXEY4_TPbpueO1lZUGdU X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNTI5MDA4NCBTYWx0ZWRfX9D9ZQFdAnhMB ZwRFoki/khyH0+0FHuTvjwUkd2zCAlc526JYToROxsVOr4zQBZbtQDlZ1g199qBBIqX6y1+/5wi 4nduoYpGw2jD7OSzdSDnalfGsg57tBFsE/5Yp+MWqM6wta3QdYLxVs2jqNPeM0zXAPwT0earGVl 6pMsQ5w4abgdr9XO55cgpXGLCeSqqXyIn1Dfwsm5XLo/Slx6+WggCxlWB+PCZ2iZvZzVmFoMigj SPW8hdD5e+CYezndhaPVVrtyQPhE7A6Zq1fJiu+BFgaW/+RJ1mpA9S5aI1HgkvNJF4AVjoSVw7g KeqnPzeHtJuoiPP5Hp+gBh/ByUILORjQ/26urN5kw7grFH+oGyLsz7JNeq0ZuT7ll6FUGBdz8Dv 1ncs/BBZfpS4cDA7zPoCFP5OWILiMEqQfu40ikIr5arLm2xbSL1+L9jhDRUs3CIFGn7Gv9jxi2j nRg45OLiFT2q0ZtyXrg== X-Authority-Analysis: v=2.4 cv=cObQdFeN c=1 sm=1 tr=0 ts=6a195196 cx=c_pps a=JL+w9abYAAE89/QcEU+0QA==:117 a=nuhDOHQX5FNHPW3J6Bj6AA==:17 a=IkcTkHD0fZMA:10 a=NGcC8JguVDcA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=3WHJM1ZQz_JShphwDgj5:22 a=lZOxv685zBznO1DyOMIA:9 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=324X-CrmTo6CU4MGRt3R:22 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.125,FMLib:17.12.100.49 definitions=2026-05-29_02,2026-05-28_03,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 adultscore=0 clxscore=1015 spamscore=0 malwarescore=0 phishscore=0 suspectscore=0 priorityscore=1501 lowpriorityscore=0 bulkscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2605210000 definitions=main-2605290084 On 5/29/2026 4:40 PM, Peter Wang (王信友) wrote: > > On Fri, 2026-05-29 at 16:12 +0800, Can Guo wrote: > > > > +static void ufshcd_parse_static_tx_eq_settings(struct ufs_hba > > > > *hba) > > > > +{ > > > > +       const u32 lpd = hba->lanes_per_direction; > > > > +       const u32 num_elems = lpd * 2; > > > > +       int gear; > > > > + > > > > +       if (!lpd) { > > > > +               return; > > > > +       } else if (lpd > UFS_MAX_LANES) { > > > > > > Unnecessary else if after return. > > You mean removing 'else if (lpd > UFS_MAX_LANES)' and the dev_warn()? > > > > Thanks, > > Can Guo. > > > > Hi Can, > > No, what I mean is that the check below aligns better with > kernel code style: > > if (!lpd) > return; > > if (lpd > UFS_MAX_LANES) { > ... > } OK, got it. Thanks, Can Guo. > > Thanks > Peter > > ************* MEDIATEK Confidentiality Notice > ******************** > The information contained in this e-mail message (including any > attachments) may be confidential, proprietary, privileged, or otherwise > exempt from disclosure under applicable laws. It is intended to be > conveyed only to the designated recipient(s). Any use, dissemination, > distribution, printing, retaining or copying of this e-mail (including its > attachments) by unintended recipient(s) is strictly prohibited and may > be unlawful. If you are not an intended recipient of this e-mail, or believe > > that you have received this e-mail in error, please notify the sender > immediately (by replying to this e-mail), delete any and all copies of > this e-mail (including any attachments) from your system, and do not > disclose the content of this e-mail to any other person. Thank you!