Re: Linux 2.4.1-ac15

Philipp Rumpf (prumpf@mandrakesoft.com)
Mon, 19 Feb 2001 05:54:11 -0600 (CST)


On Mon, 19 Feb 2001, Alan Cox wrote:
> mod->next = module_list;

put_mod_name() here.

> module_list = mod; /* link it in */
>
> Note no write barrier.

put_mod_name calls free_page which always implies a memory barrier. This
isn't beautiful but it won't blow up either.

Actually that isn't relevant since the actual table is copied _after_
ex_table_{start,end}. We'll scan uninitialized memory and if some word
happens to match the fault EIP we jump to the bogus fixup.

> Delete is even worse
>
> We unlink the module
> We free the memory
>
> At the same time another cpu may be walking the exception table that we free.

True.

Rusty had a patch that locked the module list properly IIRC.

-
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/