Re: [PATCH blktests 0/3] Add SCSI generic test group
On Thu, May 18, 2017 at 03:29:45PM +0200, Johannes Thumshirn wrote: > On 05/18/2017 03:19 PM, Christoph Hellwig wrote: > > All SG_IO test should also apply to block device nodes that support > > the ioctl.. > > > > But these are not necessarily SG_IO tests, are they? > > The test included is doesn't hit the SG_IO path in the sg driver, but > the sg_read path. Oh, you're right. > > Of cause we can make a generic sg_io tool but IMHO it's quite convenient > to just throw in the reproducers we get. > > And as it exercises the /dev/sg character device I decided to make a new > group. Yeah, makes sense. And any SG_IO test should be able to run on both block device nodes and sg nodes.
Re: [PATCH blktests 0/3] Add SCSI generic test group
On 05/19/2017 12:46 AM, Omar Sandoval wrote: > Looking at this some more, it seems like the syzkaller reproducer always > bangs on /dev/sg0. How hard would it be to adapt it to run on the sg > device for every test device instead? Can't be too hard I guess ;-). Maybe I can even clean it up a bit so it compiles with the "-Wall -Wextra -Werror" trinity. I'll send you a v2 once I'm done with it (and all other comments). Byte, Johannes -- Johannes Thumshirn Storage jthumsh...@suse.de+49 911 74053 689 SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg GF: Felix Imendörffer, Jane Smithard, Graham Norton HRB 21284 (AG Nürnberg) Key fingerprint = EC38 9CAB C2C4 F25D 8600 D0D0 0393 969D 2D76 0850
Re: [PATCH blktests 0/3] Add SCSI generic test group
On Thu, May 18, 2017 at 03:29:45PM +0200, Johannes Thumshirn wrote: > On 05/18/2017 03:19 PM, Christoph Hellwig wrote: > > All SG_IO test should also apply to block device nodes that support > > the ioctl.. > > > > But these are not necessarily SG_IO tests, are they? > > The test included is doesn't hit the SG_IO path in the sg driver, but > the sg_read path. > > Of cause we can make a generic sg_io tool but IMHO it's quite convenient > to just throw in the reproducers we get. > > And as it exercises the /dev/sg character device I decided to make a new > group. > > Johannes Looking at this some more, it seems like the syzkaller reproducer always bangs on /dev/sg0. How hard would it be to adapt it to run on the sg device for every test device instead?
Re: [PATCH blktests 0/3] Add SCSI generic test group
On 05/18/2017 03:19 PM, Christoph Hellwig wrote: > All SG_IO test should also apply to block device nodes that support > the ioctl.. > But these are not necessarily SG_IO tests, are they? The test included is doesn't hit the SG_IO path in the sg driver, but the sg_read path. Of cause we can make a generic sg_io tool but IMHO it's quite convenient to just throw in the reproducers we get. And as it exercises the /dev/sg character device I decided to make a new group. Johannes -- Johannes Thumshirn Storage jthumsh...@suse.de+49 911 74053 689 SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg GF: Felix Imendörffer, Jane Smithard, Graham Norton HRB 21284 (AG Nürnberg) Key fingerprint = EC38 9CAB C2C4 F25D 8600 D0D0 0393 969D 2D76 0850
Re: [PATCH blktests 0/3] Add SCSI generic test group
All SG_IO test should also apply to block device nodes that support the ioctl..
[PATCH blktests 0/3] Add SCSI generic test group
Add a test group for the SCSI generic driver and one syzcaller reproducer for this group. The reprodcuer is distributed as a C program, so the makefile is amended to build C files to be used in the test. I didn't get the TIMEOUT to work (not even with block/001) so I decided to just require the 'timeout' program in my testcase. Johannes Thumshirn (3): Add ability to build test-cases tests/sg: add SCSI generic test grouop sg/001: add regression test for syzcaller generated GPF Makefile | 26 +++- common/sg| 22 +++ src/.gitignore | 1 + src/Makefile | 14 ++ src/sg-001.c | 430 +++ tests/sg/001 | 48 +++ tests/sg/001.out | 2 + tests/sg/group | 40 ++ 8 files changed, 582 insertions(+), 1 deletion(-) create mode 100644 common/sg create mode 100644 src/.gitignore create mode 100644 src/Makefile create mode 100644 src/sg-001.c create mode 100755 tests/sg/001 create mode 100644 tests/sg/001.out create mode 100644 tests/sg/group -- 2.12.0