Re: [PATCH V2 11/12] scsi: sd: Introduce scsi_disk_from_queue()

2017-09-12 Thread Damien Le Moal
Ming, On 9/10/17 14:16, Ming Lei wrote: > On Fri, Sep 08, 2017 at 01:16:39AM +0900, Damien Le Moal wrote: >> Using scsi_device_from_queue(), return the scsi_disk structure >> associated with a request queue if the device is a disk. >> Export this function to make it available to modules. >> > >

Re: [PATCH V2 11/12] scsi: sd: Introduce scsi_disk_from_queue()

2017-09-09 Thread Ming Lei
On Fri, Sep 08, 2017 at 01:16:39AM +0900, Damien Le Moal wrote: > Using scsi_device_from_queue(), return the scsi_disk structure > associated with a request queue if the device is a disk. > Export this function to make it available to modules. > This approach may be a little over-kill, actually

[PATCH V2 11/12] scsi: sd: Introduce scsi_disk_from_queue()

2017-09-07 Thread Damien Le Moal
Using scsi_device_from_queue(), return the scsi_disk structure associated with a request queue if the device is a disk. Export this function to make it available to modules. Signed-off-by: Damien Le Moal --- drivers/scsi/sd.c | 32