From: viro@ZenIV.linux.org.uk Date: Wed, 7 Sep 2005 22:18:24 +0000 (+0100) Subject: [PATCH] -Wundef fixes (ncr5380) X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=185a7a1cd79b9891e3c17abdb103ba1c98d6ca7a;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git [PATCH] -Wundef fixes (ncr5380) NDEBUG and NDEBUG_ABORT are almost always used as integers in NCR5380; added define to 0 if they are not defined, switched lone ifdef NDEBUG into if. Signed-off-by: Al Viro Signed-off-by: Linus Torvalds --- diff --git a/drivers/scsi/NCR5380.c b/drivers/scsi/NCR5380.c index f8ec6fe7d858..d40ba0bd68a3 100644 --- a/drivers/scsi/NCR5380.c +++ b/drivers/scsi/NCR5380.c @@ -88,6 +88,13 @@ */ #include +#ifndef NDEBUG +#define NDEBUG 0 +#endif +#ifndef NDEBUG +#define NDEBUG_ABORT 0 +#endif + #if (NDEBUG & NDEBUG_LISTS) #define LIST(x,y) {printk("LINE:%d Adding %p to %p\n", __LINE__, (void*)(x), (void*)(y)); if ((x)==(y)) udelay(5); } #define REMOVE(w,x,y,z) {printk("LINE:%d Removing: %p->%p %p->%p \n", __LINE__, (void*)(w), (void*)(x), (void*)(y), (void*)(z)); if ((x)==(y)) udelay(5); } @@ -359,7 +366,7 @@ static struct { {PHASE_UNKNOWN, "UNKNOWN"} }; -#ifdef NDEBUG +#if NDEBUG static struct { unsigned char mask; const char *name;