projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cce9fd6
)
scsi: ufs: Simplify zero-initialization
author
Bart Van Assche
<bvanassche@acm.org>
Thu, 27 Jul 2023 19:41:18 +0000
(12:41 -0700)
committer
Martin K. Petersen
<martin.petersen@oracle.com>
Mon, 31 Jul 2023 19:17:50 +0000
(15:17 -0400)
Use { } instead of { { 0 }, } to zero-initialize data structures on the
stack. This patch fixes two W=2 warnings.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Link:
https://lore.kernel.org/r/20230727194457.3152309-7-bvanassche@acm.org
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/ufs/core/ufshcd.c
patch
|
blob
|
history
diff --git
a/drivers/ufs/core/ufshcd.c
b/drivers/ufs/core/ufshcd.c
index ca520f2b1820e98e22db4a108bc2e9ad4971592b..5e248c60f8877f0c1c7cfc1a4ad3946dd3aa121d 100644
(file)
--- a/
drivers/ufs/core/ufshcd.c
+++ b/
drivers/ufs/core/ufshcd.c
@@
-7040,7
+7040,7
@@
static int __ufshcd_issue_tm_cmd(struct ufs_hba *hba,
static int ufshcd_issue_tm_cmd(struct ufs_hba *hba, int lun_id, int task_id,
u8 tm_function, u8 *tm_response)
{
- struct utp_task_req_desc treq = {
{ 0 },
};
+ struct utp_task_req_desc treq = { };
enum utp_ocs ocs_value;
int err;
@@
-7205,7
+7205,7
@@
int ufshcd_exec_raw_upiu_cmd(struct ufs_hba *hba,
{
int err;
enum dev_cmd_type cmd_type = DEV_CMD_TYPE_QUERY;
- struct utp_task_req_desc treq = {
{ 0 },
};
+ struct utp_task_req_desc treq = { };
enum utp_ocs ocs_value;
u8 tm_f = be32_to_cpu(req_upiu->header.dword_1) >> 16 & MASK_TM_FUNC;