open-iscsi / tcmu-runner

A daemon that handles the userspace side of the LIO TCM-User backstore.
Apache License 2.0
190 stars 148 forks source link

tcmur_device: fix racy between reopening devices and reporting events #695

Closed lxbsz closed 1 year ago

lxbsz commented 1 year ago

To make sure all the in-flight IOs have been finished before flushing the event_work. Or just after we flush the event_work a new timedout IO callback could come and then it will fire a new event work, which may access the device while we are closing the device later.

Signed-off-by: Xiubo Li xiubli@redhat.com