diff options
author | Kevin Vigor <kvigor@fb.com> | 2018-05-30 18:45:11 +0200 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2018-05-30 19:30:42 +0200 |
commit | 5e3c3a7ecefefaebc7c9a626fe4522cb85bbdaad (patch) | |
tree | 03f7f01f6c8164298296f87344a71dd754fab70b /drivers/nvme/host/fc.c | |
parent | blk-throttle: fix potential NULL pointer dereference in throtl_select_dispatch (diff) | |
download | linux-5e3c3a7ecefefaebc7c9a626fe4522cb85bbdaad.tar.xz linux-5e3c3a7ecefefaebc7c9a626fe4522cb85bbdaad.zip |
nbd: clear DISCONNECT_REQUESTED flag once disconnection occurs.
When a userspace client requests a NBD device be disconnected, the
DISCONNECT_REQUESTED flag is set. While this flag is set, the driver
will not inform userspace when a connection is closed.
Unfortunately the flag was never cleared, so once a disconnect was
requested the driver would thereafter never tell userspace about a
closed connection. Thus when connections failed due to timeout, no
attempt to reconnect was made and eventually the device would fail.
Fix by clearing the DISCONNECT_REQUESTED flag (and setting the
DISCONNECTED flag) once all connections are closed.
Reviewed-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: Kevin Vigor <kvigor@fb.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions