Re: [PATCH][0/8] (Targeting 2.6.17) Posix memory locking and balancedmlock-LRU semantic

From: Nick Piggin
Date: Fri Mar 24 2006 - 13:24:27 EST


Stone Wang wrote:
2006/3/21, Nick Piggin <nickpiggin@xxxxxxxxxxxx>:

In what way are we not now posix compliant now?


Currently, Linux's mlock for example, may fail with only part of its
task finished.

While accroding to POSIX definition:

man mlock(2)

"
RETURN VALUE
On success, mlock returns zero. On error, -1 is returned, errno is set
appropriately, and no changes are made to any locks in the address
space of the process.
"


Looks like you're right, so good catch. You should probably try to submit your
posix mlock patch by itself then. Make sure you look at the coding standards
though, and try to _really_ follow coding conventions of the file you're
modifying.

You also should make sure the patch works standalone (ie. not just as part of
a set). Oh, and introducing a new field in vma for a flag is probably not the
best option if you still have room in the vm_flags field.

And the patch changelog should contain the actual problem, and quote the
relevant part of the POSIX definition, if applicable.

Thanks,
Nick

--
SUSE Labs, Novell Inc.
Send instant messages to your online friends http://au.messenger.yahoo.com -
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/