Linux-kernel mailing list archive 2000-04,: Re: buggy GFP_KERNEL allocators

# Re: buggy GFP_KERNEL allocators

Rik van Riel (riel@nl.linux.org)
Thu, 27 Jan 2000 05:16:28 +0100 (CET)

- Messages sorted by: [ date ][ thread ][ subject ][ author ]
- Next message: Brad Douglas: "[DRIVER UPDATE] aty128fb"
- Previous message: Rik van Riel: "Re: problem with linux 2.2.15pre4 + Rik's VM fix"

On Wed, 26 Jan 2000, Ben LaHaise wrote:
> On Wed, 26 Jan 2000 kuznet@ms2.inr.ac.ru wrote:
>
> > Hello!
> >
> > > + current->state = TASK_RUNNING; /* We *must* do this before touching userspace! */
> >
> > This smells suspiciously. Page fault code should not stuck only because
> > task state is not running. It contaradicts all the idea behind wait queues.
> >
> > Essentially, fault is like signal. It must move task state to running.
>
> Applying the change to the page fault handler might just be the
> right thing to do, and in fact it would make sense in 2.3 to have
> the fault handler also switch to lazy tlb mode if the task has to
> perform io. The fault handler does neither of these things right
> now, and in fact this was causing occasional stuck tasks if the
> fault ended up calling schedule before changing current->state.

Won't we confuse lots of pieces of code when their
TASK_UNINTERRUPTIBLE process is returned to them as
a TASK_RUNNING one?

I'm somewhat afraid that we will break code whichever
way we go. That's why I've added a no-sleep workaround
to __get_free_pages() (hey, this isn't happening often
enough to run us out of memory) and added the printk()
to warn us about potentially dangerous code.

regards,

Rik

    --
    The Internet is not a network of computers. It is a network
    of people. That is its real strength.

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

- Next message: Brad Douglas: "[DRIVER UPDATE] aty128fb"
- Previous message: Rik van Riel: "Re: problem with linux 2.2.15pre4 + Rik's VM fix"