Skip to content

Commit 6f86f14

Browse files
Christoph Hellwigbrauner
authored andcommitted
erofs: use lockref_init for pcl->lockref
Signed-off-by: Christoph Hellwig <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Gao Xiang <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
1 parent 8c32b87 commit 6f86f14

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

fs/erofs/zdata.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -747,8 +747,7 @@ static int z_erofs_register_pcluster(struct z_erofs_decompress_frontend *fe)
747747
if (IS_ERR(pcl))
748748
return PTR_ERR(pcl);
749749

750-
spin_lock_init(&pcl->lockref.lock);
751-
pcl->lockref.count = 1; /* one ref for this request */
750+
lockref_init(&pcl->lockref, 1); /* one ref for this request */
752751
pcl->algorithmformat = map->m_algorithmformat;
753752
pcl->length = 0;
754753
pcl->partial = true;

0 commit comments

Comments
 (0)