Re: copy_mount_options in 2.3.99-pre9

©[@ÄØÿ¿8þÿ¿Jens Axboe (kernel@kvack.org)
Wed, 28 Jun 2000 17:51:07 -0400 (EDT)


On Tue, 27 Jun 2000, Richard Jerrell wrote:

> There is a bug in copy_mount_options in kernel 2.3.99-pre9. In
>
> fs/super.c:1182 i = copy_from_user((void *)page, data, PAGE_SIZE);

> this message. So in order to fix it, just switch back to the version in
> 2.2.15 where we round off the address to find the page and how much space
> is left before we fault and copy that amount instead of a full page
> always. Here is a snapshot of the dmesg I get when the function is broken

That mechanism was race prone and required additional locking that the
exception fixup code handles nicely.

> VFS: Mounted root (ext2 filesystem) readonly.
> Freeing unused kernel memory: 448k freed
> mount: Exception at [<fffffc00004c0480>] (fffffc00004c04c0)

Which is fine. Turn off the Execption: messages -- leaving them on means
that user programs can perform a DoS attack on your kernel message logs
anyways. It was a debugging thing that was turned off ages ago on x86.

-ben

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