Re: __bad_udelay in 2.2.18pre15

2000-10-11 Thread Ralf Baechle
On Wed, Oct 11, 2000 at 12:13:48PM +0200, Benjamin Herrenschmidt wrote: > >Well, at first, I wanted to implement it the same way on PPC. However, it > >dies on all occurences where udelay is called with a non-constant expression. > > > >I spotted this case in a few PPC specific stuffs (fixable),

Re: __bad_udelay in 2.2.18pre15

2000-10-11 Thread Alan Cox
> Wouldn't it be better to use an #error directive? I'm sure this could turn > into a FAQ, even though the symbol is called "__bad_udelay()". You cant do that trick since #error is pre-processor, otherwise - yes > - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the

Re: __bad_udelay in 2.2.18pre15

2000-10-11 Thread Benjamin Herrenschmidt
> >Yep. This is a huge release patch anyway so resynching the stuff is fine. >What I wont take is stuff touching core code I do have a 2 lines patch to the common ide code that fix a problem when revalidating a CD-ROM after sleep, but it was ack'ed by Andre Hedrick. I also have a two-liners to k

Re: __bad_udelay in 2.2.18pre15

2000-10-11 Thread Andreas Schwab
"Chris Swiedler" <[EMAIL PROTECTED]> writes: |> > > 2.2.18pre15 defines udelay as (in file include/asm-i386/delay.h) : |> > > extern void __bad_udelay(void); |> > > |> > > #define udelay(n) (__builtin_constant_p(n) ? \ |> > > ((n) > 2 ? __bad_udelay() : __const_udelay((n) * |> > > 0x1

RE: __bad_udelay in 2.2.18pre15

2000-10-11 Thread Chris Swiedler
> > 2.2.18pre15 defines udelay as (in file include/asm-i386/delay.h) : > > extern void __bad_udelay(void); > > > > #define udelay(n) (__builtin_constant_p(n) ? \ > > ((n) > 2 ? __bad_udelay() : __const_udelay((n) * > > 0x10c6ul)) : \ > > __udelay(n)) > > > > ... > > It seems __

Re: __bad_udelay in 2.2.18pre15

2000-10-11 Thread Alan Cox
> later, I have to extract them from my tree. Well... would you accept a > huge pile of PPC patches for 2.2.18 in this case, I can send you my > current diffs (with a bit of cleanup) ? Yep. This is a huge release patch anyway so resynching the stuff is fine. What I wont take is stuff touching co

Re: __bad_udelay in 2.2.18pre15

2000-10-11 Thread Benjamin Herrenschmidt
>> >> Well, at first, I wanted to implement it the same way on PPC. However, it >> dies on all occurences where udelay is called with a non-constant >expression. > >__builtin_constant_p means non constant expressions will always call udelay > >> I spotted this case in a few PPC specific stuffs (f

Re: __bad_udelay in 2.2.18pre15

2000-10-11 Thread Alan Cox
> >> #define udelay(n) (__builtin_constant_p(n) ? \ > >> ((n) > 2 ? __bad_udelay() : __const_udelay((n) * > >> 0x10c6ul)) : \ > >> __udelay(n)) > >> > >> ... > >> It seems __bad_udelay is not defined anywhere in the kernel source. > > > >Correct. Its a compile time error tra

Re: __bad_udelay in 2.2.18pre15

2000-10-11 Thread Benjamin Herrenschmidt
>Well, at first, I wanted to implement it the same way on PPC. However, it >dies on all occurences where udelay is called with a non-constant expression. > >I spotted this case in a few PPC specific stuffs (fixable), but also in >the sys_nanosleep code, and in the de4x5 driver. Hrm... looks like

Re: __bad_udelay in 2.2.18pre15

2000-10-11 Thread Benjamin Herrenschmidt
>> 2.2.18pre15 defines udelay as (in file include/asm-i386/delay.h) : >> extern void __bad_udelay(void); >> >> #define udelay(n) (__builtin_constant_p(n) ? \ >> ((n) > 2 ? __bad_udelay() : __const_udelay((n) * >> 0x10c6ul)) : \ >> __udelay(n)) >> >> ... >> It seems __bad_ud

Re: __bad_udelay in 2.2.18pre15

2000-10-10 Thread Horst von Brand
Marcelo Tosatti <[EMAIL PROTECTED]> said: > 2.2.18pre15 defines udelay as (in file include/asm-i386/delay.h) : > > ... > > extern void __bad_udelay(void); > > ... > > #define udelay(n) (__builtin_constant_p(n) ? \ > ((n) > 2 ? __bad_udelay() : __const_udelay((n) * > 0x10c6ul)) : \

Re: __bad_udelay in 2.2.18pre15

2000-10-10 Thread Alan Cox
> 2.2.18pre15 defines udelay as (in file include/asm-i386/delay.h) : > extern void __bad_udelay(void); > > #define udelay(n) (__builtin_constant_p(n) ? \ > ((n) > 2 ? __bad_udelay() : __const_udelay((n) * > 0x10c6ul)) : \ > __udelay(n)) > > ... > It seems __bad_udelay is no

Re: __bad_udelay in 2.2.18pre15

2000-10-10 Thread Marcus Sundberg
Marcelo Tosatti <[EMAIL PROTECTED]> writes: > 2.2.18pre15 defines udelay as (in file include/asm-i386/delay.h) : > > ... > > extern void __bad_udelay(void); > > ... > > #define udelay(n) (__builtin_constant_p(n) ? \ > ((n) > 2 ? __bad_udelay() : __const_udelay((n) * > 0x10c6ul))

__bad_udelay in 2.2.18pre15

2000-10-10 Thread Marcelo Tosatti
2.2.18pre15 defines udelay as (in file include/asm-i386/delay.h) : ... extern void __bad_udelay(void); ... #define udelay(n) (__builtin_constant_p(n) ? \ ((n) > 2 ? __bad_udelay() : __const_udelay((n) * 0x10c6ul)) : \ __udelay(n)) ... It seems __bad_udelay is not defi