]> Gentwo Git Trees - linux/.git/commitdiff
xfs: use zi more in xfs_zone_gc_mount
authorChristoph Hellwig <hch@lst.de>
Tue, 18 Nov 2025 06:49:42 +0000 (07:49 +0100)
committerCarlos Maiolino <cem@kernel.org>
Thu, 20 Nov 2025 12:32:58 +0000 (13:32 +0100)
Use the local variable instead of the extra pointer dereference when
starting the GC thread.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Signed-off-by: Carlos Maiolino <cem@kernel.org>
fs/xfs/xfs_zone_gc.c

index b6a2ecca2e49c1c1b21ef040cd565b7111779a14..3c52cc1497d48c37c9507a6177f1a2d52dd67471 100644 (file)
@@ -1182,16 +1182,16 @@ xfs_zone_gc_mount(
                goto out_put_gc_zone;
        }
 
-       mp->m_zone_info->zi_gc_thread = kthread_create(xfs_zoned_gcd, data,
+       zi->zi_gc_thread = kthread_create(xfs_zoned_gcd, data,
                        "xfs-zone-gc/%s", mp->m_super->s_id);
-       if (IS_ERR(mp->m_zone_info->zi_gc_thread)) {
+       if (IS_ERR(zi->zi_gc_thread)) {
                xfs_warn(mp, "unable to create zone gc thread");
-               error = PTR_ERR(mp->m_zone_info->zi_gc_thread);
+               error = PTR_ERR(zi->zi_gc_thread);
                goto out_free_gc_data;
        }
 
        /* xfs_zone_gc_start will unpark for rw mounts */
-       kthread_park(mp->m_zone_info->zi_gc_thread);
+       kthread_park(zi->zi_gc_thread);
        return 0;
 
 out_free_gc_data: