lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Message-ID: <e760d891-36d9-8253-326d-ad5c3645714f@acm.org> Date: Fri, 25 Nov 2022 17:14:02 -0800 From: Bart Van Assche <bvanassche@....org> To: Asutosh Das <quic_asutoshd@...cinc.com>, quic_cang@...cinc.com, martin.petersen@...cle.com, linux-scsi@...r.kernel.org Cc: quic_nguyenb@...cinc.com, quic_xiaosenh@...cinc.com, stanley.chu@...iatek.com, eddie.huang@...iatek.com, daejun7.park@...sung.com, avri.altman@....com, mani@...nel.org, beanhuo@...ron.com, linux-arm-msm@...r.kernel.org, Alim Akhtar <alim.akhtar@...sung.com>, "James E.J. Bottomley" <jejb@...ux.ibm.com>, Andy Gross <agross@...nel.org>, Bjorn Andersson <andersson@...nel.org>, Konrad Dybcio <konrad.dybcio@...ainline.org>, Jinyoung Choi <j-young.choi@...sung.com>, Arthur Simchaev <Arthur.Simchaev@....com>, Kiwoong Kim <kwmad.kim@...sung.com>, open list <linux-kernel@...r.kernel.org> Subject: Re: [PATCH v5 07/16] ufs: core: mcq: Calculate queue depth On 11/22/22 20:10, Asutosh Das wrote: > +int ufshcd_mcq_decide_queue_depth(struct ufs_hba *hba) > +{ > + int mac; > + > + /* Mandatory to implement get_hba_mac() */ > + mac = ufshcd_mcq_vops_get_hba_mac(hba); > + if (mac < 0) { > + dev_err(hba->dev, "Failed to get mac, err=%d\n", mac); > + return mac; > + } > + > + WARN_ON(!hba->dev_info.bqueuedepth); > + /* > + * max. value of bqueuedepth = 256, mac is host dependent. > + * It is mandatory for UFS device to define bQueueDepth if > + * shared queuing architecture is enabled. > + */ > + return min_t(int, mac, hba->dev_info.bqueuedepth); > +} Isn't WARN_ON_ONCE() recommended over WARN_ON()? Otherwise this patch looks good to me. Thanks, Bart.
Powered by blists - more mailing lists