Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1570877
| From | Christoph Hellwig <hch@lst.de> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH 06/10] nbd: remove REQ_TYPE_DRV_PRIV leftovers |
| Date | 2017-01-31 17:30 +0100 |
| Message-ID | <t5JtE-2Tw-29@gated-at.bofh.it> (permalink) |
| References | <t5J0B-2tO-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Disconnects don't use block layer requests these days, so all handling of private requests is dead code. Signed-off-by: Christoph Hellwig <hch@lst.de> --- drivers/block/nbd.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/drivers/block/nbd.c b/drivers/block/nbd.c index 9fd06ee..d4c6281 100644 --- a/drivers/block/nbd.c +++ b/drivers/block/nbd.c @@ -193,13 +193,6 @@ static enum blk_eh_timer_return nbd_xmit_timeout(struct request *req, set_bit(NBD_TIMEDOUT, &nbd->runtime_flags); req->errors++; - /* - * If our disconnect packet times out then we're already holding the - * config_lock and could deadlock here, so just set an error and return, - * we'll handle shutting everything down later. - */ - if (req->cmd_type == REQ_TYPE_DRV_PRIV) - return BLK_EH_HANDLED; mutex_lock(&nbd->config_lock); sock_shutdown(nbd); mutex_unlock(&nbd->config_lock); @@ -510,8 +503,7 @@ static void nbd_handle_cmd(struct nbd_cmd *cmd, int index) goto error_out; } - if (req->cmd_type != REQ_TYPE_FS && - req->cmd_type != REQ_TYPE_DRV_PRIV) + if (req->cmd_type != REQ_TYPE_FS) goto error_out; if (req->cmd_type == REQ_TYPE_FS && -- 2.1.4
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
remove the cmd_type field from struct request Christoph Hellwig <hch@lst.de> - 2017-01-31 17:20 +0100
[PATCH 01/10] scm_blk: remove unneeded REQ_TYPE_FS check Christoph Hellwig <hch@lst.de> - 2017-01-31 17:30 +0100
[PATCH 05/10] mspro_block: remove pointless prep_fn Christoph Hellwig <hch@lst.de> - 2017-01-31 17:30 +0100
[PATCH 07/10] nbd: move request validity checking into nbd_send_cmd Christoph Hellwig <hch@lst.de> - 2017-01-31 17:30 +0100
[PATCH 06/10] nbd: remove REQ_TYPE_DRV_PRIV leftovers Christoph Hellwig <hch@lst.de> - 2017-01-31 17:30 +0100
[PATCH 04/10] ms_block: remove pointless prep_fn Christoph Hellwig <hch@lst.de> - 2017-01-31 17:30 +0100
Re: remove the cmd_type field from struct request Jens Axboe <axboe@kernel.dk> - 2017-01-31 19:10 +0100
Re: remove the cmd_type field from struct request Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> - 2017-01-31 20:00 +0100
Re: remove the cmd_type field from struct request Jens Axboe <axboe@kernel.dk> - 2017-01-31 22:20 +0100
Re: remove the cmd_type field from struct request James Bottomley <James.Bottomley@HansenPartnership.com> - 2017-01-31 20:00 +0100
Re: remove the cmd_type field from struct request Hannes Reinecke <hare@suse.de> - 2017-02-01 08:00 +0100
Re: remove the cmd_type field from struct request Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> - 2017-02-01 12:00 +0100
Re: remove the cmd_type field from struct request Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com> - 2017-02-01 11:40 +0100
Re: remove the cmd_type field from struct request Jens Axboe <axboe@kernel.dk> - 2017-01-31 22:10 +0100
Re: remove the cmd_type field from struct request "Martin K. Petersen" <martin.petersen@oracle.com> - 2017-02-01 04:00 +0100
csiph-web