diff options
| -rw-r--r-- | drivers/block/nbd.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/block/nbd.c b/drivers/block/nbd.c index 54bf633c9013..39e5f7fae3ef 100644 --- a/drivers/block/nbd.c +++ b/drivers/block/nbd.c | |||
| @@ -285,7 +285,7 @@ static struct request *nbd_find_request(struct nbd_device *nbd, | |||
| 285 | 285 | ||
| 286 | err = wait_event_interruptible(nbd->active_wq, nbd->active_req != xreq); | 286 | err = wait_event_interruptible(nbd->active_wq, nbd->active_req != xreq); |
| 287 | if (unlikely(err)) | 287 | if (unlikely(err)) |
| 288 | goto out; | 288 | return ERR_PTR(err); |
| 289 | 289 | ||
| 290 | spin_lock(&nbd->queue_lock); | 290 | spin_lock(&nbd->queue_lock); |
| 291 | list_for_each_entry_safe(req, tmp, &nbd->queue_head, queuelist) { | 291 | list_for_each_entry_safe(req, tmp, &nbd->queue_head, queuelist) { |
| @@ -297,10 +297,7 @@ static struct request *nbd_find_request(struct nbd_device *nbd, | |||
| 297 | } | 297 | } |
| 298 | spin_unlock(&nbd->queue_lock); | 298 | spin_unlock(&nbd->queue_lock); |
| 299 | 299 | ||
| 300 | err = -ENOENT; | 300 | return ERR_PTR(-ENOENT); |
| 301 | |||
| 302 | out: | ||
| 303 | return ERR_PTR(err); | ||
| 304 | } | 301 | } |
| 305 | 302 | ||
| 306 | static inline int sock_recv_bvec(struct nbd_device *nbd, struct bio_vec *bvec) | 303 | static inline int sock_recv_bvec(struct nbd_device *nbd, struct bio_vec *bvec) |
