Re: [PATCH 3/4] sg: check for valid direction before starting the request

2017-02-03 Thread Hannes Reinecke
On 02/03/2017 11:28 AM, Christoph Hellwig wrote: > On Fri, Feb 03, 2017 at 09:54:50AM +0100, Hannes Reinecke wrote: >> From: Johannes Thumshirn >> >> Check for a valid direction before starting the request, otherwise we risk >> running into an assertion in the scsi midlayer checking for vaild requ

Re: [PATCH 3/4] sg: check for valid direction before starting the request

2017-02-03 Thread Hannes Reinecke
On 02/03/2017 11:28 AM, Christoph Hellwig wrote: > On Fri, Feb 03, 2017 at 09:54:50AM +0100, Hannes Reinecke wrote: >> From: Johannes Thumshirn >> >> Check for a valid direction before starting the request, otherwise we risk >> running into an assertion in the scsi midlayer checking for vaild requ

Re: [PATCH 3/4] sg: check for valid direction before starting the request

2017-02-03 Thread Christoph Hellwig
On Fri, Feb 03, 2017 at 09:54:50AM +0100, Hannes Reinecke wrote: > From: Johannes Thumshirn > > Check for a valid direction before starting the request, otherwise we risk > running into an assertion in the scsi midlayer checking for vaild requests. Good idea, but.. > +static bool sg_is_valid_di

[PATCH 3/4] sg: check for valid direction before starting the request

2017-02-03 Thread Hannes Reinecke
From: Johannes Thumshirn Check for a valid direction before starting the request, otherwise we risk running into an assertion in the scsi midlayer checking for vaild requests. Signed-off-by: Johannes Thumshirn Link: http://www.spinics.net/lists/linux-scsi/msg104400.html Reported-by: Dmitry Vyuk