Commit 1c629485 authored by YueHaibing's avatar YueHaibing Committed by Martin K. Petersen

scsi: smartpqi: remove set but not used variable 'ctrl_info'

Fixes gcc '-Wunused-but-set-variable' warning:

drivers/scsi/smartpqi/smartpqi_init.c: In function 'pqi_driver_version_show':
drivers/scsi/smartpqi/smartpqi_init.c:6164:24: warning:
 variable 'ctrl_info' set but not used [-Wunused-but-set-variable]

commit 6d90615f ("scsi: smartpqi: add sysfs entries") added it but
it was never used. Also remove variable 'shost'.

[mkp: commit desc]

Link: https://lore.kernel.org/r/20190831130348.20552-1-yuehaibing@huawei.comReported-by: default avatarHulk Robot <hulkci@huawei.com>
Signed-off-by: default avatarYueHaibing <yuehaibing@huawei.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent a3a65ddd
...@@ -6157,12 +6157,6 @@ static ssize_t pqi_firmware_version_show(struct device *dev, ...@@ -6157,12 +6157,6 @@ static ssize_t pqi_firmware_version_show(struct device *dev,
static ssize_t pqi_driver_version_show(struct device *dev, static ssize_t pqi_driver_version_show(struct device *dev,
struct device_attribute *attr, char *buffer) struct device_attribute *attr, char *buffer)
{ {
struct Scsi_Host *shost;
struct pqi_ctrl_info *ctrl_info;
shost = class_to_shost(dev);
ctrl_info = shost_to_hba(shost);
return snprintf(buffer, PAGE_SIZE, return snprintf(buffer, PAGE_SIZE,
"%s\n", DRIVER_VERSION BUILD_TIMESTAMP); "%s\n", DRIVER_VERSION BUILD_TIMESTAMP);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment