Hi, I've read about the possible bugs. About the combination between mmap and mandatory locks: of course the mapping of memory is causing troubles when a mandatory lock is set. The mapped region should or forward the lock to the new memory location (where remapped) or the mmap should be denied, unless the locking allows it (when the mandatory lock is read, allow read access, if a write lock, deny all others, also mmap). The first is causing too much overhead, so the second is in my opinion the best option.
Second, when a write is allowed, and a read lock is set (which is possible according to http://kernel.org/doc/Documentation/filesystems/mandatory-locking.txt then the implementation is not right. Like other operations which require exclusive access to a region of a file, like writes do, denying other writes to the same region at the same moment, I guess this locking should also behave like that. If this isn't the case (where theoretically it is possible that writes are done when a read lock is set) then there is something wrong. Stef
_______________________________________________ systemd-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/systemd-devel
