Whamcloud - gitweb
LU-13494 osp: wait for import invalidation 99/45499/31
authorAlex Zhuravlev <bzzz@whamcloud.com>
Tue, 9 Nov 2021 08:03:32 +0000 (11:03 +0300)
committerOleg Drokin <green@whamcloud.com>
Tue, 21 Mar 2023 23:13:20 +0000 (23:13 +0000)
commit0682d7d6bc64bb75777f05ffb423779bbe781063
treef8ac19e5a61a59d53f3e290d9d2cbd89894744a9
parentd028f1ffec76cc3c7449b1cc2634f2f04609dfaf
LU-13494 osp: wait for import invalidation

osp_update_fini() should wait till racing ptlrpc_import_invalidate()
(running in a dedicated invalidation thread) is complete as the both
threads access ou_update and osp_update_fini() release the structure.

the change also fixes kernel's warning on scheduling while atomic:
old osp_update_fini() took the spinlock to protect ou_list, but
given new wait_event() we don't need to protect the list anymore.

Signed-off-by: Alex Zhuravlev <bzzz@whamcloud.com>
Change-Id: Iea40d3be8b1b3079b9fe8bdd015cc3392027b64d
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/45499
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
Reviewed-by: Lai Siyao <lai.siyao@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
lustre/osp/osp_dev.c