Re: [PATCH 1/2] xfs: streamline xfs_filestream_pick_ag

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

 



On Tue, Oct 22, 2024 at 11:05:35AM -0700, Darrick J. Wong wrote:
> On Tue, Oct 22, 2024 at 02:13:37PM +0200, Christoph Hellwig wrote:
> > Directly return the error from xfs_bmap_longest_free_extent instead
> > of breaking from the loop and handling it there, and use a done
> > label to directly jump to the exist when we found a suitable perag
> > structure to reduce the indentation level and pag/max_pag check
> > complexity in the tail of the function.
> > 
> > Signed-off-by: Christoph Hellwig <hch@xxxxxx>
> 
> So the key change here is that now the function can exit directly from
> the for_each_perag_wrap loop if it finds a suitable perag, and that the
> rest of the function has less indentation?

Yes.

> Ok, sounds good to me though the bugfix probably should've come first.

I needed the refactor to understand the mess in the function :)
But I'll reorder it.





[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