Commit e5283626 authored by Joe Perches's avatar Joe Perches Committed by Greg Kroah-Hartman

usb: storage: Convert usb_stor_dbg to return void

No caller or macro uses the return value so make it void.
Signed-off-by: default avatarJoe Perches <joe@perches.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 474fe70b
......@@ -179,17 +179,14 @@ void usb_stor_show_sense(const struct us_data *us,
US_DEBUGPX("\n");
}
int usb_stor_dbg(const struct us_data *us, const char *fmt, ...)
void usb_stor_dbg(const struct us_data *us, const char *fmt, ...)
{
va_list args;
int r;
va_start(args, fmt);
r = dev_vprintk_emit(7, &us->pusb_dev->dev, fmt, args);
dev_vprintk_emit(7, &us->pusb_dev->dev, fmt, args);
va_end(args);
return r;
}
EXPORT_SYMBOL_GPL(usb_stor_dbg);
......@@ -50,15 +50,17 @@
void usb_stor_show_command(const struct us_data *us, struct scsi_cmnd *srb);
void usb_stor_show_sense(const struct us_data *us, unsigned char key,
unsigned char asc, unsigned char ascq);
__printf(2, 3) int usb_stor_dbg(const struct us_data *us,
const char *fmt, ...);
__printf(2, 3) void usb_stor_dbg(const struct us_data *us,
const char *fmt, ...);
#define US_DEBUGPX(fmt, ...) printk(fmt, ##__VA_ARGS__)
#define US_DEBUG(x) x
#else
__printf(2, 3)
static inline int _usb_stor_dbg(const struct us_data *us,
const char *fmt, ...) {return 1;}
static inline void _usb_stor_dbg(const struct us_data *us,
const char *fmt, ...)
{
}
#define usb_stor_dbg(us, fmt, ...) \
do { if (0) _usb_stor_dbg(us, fmt, ##__VA_ARGS__); } while (0)
#define US_DEBUGPX(fmt, ...) \
......
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