Messages in this thread | | | Date | Thu, 24 Jun 1999 09:27:09 -0400 (EDT) | From | Benjamin LaHaise <> | Subject | Re: RFC: BSD system call revoke? |
| |
On Thu, 24 Jun 1999, Matthew Kirkwood wrote:
> Things it needs: > * Someone to verify that vmtruncate(inode, 0) works and is > the right thing to do > * Investigation of how to handle the CLONE_FILES case.
vmtruncate doesn't do what you need to do as it only works on files that are in the page cache, whereas device drivers, like sound, mark their mmap'd pages reserved so that the kernel doesn't touch them. More than likely, you'll have to walk the inode->i_mmap ring and unmap each one. You'll have to be careful about grabbing semaphores. Revoke probably needs to prevent open from grabbing a new file handle before it has finished its work -- add to that the need for the mmap semaphore and there's plenty of ordering constraints.
-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/
| |