Message ID | 1515669238-125768-1-git-send-email-weiyongjun1@huawei.com (mailing list archive) |
---|---|
State | Accepted |
Headers | show |
On 11/01/2018 11:13, Wei Yongjun wrote: > Fixes the following sparse warning: > > drivers/scsi/hisi_sas/hisi_sas_main.c:1691:25: warning: > symbol 'host_attrs' was not declared. Should it be static? > > Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com> Acked-by: John Garry <john.garry@huawei.com> > --- > drivers/scsi/hisi_sas/hisi_sas_main.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/scsi/hisi_sas/hisi_sas_main.c b/drivers/scsi/hisi_sas/hisi_sas_main.c > index 360ecef..e3e7285 100644 > --- a/drivers/scsi/hisi_sas/hisi_sas_main.c > +++ b/drivers/scsi/hisi_sas/hisi_sas_main.c > @@ -1688,7 +1688,7 @@ void hisi_sas_kill_tasklets(struct hisi_hba *hisi_hba) > struct scsi_transport_template *hisi_sas_stt; > EXPORT_SYMBOL_GPL(hisi_sas_stt); > > -struct device_attribute *host_attrs[] = { > +static struct device_attribute *host_attrs[] = { > &dev_attr_phy_event_threshold, > NULL, > }; > > > . >
Wei, > Fixes the following sparse warning: > > drivers/scsi/hisi_sas/hisi_sas_main.c:1691:25: warning: > symbol 'host_attrs' was not declared. Should it be static? Applied to 4.16/scsi-queue. Thank you!
diff --git a/drivers/scsi/hisi_sas/hisi_sas_main.c b/drivers/scsi/hisi_sas/hisi_sas_main.c index 360ecef..e3e7285 100644 --- a/drivers/scsi/hisi_sas/hisi_sas_main.c +++ b/drivers/scsi/hisi_sas/hisi_sas_main.c @@ -1688,7 +1688,7 @@ void hisi_sas_kill_tasklets(struct hisi_hba *hisi_hba) struct scsi_transport_template *hisi_sas_stt; EXPORT_SYMBOL_GPL(hisi_sas_stt); -struct device_attribute *host_attrs[] = { +static struct device_attribute *host_attrs[] = { &dev_attr_phy_event_threshold, NULL, };
Fixes the following sparse warning: drivers/scsi/hisi_sas/hisi_sas_main.c:1691:25: warning: symbol 'host_attrs' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com> --- drivers/scsi/hisi_sas/hisi_sas_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)