RE: [PATCH v2] storvsc: Set up correct queue depth values for IDE devices
> -Original Message- > From: linux-kernel-ow...@vger.kernel.org> On Behalf > Of Long Li > Sent: Thursday, March 22, 2018 2:47 PM > To: KY Srinivasan ; Haiyang Zhang > ; Stephen > Hemminger ; James E . J . Bottomley > ; > Martin K . Petersen ; > de...@linuxdriverproject.org; linux- > s...@vger.kernel.org; linux-ker...@vger.kernel.org > Cc: Long Li > Subject: [PATCH v2] storvsc: Set up correct queue depth values for IDE devices > > From: Long Li > > Unlike SCSI and FC, we don't use multiple channels for IDE. > Also fix the calculation for sub-channels. > > Change log: > v2: Addressed comment on incorrect number of sub-channels. > (Michael Kelley ) > > Signed-off-by: Long Li Reviewed-by: Michael Kelley > --- > drivers/scsi/storvsc_drv.c | 7 +-- > 1 file changed, 5 insertions(+), 2 deletions(-) > > diff --git a/drivers/scsi/storvsc_drv.c b/drivers/scsi/storvsc_drv.c > index 8c51d628b52e..a2ec0bc9e9fa 100644 > --- a/drivers/scsi/storvsc_drv.c > +++ b/drivers/scsi/storvsc_drv.c > @@ -1722,11 +1722,14 @@ static int storvsc_probe(struct hv_device *device, > max_targets = STORVSC_MAX_TARGETS; > max_channels = STORVSC_MAX_CHANNELS; > /* > - * On Windows8 and above, we support sub-channels for storage. > + * On Windows8 and above, we support sub-channels for storage > + * on SCSI and FC controllers. >* The number of sub-channels offerred is based on the number of >* VCPUs in the guest. >*/ > - max_sub_channels = (num_cpus / storvsc_vcpus_per_sub_channel); > + if (!dev_is_ide) > + max_sub_channels = > + (num_cpus - 1) / storvsc_vcpus_per_sub_channel; > } > > scsi_driver.can_queue = (max_outstanding_req_per_channel * > -- > 2.14.1
[PATCH] scsi: remove reference to scsi_show_extd_sense()
In commit 2104551969e8 ("scsi: use per-cpu buffer for formatting sense"), function scsi_show_extd_sense() was removed, switching use over to scsi_format_extd_sense(). Remove last reference to scsi_show_extd_sense() in include/scsi/scsi_dbg.h. Signed-off-by: John Pittman--- include/scsi/scsi_dbg.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/include/scsi/scsi_dbg.h b/include/scsi/scsi_dbg.h index 04e0679..e03bd9d 100644 --- a/include/scsi/scsi_dbg.h +++ b/include/scsi/scsi_dbg.h @@ -11,8 +11,6 @@ struct scsi_sense_hdr; extern void scsi_print_command(struct scsi_cmnd *); extern size_t __scsi_format_command(char *, size_t, const unsigned char *, size_t); -extern void scsi_show_extd_sense(const struct scsi_device *, const char *, -unsigned char, unsigned char); extern void scsi_print_sense_hdr(const struct scsi_device *, const char *, const struct scsi_sense_hdr *); extern void scsi_print_sense(const struct scsi_cmnd *); -- 2.7.5
Re: [2/4] scsi: hpsa: Less function calls in hpsa_big_passthru_ioctl() after error detection
>> @@ -6501,14 +6501,16 @@ static int hpsa_big_passthru_ioctl(struct ctlr_info >> *h, void __user *argp) >> cleanup0: >> cmd_free(h, c); >> cleanup1: >> - if (buff) { >> + { >> int i; >> >> for (i = 0; i < sg_used; i++) >> kfree(buff[i]); >> kfree(buff); >> } > > Thanks for looking at the hpsa driver. > > This HUNK ends up with an unnamed block. Which identifier would you like to use there? > I would prefer to not have it structured like this. Would you like to show a source code layout alternative? Regards, Markus