ubifs: respect dirty_writeback_interval
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest0 of 2 patches 2 repliesIn review
Patches in v1 No applies recorded yet
None of the 2 patches the cover letter announces are in this archive.
Reviews trailers per patch
| Patch | Boris Brezillon |
|---|---|
| Series | R-b R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH 0/2] ubifs: respect dirty_writeback_interval
From: Rafał Miłecki <[email protected]>
Hi,
This patchset allows some ubifs adjustments that we realized we needed in LEDE project.
LEDE can be unstable on power cuts when installed on NAND devices (with ubifs). This is caused by the default high value of wbuf timeout used by ubifs. Any write that isn't followed by fsync (this may happen with buggy user space app or just shell script) may be lost if power cut happens in less than 5 seconds.
One idea for fixing this (without modifying kernel at all) is to mount ubifs with -o sync. This could affect NAND performance however, so I'm looking for a better solution.
During IRC discussion MTD guys suggested lowering wbuf timeout and I decided to give it a try. The simplest way to do that seems to be making ubifs respect dirty_writeback_interval. This parameter can be easily set with sysctl and is already used in some older file systems.
What do you think about this? I gave it a try with a simple uci commit foo; sleep 1s; POWER_CUT
and it works as expected.
Rafał Miłecki (2):
ubifs: drop softlimit and delta fields from struct ubifs_wbuf
ubifs: use dirty_writeback_interval value for wbuf timer
fs/ubifs/io.c | 15 +++++++-------- fs/ubifs/ubifs.h | 9 --------- 2 files changed, 7 insertions(+), 17 deletions(-)
Signature · 1 line
2.9.3