From: Tejun Heo Date: Fri, 24 Dec 2010 14:59:06 +0000 (+0100) Subject: ocfs2: don't use flush_scheduled_work() X-Git-Tag: firefly_0821_release~7613^2~3102^2~26 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=9b00a8182987e8b7028d97c2bee3319ef383b57a;p=firefly-linux-kernel-4.4.55.git ocfs2: don't use flush_scheduled_work() flush_scheduled_work() is deprecated and scheduled to be removed. * cancel_delayed_work() + flush_schedule_work() -> cancel_delayed_work_sync(). * flush qs->qs_work directly on exit instead. Signed-off-by: Tejun Heo Acked-by: Joel Becker Cc: Mark Fasheh --- diff --git a/fs/ocfs2/cluster/heartbeat.c b/fs/ocfs2/cluster/heartbeat.c index 52c7557f3e25..892e2de49903 100644 --- a/fs/ocfs2/cluster/heartbeat.c +++ b/fs/ocfs2/cluster/heartbeat.c @@ -307,8 +307,7 @@ static void o2hb_arm_write_timeout(struct o2hb_region *reg) static void o2hb_disarm_write_timeout(struct o2hb_region *reg) { - cancel_delayed_work(®->hr_write_timeout_work); - flush_scheduled_work(); + cancel_delayed_work_sync(®->hr_write_timeout_work); } static inline void o2hb_bio_wait_init(struct o2hb_bio_wait_ctxt *wc) diff --git a/fs/ocfs2/cluster/quorum.c b/fs/ocfs2/cluster/quorum.c index cf3e16696216..a87366750f23 100644 --- a/fs/ocfs2/cluster/quorum.c +++ b/fs/ocfs2/cluster/quorum.c @@ -325,5 +325,7 @@ void o2quo_init(void) void o2quo_exit(void) { - flush_scheduled_work(); + struct o2quo_state *qs = &o2quo_state; + + flush_work_sync(&qs->qs_work); }