linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Benjamin Block <bblock@linux.ibm.com>
To: Christoph Hellwig <hch@lst.de>
Cc: axboe@kernel.dk, martin.petersen@oracle.com, ooo@electrozaur.com,
	Johannes Thumshirn <jthumshirn@suse.de>,
	Benjamin Block <bblock@linux.vnet.ibm.com>,
	linux-scsi@vger.kernel.org, linux-block@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 6/8] bsg-lib: handle bidi requests without block layer help
Date: Tue, 13 Nov 2018 15:35:20 +0100	[thread overview]
Message-ID: <20181113143520.GB7222@w530-pk1mzal> (raw)
In-Reply-To: <20181111133211.13926-7-hch@lst.de>

On Sun, Nov 11, 2018 at 02:32:09PM +0100, Christoph Hellwig wrote:
> We can just stash away the second request in struct bsg_job instead
> of using the block layer req->next_rq field, allowing for the eventual
> removal of the latter.
> 
> Signed-off-by: Christoph Hellwig <hch@lst.de>
> ---
>  block/bsg-lib.c                   | 44 +++++++++++++++++++---
>  block/bsg.c                       | 62 ++++++-------------------------
>  drivers/scsi/scsi_transport_sas.c |  1 -
>  include/linux/bsg-lib.h           |  4 ++
>  4 files changed, 54 insertions(+), 57 deletions(-)
> 
> diff --git a/block/bsg-lib.c b/block/bsg-lib.c
> index 192129856342..005e2b75d775 100644
> --- a/block/bsg-lib.c
> +++ b/block/bsg-lib.c
> @@ -74,6 +74,9 @@ static int bsg_scsi_fill_hdr(struct request *rq, struct sg_io_v4 *hdr,
>  {
>  	struct scsi_request *sreq = scsi_req(rq);
> 
> +	if (hdr->dout_xfer_len && hdr->din_xfer_len)
> +		return -EOPNOTSUPP;
> +

This seems like a non-obvious user-breakage. So apart from removing the
in-kernel stuff that uses bidirectional commands you also forbid
userspace from every using them? That seems wrong to me.

There is other SCSI Command Sets than OSD that provide bidirectional
commands, even SBC has some (i.e.  X*WRITE*, COMPARE AND WRITE).



-- 
With Best Regards, Benjamin Block      /      Linux on IBM Z Kernel Development
IBM Systems & Technology Group   /  IBM Deutschland Research & Development GmbH
Vorsitz. AufsR.: Martina Koederitz       /      Geschäftsführung: Dirk Wittkopp
Sitz der Gesellschaft: Böblingen / Registergericht: AmtsG Stuttgart, HRB 243294


  reply	other threads:[~2018-11-13 14:35 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-11 13:32 remove exofs, the T10 OSD code and block/scsi bidi support V3 Christoph Hellwig
2018-11-11 13:32 ` [PATCH 1/8] fs: remove exofs Christoph Hellwig
2018-11-11 13:32 ` [PATCH 2/8] scsi: remove the SCSI OSD library Christoph Hellwig
2018-11-11 13:32 ` [PATCH 3/8] scsi: remove bidirectional command support Christoph Hellwig
2018-11-11 13:32 ` [PATCH 4/8] scsi: stop setting up request->special Christoph Hellwig
2018-11-11 13:32 ` [PATCH 5/8] bsg: refactor bsg_ioctl Christoph Hellwig
2018-11-13 14:05   ` Benjamin Block
2018-11-19 12:29     ` Avri Altman
2018-11-11 13:32 ` [PATCH 6/8] bsg-lib: handle bidi requests without block layer help Christoph Hellwig
2018-11-13 14:35   ` Benjamin Block [this message]
2018-11-14 15:48     ` Christoph Hellwig
2018-11-14 16:44       ` Benjamin Block
2018-11-19 12:31   ` Avri Altman
2018-11-11 13:32 ` [PATCH 7/8] block: remove req->special Christoph Hellwig
2018-11-11 13:32 ` [PATCH 8/8] block: remove bidi support Christoph Hellwig
2018-11-11 16:35 ` remove exofs, the T10 OSD code and block/scsi bidi support V3 Douglas Gilbert
2018-11-26 17:11 ` Boaz Harrosh
2018-12-19 14:43   ` Christoph Hellwig
2018-12-20  2:01     ` Douglas Gilbert
2018-12-20  7:26       ` Christoph Hellwig
2018-12-23 12:57         ` Boaz Harrosh
2018-12-20 16:08       ` Elliott, Robert (Persistent Memory)
2018-12-23 12:17     ` Boaz Harrosh

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181113143520.GB7222@w530-pk1mzal \
    --to=bblock@linux.ibm.com \
    --cc=axboe@kernel.dk \
    --cc=bblock@linux.vnet.ibm.com \
    --cc=hch@lst.de \
    --cc=jthumshirn@suse.de \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    --cc=ooo@electrozaur.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).