Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Interesting.

I think the mnt_* call is checking if the file system is mounted/accessible to write the change to the objects inode entry.



Yeah, it is, I just read up on it, it's this function: http://lxr.linux.no/linux+v3.12.6/fs/namespace.c#L404

From what I can gather, if the file handle isn't in write mode or is a special file, then we call __mnt_want_write, http://lxr.linux.no/linux+v3.12.6/fs/namespace.c#L305, otherwise we clone the write handle or something.

I'm surprised how simple this code seems.




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: