libceph: fix potential hang in ceph_osdc_notify()
stable inclusion from stable-v5.10.190 commit 513bfdde8a3b58cdfac37083c38f7b0100f72ae6 category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I928UI Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=513bfdde8a3b58cdfac37083c38f7b0100f72ae6 -------------------------------- commit e6e28432 upstream. If the cluster becomes unavailable, ceph_osdc_notify() may hang even with osd_request_timeout option set because linger_notify_finish_wait() waits for MWatchNotify NOTIFY_COMPLETE message with no associated OSD request in flight -- it's completely asynchronous. Introduce an additional timeout, derived from the specified notify timeout. While at it, switch both waits to killable which is more correct. Cc: stable@vger.kernel.org Signed-off-by:Ilya Dryomov <idryomov@gmail.com> Reviewed-by:
Dongsheng Yang <dongsheng.yang@easystack.cn> Reviewed-by:
Xiubo Li <xiubli@redhat.com> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by:
sanglipeng <sanglipeng1@jd.com>
Loading
Please sign in to comment