RFC fs: generic filesystem shutdown handling
Get series with b4
b4 am [email protected]Versions newest first
- v1 RFC Latest13 patches 11 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/13 | fs: Define bit numbers for SB_I_ flagsinclude/ | +34 | 0 replies | |
| 2/13 | fs: Convert fs_context use of SB_I_ flags to new constantsblock/ fs/ fs/ | +3 | 0 replies | |
| 3/13 | fs: Convert mount_too_revealing() to new s_iflags handling functionsfs/ | +4 | 0 replies | |
| 4/13 | fs: Convert remaining usage of SB_I_ flagsdrivers/ fs/ fs/ +22 more | +44 | 0 replies | |
| 5/13 | fs: Drop old SB_I_ constantsinclude/ | +0 | 0 replies | |
| 6/13 | fs: Drop unnecessary underscore from _SB_I_ constantsblock/ drivers/ fs/ +26 more | +63 | 4 replies | |
| 7/13 | overlayfs: Make ovl_start_write() return errorfs/ fs/ fs/ | +36 | 1 reply | |
| 8/13 | fs: Teach callers of kiocb_start_write() to handle errorsfs/ fs/ include/ +1 more | +19 | 0 replies | |
| 9/13 | fs: Teach callers of file_start_write() to handle errorsfs/ fs/ fs/ +6 more | +42 | 0 replies | |
| 10/13 | fs: Add __must_check annotations to sb_start_write_trylock() and similarinclude/ | +4 | 0 replies | |
| 11/13 | fs: Make sb_start_write() return error on shutdown filesystemfs/ fs/ fs/ +7 more | +46 | 0 replies | |
| 12/13 | fs: Make sb_start_pagefault() return error on shutdown filesystemfs/ fs/ fs/ +16 more | +45 | 0 replies | |
| 13/13 | ext4: Replace EXT4_FLAGS_SHUTDOWN flag with a generic SB_I_SHUTDOWNfs/ fs/ fs/ | +9 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH RFC 0/13] fs: generic filesystem shutdown handling
Hello,
this patch series implements generic handling of filesystem shutdown. The idea is very simple: Have a superblock flag, which when set, will make VFS refuse modifications to the filesystem. The patch series consists of several parts. Patches 1-6 cleanup handling of SB_I_ flags which is currently messy (different flags seem to have different locks protecting them although they are modified by plain stores). Patches 7-12 gradually convert code to be able to handle errors from sb_start_write() / sb_start_pagefault(). Patch 13 then shows how filesystems can use this generic flag. Additionally, we could remove some shutdown checks from within ext4 code and rely on checks in VFS but I didn't want to complicate the series with ext4 specific things.
Also, as Dave suggested, we can lift *_IOC_{SHUTDOWN|GOINGDOWN} ioctl handling to VFS (currently in 5 filesystems) and just call new ->shutdown op for the filesystem abort handling itself. But that is kind of independent thing and this series is long enough as is.
So what do people think?
Honza