Skip to content

Commit

Permalink
usb: storage: remove redundant memset() in usb_probe_stor1()
Browse files Browse the repository at this point in the history
scsi_host_alloc() will zero our private data, no need to memset it.

Signed-off-by: Yan Hong <clouds.yan@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Yan Hong authored and Greg Kroah-Hartman committed Nov 26, 2012
1 parent f36446c commit 1ac9060
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion drivers/usb/storage/usb.c
Original file line number Diff line number Diff line change
Expand Up @@ -925,7 +925,6 @@ int usb_stor_probe1(struct us_data **pus,
host->max_cmd_len = 16;
host->sg_tablesize = usb_stor_sg_tablesize(intf);
*pus = us = host_to_us(host);
memset(us, 0, sizeof(struct us_data));
mutex_init(&(us->dev_mutex));
us_set_lock_class(&us->dev_mutex, intf);
init_completion(&us->cmnd_ready);
Expand Down

0 comments on commit 1ac9060

Please sign in to comment.