On Thu, Nov 30, 2023 at 09:14:55AM -0800, Darrick J. Wong wrote: > > > + dfp = kmem_cache_zalloc(xfs_defer_pending_cache, > > > + GFP_NOFS | __GFP_NOFAIL); > > > + dfp->dfp_type = dfp_type; > > > + dfp->dfp_intent = lip; > > > + INIT_LIST_HEAD(&dfp->dfp_work); > > > + INIT_LIST_HEAD(&dfp->dfp_list); > > > + return dfp; > > > +} > > > > Initializing dfp_list here is a bit pointless as the caller instantly > > adds it to log->l_dfops. > > I'd rather pass the list_head into xfs_defer_start_recovery so that it > can create a fully initialized dfp and add it to the tracker. Sounds good to me.