Commit 36f3a14d authored by Felipe Balbi's avatar Felipe Balbi Committed by Greg Kroah-Hartman

usb: storage: ene_ub6250: fix sparse warnings

Fix the following sparse warnings:

| drivers/usb/storage/ene_ub6250.c:45:22: warning: symbol
|	'ene_ub6250_usb_ids' was not declared. Should it
|	be static?
|
| drivers/usb/storage/ene_ub6250.c:780:5: warning: symbol
|	'ms_lib_alloc_logicalmap' was not declared. Should it
|	be static?
|
| drivers/usb/storage/ene_ub6250.c:2251:5: warning: symbol
|	'ms_scsi_irp' was not declared. Should it be static?
|
| drivers/usb/storage/ene_ub6250.c:638:29: warning: right shift by bigger
|	than source value
|
| drivers/usb/storage/ene_ub6250.c:639:29: warning: right shift by bigger
|	than source value
Signed-off-by: default avatarFelipe Balbi <balbi@ti.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent b03379f7
...@@ -42,7 +42,7 @@ MODULE_LICENSE("GPL"); ...@@ -42,7 +42,7 @@ MODULE_LICENSE("GPL");
{ USB_DEVICE_VER(id_vendor, id_product, bcdDeviceMin, bcdDeviceMax), \ { USB_DEVICE_VER(id_vendor, id_product, bcdDeviceMin, bcdDeviceMax), \
.driver_info = (flags)|(USB_US_TYPE_STOR<<24) } .driver_info = (flags)|(USB_US_TYPE_STOR<<24) }
struct usb_device_id ene_ub6250_usb_ids[] = { static struct usb_device_id ene_ub6250_usb_ids[] = {
# include "unusual_ene_ub6250.h" # include "unusual_ene_ub6250.h"
{ } /* Terminating entry */ { } /* Terminating entry */
}; };
...@@ -607,8 +607,8 @@ static int sd_scsi_mode_sense(struct us_data *us, struct scsi_cmnd *srb) ...@@ -607,8 +607,8 @@ static int sd_scsi_mode_sense(struct us_data *us, struct scsi_cmnd *srb)
static int sd_scsi_read_capacity(struct us_data *us, struct scsi_cmnd *srb) static int sd_scsi_read_capacity(struct us_data *us, struct scsi_cmnd *srb)
{ {
u32 bl_num; u32 bl_num;
u16 bl_len; u32 bl_len;
unsigned int offset = 0; unsigned int offset = 0;
unsigned char buf[8]; unsigned char buf[8];
struct scatterlist *sg = NULL; struct scatterlist *sg = NULL;
...@@ -622,7 +622,7 @@ static int sd_scsi_read_capacity(struct us_data *us, struct scsi_cmnd *srb) ...@@ -622,7 +622,7 @@ static int sd_scsi_read_capacity(struct us_data *us, struct scsi_cmnd *srb)
else else
bl_num = (info->HC_C_SIZE + 1) * 1024 - 1; bl_num = (info->HC_C_SIZE + 1) * 1024 - 1;
} else { } else {
bl_len = 1<<(info->SD_READ_BL_LEN); bl_len = 1 << (info->SD_READ_BL_LEN);
bl_num = info->SD_Block_Mult * (info->SD_C_SIZE + 1) bl_num = info->SD_Block_Mult * (info->SD_C_SIZE + 1)
* (1 << (info->SD_C_SIZE_MULT + 2)) - 1; * (1 << (info->SD_C_SIZE_MULT + 2)) - 1;
} }
...@@ -777,7 +777,7 @@ static int ms_lib_free_logicalmap(struct us_data *us) ...@@ -777,7 +777,7 @@ static int ms_lib_free_logicalmap(struct us_data *us)
return 0; return 0;
} }
int ms_lib_alloc_logicalmap(struct us_data *us) static int ms_lib_alloc_logicalmap(struct us_data *us)
{ {
u32 i; u32 i;
struct ene_ub6250_info *info = (struct ene_ub6250_info *) us->extra; struct ene_ub6250_info *info = (struct ene_ub6250_info *) us->extra;
...@@ -2249,7 +2249,7 @@ static int sd_scsi_irp(struct us_data *us, struct scsi_cmnd *srb) ...@@ -2249,7 +2249,7 @@ static int sd_scsi_irp(struct us_data *us, struct scsi_cmnd *srb)
/* /*
* ms_scsi_irp() * ms_scsi_irp()
*/ */
int ms_scsi_irp(struct us_data *us, struct scsi_cmnd *srb) static int ms_scsi_irp(struct us_data *us, struct scsi_cmnd *srb)
{ {
int result; int result;
struct ene_ub6250_info *info = (struct ene_ub6250_info *)us->extra; struct ene_ub6250_info *info = (struct ene_ub6250_info *)us->extra;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment