diff mbox series

[RFC,1/4] ufs: Rename the second ufshcd_probe_hba() argument

Message ID 20210619005228.28569-2-bvanassche@acm.org (mailing list archive)
State Superseded
Headers show
Series UFS patches for Linux kernel v5.14 | expand

Commit Message

Bart Van Assche June 19, 2021, 12:52 a.m. UTC
Rename the second argument of ufshcd_probe_hba() such that the name of
that argument reflects its purpose instead of how the function is called.
See also commit 1b9e21412f72 ("scsi: ufs: Split ufshcd_probe_hba() based
on its called flow").

Cc: Bean Huo <beanhuo@micron.com>
Cc: Asutosh Das <asutoshd@codeaurora.org>
Cc: Can Guo <cang@codeaurora.org>
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
---
 drivers/scsi/ufs/ufshcd.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

Comments

Avri Altman June 21, 2021, 8:13 a.m. UTC | #1
> 
> Rename the second argument of ufshcd_probe_hba() such that the name of
> that argument reflects its purpose instead of how the function is called.
> See also commit 1b9e21412f72 ("scsi: ufs: Split ufshcd_probe_hba() based
> on its called flow").
> 
> Cc: Bean Huo <beanhuo@micron.com>
> Cc: Asutosh Das <asutoshd@codeaurora.org>
> Cc: Can Guo <cang@codeaurora.org>
> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Reviewed-by: Avri Altman <avri.altman@wdc.com>


> ---
>  drivers/scsi/ufs/ufshcd.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
> index 25fe18a36cd2..c230d2a6a55c 100644
> --- a/drivers/scsi/ufs/ufshcd.c
> +++ b/drivers/scsi/ufs/ufshcd.c
> @@ -7964,13 +7964,13 @@ static int ufshcd_clear_ua_wluns(struct ufs_hba
> *hba)
>  }
> 
>  /**
> - * ufshcd_probe_hba - probe hba to detect device and initialize
> + * ufshcd_probe_hba - probe hba to detect device and initialize it
>   * @hba: per-adapter instance
> - * @async: asynchronous execution or not
> + * @init_dev_params: whether or not to call ufshcd_device_params_init().
>   *
>   * Execute link-startup and verify device initialization
>   */
> -static int ufshcd_probe_hba(struct ufs_hba *hba, bool async)
> +static int ufshcd_probe_hba(struct ufs_hba *hba, bool init_dev_params)
>  {
>         int ret;
>         unsigned long flags;
> @@ -8002,7 +8002,7 @@ static int ufshcd_probe_hba(struct ufs_hba *hba,
> bool async)
>          * Initialize UFS device parameters used by driver, these
>          * parameters are associated with UFS descriptors.
>          */
> -       if (async) {
> +       if (init_dev_params) {
>                 ret = ufshcd_device_params_init(hba);
>                 if (ret)
>                         goto out;
diff mbox series

Patch

diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index 25fe18a36cd2..c230d2a6a55c 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs/ufshcd.c
@@ -7964,13 +7964,13 @@  static int ufshcd_clear_ua_wluns(struct ufs_hba *hba)
 }
 
 /**
- * ufshcd_probe_hba - probe hba to detect device and initialize
+ * ufshcd_probe_hba - probe hba to detect device and initialize it
  * @hba: per-adapter instance
- * @async: asynchronous execution or not
+ * @init_dev_params: whether or not to call ufshcd_device_params_init().
  *
  * Execute link-startup and verify device initialization
  */
-static int ufshcd_probe_hba(struct ufs_hba *hba, bool async)
+static int ufshcd_probe_hba(struct ufs_hba *hba, bool init_dev_params)
 {
 	int ret;
 	unsigned long flags;
@@ -8002,7 +8002,7 @@  static int ufshcd_probe_hba(struct ufs_hba *hba, bool async)
 	 * Initialize UFS device parameters used by driver, these
 	 * parameters are associated with UFS descriptors.
 	 */
-	if (async) {
+	if (init_dev_params) {
 		ret = ufshcd_device_params_init(hba);
 		if (ret)
 			goto out;