nbd: fix -ERESTARTSYS handling
authorJosef Bacik <jbacik@fb.com>
Mon, 2 Oct 2017 20:22:08 +0000 (16:22 -0400)
committerJens Axboe <axboe@kernel.dk>
Mon, 2 Oct 2017 20:29:09 +0000 (14:29 -0600)
commit6e60a3bbb45bd8b307269d6a821ee2c72d815846
tree9bfd658c8774613bd601ea9b5251d2e0eec99d11
parenta5f3d8a5eaaf917878f07998e6f1ea46024e6bab
nbd: fix -ERESTARTSYS handling

Christoph made it so that if we return'ed BLK_STS_RESOURCE whenever we
got ERESTARTSYS from sending our packets we'd return BLK_STS_OK, which
means we'd never requeue and just hang.  We really need to return the
right value from the upper layer.

Fixes: fc17b6534eb8 ("blk-mq: switch ->queue_rq return value to blk_status_t")
Signed-off-by: Josef Bacik <jbacik@fb.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/block/nbd.c