Re: [PATCH 3/3] xfs: only iget the file once when doing vectored scrub-by-handle

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Apr 10, 2024 at 09:56:45PM -0700, Darrick J. Wong wrote:
> > Well, someone needs to own it, it's just not just ext4 but could us.
> 
> Er... I don't understand this?        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

If we set current->journal and take a page faul we could not just
recurse into ext4 but into any fs including XFS.  Any everyone
blindly dereferences is as only one fs can own it.

> > > Alloc transaction -> lock rmap btree for repairs -> iscan filesystem to
> > > find rmap records -> iget/irele.
> > 
> > So this is just the magic empty transaction?
> 
> No, that's the fully featured repair transaction that will eventually be
> used to write/commit the new rmap tree.

That seems a bit dangerous to me.  I guess we rely on the code inside
the transaction context to never race with unmount as lack of SB_ACTIVE
will make the VFS ignore the dontcache flag.





[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux