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
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <4ad8c00e-f752-dfb2-331e-8cdff02eaa05@acm.org>
Date:   Thu, 18 Aug 2022 19:48:22 -0700
From:   Bart Van Assche <bvanassche@....org>
To:     Can Guo <quic_cang@...cinc.com>, quic_asutoshd@...cinc.com,
        quic_nguyenb@...cinc.com, quic_xiaosenh@...cinc.com,
        stanley.chu@...iatek.com, adrian.hunter@...el.com,
        beanhuo@...ron.com, avri.altman@....com, mani@...nel.org,
        linux-scsi@...r.kernel.org, kernel-team@...roid.com
Cc:     Andy Gross <agross@...nel.org>,
        Bjorn Andersson <bjorn.andersson@...aro.org>,
        "James E.J. Bottomley" <jejb@...ux.ibm.com>,
        "Martin K. Petersen" <martin.petersen@...cle.com>,
        "open list:ARM/QUALCOMM SUPPORT" <linux-arm-msm@...r.kernel.org>,
        open list <linux-kernel@...r.kernel.org>
Subject: Re: [RFC PATCH v2 2/2] scsi: ufs-qcom: Add MCQ support

On 8/11/22 03:33, Can Guo wrote:
> +static int ufs_qcom_get_outstanding_cqs(struct ufs_hba *hba,
> +					unsigned long *ocqs)
> +{
> +	return -EINVAL;
> +}

Why does the get_outstanding_cqs vop exist since the only implementation 
of that vop returns EINVAL?

> +static int ufs_qcom_config_mcq_rop(struct ufs_hba *hba)
> +{
> +	struct ufshcd_mcq_rop_info_t *rop;
> +	struct ufshcd_res_info_t *mem_res, *sqdao_res;
> +	int i;
> +
> +	mem_res = &hba->res[RES_MEM];
> +	sqdao_res = &hba->res[RES_MCQ_SQD];
> +
> +	if (!mem_res->base || !sqdao_res->base)
> +		return -EINVAL;
> +
> +	for (i = 0; i < ROP_MAX; i++) {
> +		rop = &hba->mcq_rop[i];
> +		rop->offset = sqdao_res->resource->start -
> +			      mem_res->resource->start + 0x40 * i;
> +		rop->stride = 0x100;
> +		rop->base = sqdao_res->base + 0x40 * i;
> +	}
> +
> +	return 0;
> +}

Is there anything in the above function that is specific to the Qualcomm 
controller? If not, please move the above code into ufshcd.c.

> +static int ufs_qcom_get_hba_mac(struct ufs_hba *hba)
> +{
> +	return MAX_SUPP_MAC;
> +}

Since there is a register in the UFSHCI 4.0 specification from which the 
maximum number of outstanding commands can be retrieved, why does the 
get_hba_mac vop exist?

Thanks,

Bart.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ