]> git.baikalelectronics.ru Git - kernel.git/commit
scsi: Export SCSI Inquiry data to sysfs
authorJohannes Thumshirn <jthumshirn@suse.de>
Mon, 9 Nov 2015 09:56:57 +0000 (10:56 +0100)
committerMartin K. Petersen <martin.petersen@oracle.com>
Mon, 9 Nov 2015 16:46:44 +0000 (11:46 -0500)
commit10b2bc6acaafc8b6a6427fd6ab9e9ae0066e5018
treeaccd2bca20490a3e85bba59714b35ef9e019d4d3
parent0c10f2df4bd003a68752a7813fda4c95ce4c3da6
scsi: Export SCSI Inquiry data to sysfs

Export the RAW SCSI Inquiry to sysfs as binfile. This way the data can be used
by userland without the need to have and ioctl or use the sg_inq tool.

Here is an example of the provided data

linux:~ # hexdump /sys/class/scsi_device/1\:0\:0\:0/device/inquiry
0000000 8005 3205 001f 0000 4551 554d 2020 2020
0000010 4551 554d 4420 4456 522d 4d4f 2020 2020
0000020 2e32 2e33
0000024

Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/scsi_sysfs.c