writeback: Avoid lockups when switching inodes
Status from this message: Applied to the vfs-6.18.writeback branch of the vfs/vfs.git tree.
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest4 patches 7 repliesApplied
- v14 patches 9 repliesSuperseded
Changes in v2 from the cover letter
* Added Acked-by's from Tejun
* Modified patch 1 to directly insert isw items into a list of switches to make instead of queueing rcu_work for that. This actually speeded up large scale switching about 2x.
Patches in v2 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | writeback: Avoid contention on wb->list_lock when switching inodesfs/ include/ include/ +1 more | +75 | 4 replies | |
| 2/4 | writeback: Avoid softlockup when switching many inodesfs/ | +10 | 0 replies | |
| 3/4 | writeback: Avoid excessively long inode switching timesfs/ | +11 | 0 replies | |
| 4/4 | writeback: Add tracepoint to track pending inode switchesfs/ include/ | +31 | 0 replies |
Reviews trailers per patch
All 4 patches have a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Tejun Heo |
|---|---|
| Series | A-b |
| 1/4 | A-b |
| 2/4 | A-b |
| 3/4 | A-b |
| 4/4 | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v2 0/4] writeback: Avoid lockups when switching inodes
Hello!
This patch series addresses lockups reported by users when systemd unit reading lots of files from a filesystem mounted with lazytime mount option exits. See patch 3 for more details about the reproducer.
There are two main issues why switching many inodes between wbs:
1) Multiple workers will be spawned to do the switching but they all contend on the same wb->list_lock making all the parallelism pointless and just wasting time.
2) Sorting of wb->b_dirty list by dirtied_time_when is inherently slow.
Patches 1-3 address these problems, patch 4 adds a tracepoint for better observability of inode writeback switching.
Changes since v1:
* Added Acked-by's from Tejun
* Modified patch 1 to directly insert isw items into a list of switches to make instead of queueing rcu_work for that. This actually speeded up large scale switching about 2x.
Honza
Previous versions: