From: Mark Knibbs Date: Sun, 21 Sep 2014 18:59:42 +0000 (+0100) Subject: storage: Replace magic number with define in usb_stor_euscsi_init() X-Git-Tag: v4.9.8~5607^2~29 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=bda9893c50fb56253d3c206c14e3f933e5f68b3c;p=platform%2Fkernel%2Flinux-rpi3.git storage: Replace magic number with define in usb_stor_euscsi_init() usb_stor_euscsi_init() calls usb_stor_control_msg() with timeout argument 5000. USB_CTRL_SET_TIMEOUT is defined to be 5000 in usb.h, so would it make sense to use that instead? Patch below if it would. Signed-off-by: Mark Knibbs Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/usb/storage/initializers.c b/drivers/usb/storage/initializers.c index 5a8b5ff..4bc2fc9 100644 --- a/drivers/usb/storage/initializers.c +++ b/drivers/usb/storage/initializers.c @@ -52,7 +52,7 @@ int usb_stor_euscsi_init(struct us_data *us) us->iobuf[0] = 0x1; result = usb_stor_control_msg(us, us->send_ctrl_pipe, 0x0C, USB_RECIP_INTERFACE | USB_TYPE_VENDOR, - 0x01, 0x0, us->iobuf, 0x1, 5000); + 0x01, 0x0, us->iobuf, 0x1, USB_CTRL_SET_TIMEOUT); usb_stor_dbg(us, "-- result is %d\n", result); return 0;