projects/linux·commit 1f4a63bf

xfs: Calling destroy_work_on_stack() to pair with INIT_WORK_ONSTACK()

1f4a63bf · Chuansheng Liu <[email protected]> · 2014-01-07 16:53:34 +08:00

In case CONFIG_DEBUG_OBJECTS_WORK is defined, it is needed to
call destroy_work_on_stack() which frees the debug object to pair
with INIT_WORK_ONSTACK().

Signed-off-by: Liu, Chuansheng <[email protected]>
Reviewed-by: Ben Myers <[email protected]>
Signed-off-by: Ben Myers <[email protected]>

(cherry picked from commit 6f96b3063cdd473c68664a190524ed966ac0cd92)
Commit
1f4a63bf019524c96e79f088cd717b96ef00a249
Parents
bba719b5

Changes

1 files changed · +1 −0

FileStatusAddDelContent
fs/xfs/xfs_bmap_util.cmodified+1−0View file

fs/xfs/xfs_bmap_util.c

View file
diff --git a/fs/xfs/xfs_bmap_util.c b/fs/xfs/xfs_bmap_util.c
index 1394106..82e0dab 100644
--- a/fs/xfs/xfs_bmap_util.c
+++ b/fs/xfs/xfs_bmap_util.c
@@ -287,6 +287,7 @@ xfs_bmapi_allocate(
INIT_WORK_ONSTACK(&args->work, xfs_bmapi_allocate_worker);
queue_work(xfs_alloc_wq, &args->work);
wait_for_completion(&done);
+ destroy_work_on_stack(&args->work);
return args->result;
}