Messages in this thread | | | Date | Fri, 6 Feb 2004 18:22:08 +0000 | From | viro@parcelfa ... | Subject | Re: IA32 (2.6.2 - 2004-02-05.22.30) - 3 New warnings (gcc 3.2.2) |
| |
On Fri, Feb 06, 2004 at 08:52:00AM -0800, Linus Torvalds wrote: > > > On Fri, 6 Feb 2004 viro@parcelfarce.linux.theplanet.co.uk wrote: > > > > IOW, gcc doesn't realize that we never return from BUG(). AFAICS, it > > should. Some changes of __volatile__ semantics? > > Thsrs is no way to tell gcc that an inline asm doesn't return. The only > way to do it would be to add something like a "for (;;);" (that gcc will > actually generate real code for) inside the BUG() macro, but I'd hate to > do that.
Umm... How about
static inline void BUG() __attribute__((noreturn));
static inline void BUG(void) { __asm__ .... } > Better to just initialize the variable to a default value and avoid the > warning for now.
Alternatively, we can just turn the damn thing into if (dev->mode == IMM_NIBBLE || dev->mode = IMM_PS2) ports = 3; else ports = 8; and be done with that... - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |