Re: [PATCH v2 3/3] scsi: ufs: cleanup ufs initialization path

2020-05-28 Thread Stanley Chu
Hi Bean, On Thu, 2020-05-28 at 13:56 +0200, Bean Huo wrote: > From: Bean Huo > > At UFS initialization stage, to get the length of the descriptor, > ufshcd_read_desc_length() being called 6 times. This patch is to > delete unnecessary reduntant code, remove ufshcd_read_desc_length() > and boost

Re: [PATCH v2 3/3] scsi: ufs: cleanup ufs initialization path

2020-05-28 Thread Bart Van Assche
On 2020-05-28 07:58, Avri Altman wrote: >> From: Bean Huo >> +static void ufshcd_update_desc_length(struct ufs_hba *hba, >> + enum desc_idn desc_id, int desc_len) > desc_len is at most 255 so maybe u8? At least on x86 using types like 'u8' for function

Re: [PATCH v2 3/3] scsi: ufs: cleanup ufs initialization path

2020-05-28 Thread Bean Huo
On Thu, 2020-05-28 at 14:58 +, Avri Altman wrote: > Hi, > > > From: Bean Huo > > > > At UFS initialization stage, to get the length of the descriptor, > > ufshcd_read_desc_length() being called 6 times. > > May I suggest one more clarifying sentence to your commit log: > "Instead, we will

Re: [PATCH v2 3/3] scsi: ufs: cleanup ufs initialization path

2020-05-28 Thread Bart Van Assche
On 2020-05-28 04:56, Bean Huo wrote: > At UFS initialization stage, to get the length of the descriptor, > ufshcd_read_desc_length() being called 6 times. This patch is to > delete unnecessary reduntant code, remove ufshcd_read_desc_length() > and boost UFS initialization. As explained in

RE: [PATCH v2 3/3] scsi: ufs: cleanup ufs initialization path

2020-05-28 Thread Avri Altman
Hi, > From: Bean Huo > > At UFS initialization stage, to get the length of the descriptor, > ufshcd_read_desc_length() being called 6 times. May I suggest one more clarifying sentence to your commit log: "Instead, we will capture the descriptor size the first time we'll read it." >This patch

[PATCH v2 3/3] scsi: ufs: cleanup ufs initialization path

2020-05-28 Thread Bean Huo
From: Bean Huo At UFS initialization stage, to get the length of the descriptor, ufshcd_read_desc_length() being called 6 times. This patch is to delete unnecessary reduntant code, remove ufshcd_read_desc_length() and boost UFS initialization. Signed-off-by: Bean Huo ---