Re: [PATCH] xfs: update BDI {io,ra}_pages values based on the RT device limits
Carlos Maiolino <[email protected]>
| Newsgroups | org.kernel.vger.linux-xfs,org.kernel.vger.linux-fsdevel |
|---|---|
| Message-ID | <[email protected]> |
On Mon, Jul 20, 2026 at 11:11:28AM +0200, Christoph Hellwig wrote: > On Mon, Jul 20, 2026 at 11:02:15AM +0200, Carlos Maiolino wrote: > > On Tue, Jun 23, 2026 at 04:21:06PM +0200, Christoph Hellwig wrote: > > > When using XFS with a main device on an SSD that stores metadata and a RT > > > device to store data on a HDD, we fail to take the I/O sizes for the RT > > > device into accounting, leading to up to 5% slower read performance when > > > using an SSD for metadata vs storing data and metadata on the HDD. > > > > > > Fix this up by taking the RT settings into account. Note that this > > > updates the BDI owned by the main device, and leaves those settings in > > > place even when the file system is unmounted. This is a bit unexpected > > > but not different from manual tuning through sysfs (although that is only > > > possible for the ra_pages value). > > > > Sorry a 'very late reply', but... > > On a second thought, wouldn't be wise to cache the original value in > > memory and restore it during unmount/filesystem shutdown? > > > > I could send a patch to complement this one if you guys agree, otherwise > > just ignore me. > > As mentioned this does seem like a valid option, there's tradeoff > both ways. Although we'd also want a flag to avoid restoring them > if they were changed while mounted so it would get a bit more > complicated. Happy to respin it for that if there is a general > preference. > Sorry coming back late to it, I don't want to give you extra work after we've already discussed the implementation. I was going to merge this patch today, but it came to my mind that might not be a good idea to just quietly update BDI settings while XFS is using it and just keep whatever change we made persist after the mount. I can still merge it this week and we decide what to do later or just wait a bit for extra thoughts on this. Perhaps let's see if we get other comments soon and we make a decision later this week.