debug.h (75b9130e8af64c6878a1aa396a8446f3ce2cfb49) | debug.h (191648d03d20229523d9a75b8abef56421298d28) |
---|---|
1/* Driver for USB Mass Storage compliant devices 2 * Debugging Functions Header File 3 * 4 * Current development and maintenance by: 5 * (c) 1999-2002 Matthew Dharm (mdharm-usb@one-eyed-alien.net) 6 * 7 * Initial work by: 8 * (c) 1999 Michael Gee (michael@linuxspecific.com) --- 33 unchanged lines hidden (view full) --- 42#ifndef _DEBUG_H_ 43#define _DEBUG_H_ 44 45#include <linux/kernel.h> 46 47#define USB_STORAGE "usb-storage: " 48 49#ifdef CONFIG_USB_STORAGE_DEBUG | 1/* Driver for USB Mass Storage compliant devices 2 * Debugging Functions Header File 3 * 4 * Current development and maintenance by: 5 * (c) 1999-2002 Matthew Dharm (mdharm-usb@one-eyed-alien.net) 6 * 7 * Initial work by: 8 * (c) 1999 Michael Gee (michael@linuxspecific.com) --- 33 unchanged lines hidden (view full) --- 42#ifndef _DEBUG_H_ 43#define _DEBUG_H_ 44 45#include <linux/kernel.h> 46 47#define USB_STORAGE "usb-storage: " 48 49#ifdef CONFIG_USB_STORAGE_DEBUG |
50void usb_stor_show_command(struct scsi_cmnd *srb); 51void usb_stor_show_sense( unsigned char key, 52 unsigned char asc, unsigned char ascq ); 53__printf(1, 2) int usb_stor_dbg(const char *fmt, ...); | 50void usb_stor_show_command(const struct us_data *us, struct scsi_cmnd *srb); 51void usb_stor_show_sense(const struct us_data *us, unsigned char key, 52 unsigned char asc, unsigned char ascq); 53__printf(2, 3) int usb_stor_dbg(const struct us_data *us, 54 const char *fmt, ...); |
54 | 55 |
55#define US_DEBUGP(fmt, ...) usb_stor_dbg(fmt, ##__VA_ARGS__) | |
56#define US_DEBUGPX(fmt, ...) printk(fmt, ##__VA_ARGS__) 57#define US_DEBUG(x) x 58#else | 56#define US_DEBUGPX(fmt, ...) printk(fmt, ##__VA_ARGS__) 57#define US_DEBUG(x) x 58#else |
59#define US_DEBUGP(fmt, ...) \ 60 do { if (0) printk(fmt, ##__VA_ARGS__); } while (0) | 59__printf(2, 3) 60static inline int _usb_stor_dbg(const struct us_data *us, 61 const char *fmt, ...) {return 1;} 62#define usb_stor_dbg(us, fmt, ...) \ 63 do { if (0) _usb_stor_dbg(us, fmt, ##__VA_ARGS__); } while (0) |
61#define US_DEBUGPX(fmt, ...) \ 62 do { if (0) printk(fmt, ##__VA_ARGS__); } while (0) 63#define US_DEBUG(x) 64#endif 65 66#endif | 64#define US_DEBUGPX(fmt, ...) \ 65 do { if (0) printk(fmt, ##__VA_ARGS__); } while (0) 66#define US_DEBUG(x) 67#endif 68 69#endif |