Hi Greg, the recent reorganisation of the speedtouch driver broke the logic that turns on debugging output in speedtch.c and usb_atm.c when DEBUG or CONFIG_USB_DEBUG is set. This patch fixes things up, and moves duplicated debugging code into the header file.
Signed-off-by: Duncan Sands <[EMAIL PROTECTED]> --- linux-2.5/drivers/usb/atm/usb_atm.c.orig 2004-12-22 14:27:18.575681693 +0100 +++ linux-2.5/drivers/usb/atm/usb_atm.c 2004-12-22 16:01:23.536109697 +0100 @@ -83,23 +83,6 @@ #include "usb_atm.h" -/* -#define DEBUG -#define VERBOSE_DEBUG -*/ - -#if !defined (DEBUG) && defined (CONFIG_USB_DEBUG) -# define DEBUG -#endif - -#include <linux/usb.h> - -#ifdef DEBUG -#define UDSL_ASSERT(x) BUG_ON(!(x)) -#else -#define UDSL_ASSERT(x) do { if (!(x)) warn("failed assertion '" #x "' at line %d", __LINE__); } while(0) -#endif - #ifdef VERBOSE_DEBUG static int udsl_print_packet(const unsigned char *data, int len); #define PACKETDEBUG(arg...) udsl_print_packet (arg) --- linux-2.5/drivers/usb/atm/speedtch.c.orig 2004-12-22 14:34:55.172844490 +0100 +++ linux-2.5/drivers/usb/atm/speedtch.c 2004-12-22 14:52:40.066664725 +0100 @@ -44,30 +44,10 @@ #include "usb_atm.h" -/* -#define DEBUG -#define VERBOSE_DEBUG -*/ - -#if !defined (DEBUG) && defined (CONFIG_USB_DEBUG) -# define DEBUG -#endif - -#include <linux/usb.h> - #if defined(CONFIG_FW_LOADER) || defined(CONFIG_FW_LOADER_MODULE) # define USE_FW_LOADER #endif -#ifdef VERBOSE_DEBUG -static int udsl_print_packet(const unsigned char *data, int len); -#define PACKETDEBUG(arg...) udsl_print_packet (arg) -#define vdbg(arg...) dbg (arg) -#else -#define PACKETDEBUG(arg...) -#define vdbg(arg...) -#endif - #define DRIVER_AUTHOR "Johan Verrept, Duncan Sands <[EMAIL PROTECTED]>" #define DRIVER_VERSION "1.8" #define DRIVER_DESC "Alcatel SpeedTouch USB driver version " DRIVER_VERSION --- linux-2.5/drivers/usb/atm/usb_atm.h.orig 2004-12-22 14:57:28.174930423 +0100 +++ linux-2.5/drivers/usb/atm/usb_atm.h 2004-12-22 16:03:04.161548215 +0100 @@ -21,13 +21,30 @@ * ******************************************************************************/ +#include <linux/config.h> #include <linux/list.h> -#include <linux/usb.h> #include <linux/kref.h> #include <linux/atm.h> #include <linux/atmdev.h> #include <asm/semaphore.h> +/* +#define DEBUG +#define VERBOSE_DEBUG +*/ + +#if !defined (DEBUG) && defined (CONFIG_USB_DEBUG) +# define DEBUG +#endif + +#include <linux/usb.h> + +#ifdef DEBUG +#define UDSL_ASSERT(x) BUG_ON(!(x)) +#else +#define UDSL_ASSERT(x) do { if (!(x)) warn("failed assertion '" #x "' at line %d", __LINE__); } while(0) +#endif + #define UDSL_MAX_RCV_URBS 4 #define UDSL_MAX_SND_URBS 4 #define UDSL_MAX_RCV_BUFS 8 ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://productguide.itmanagersjournal.com/ _______________________________________________ linux-usb-devel@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel