Re: atomic copy_from_user?

From: Andrew Morton
Date: Mon Dec 22 2003 - 17:24:54 EST


Joe Korty <joe.korty@xxxxxxxx> wrote:
>
> > inc_preempt_count() and dec_preempt_count() are for use when you
> > _absolutely_ must manage the preemption counter, regardless of whether
> > or not kernel preemption is enabled.
> >
> > They are used for things like atomic kmaps.
>
> Hi Robert,
> I do not see why a non-preempt kernel would care at all about
> the value of preempt_count. (kmap_atomic is obviously setting it,
> where is the place in a non-preempt kernel where the set value
> is being acted upon?).

do_page_fault()'s in_atomic() test.
-
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/