Re: [RFC PATCH] x86: Add safe_udelay() and safe_msleep()

From: Thomas Gleixner
Date: Thu Jan 13 2011 - 17:52:54 EST


On Thu, 13 Jan 2011, Greg KH wrote:
> On Thu, Jan 13, 2011 at 02:21:29PM -0800, Yinghai Lu wrote:
> > +extern void use_normal_delay(void);
> > +extern void use_normal_sleep(void);
> > #endif /* defined(_LINUX_DELAY_H) */
> > Index: linux-2.6/init/main.c
> > ===================================================================
> > --- linux-2.6.orig/init/main.c
> > +++ linux-2.6/init/main.c
> > @@ -879,6 +879,9 @@ static int __init kernel_init(void * unu
> > cad_pid = task_pid(current);
> >
> > smp_prepare_cpus(setup_max_cpus);
> > + /* set them back, x86 use it for early delay*/
> > + use_normal_delay();
> > + use_normal_sleep();
>
> Ick, I really don't like this.
>
> And, most importantly, I'm still not sure it's needed at all, as I don't
> agree with your previous patches that you say this one is needed for.
>
> So, how about we work on the original root problem here before worrying
> about changing the main usleep logic for the whole kernel?

What the hell is the root problem ?

Thanks,

tglx
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/