* [PATCH 1/3] scsi: fnic: make some symbols static
@ 2020-04-15 9:38 Jason Yan
2020-04-15 9:38 ` [PATCH 2/3] scsi: fnic: make fnic_list and fnic_list_lock static Jason Yan
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Jason Yan @ 2020-04-15 9:38 UTC (permalink / raw)
To: satishkh, sebaddel, kartilak, jejb, martin.petersen, linux-scsi,
linux-kernel
Cc: Jason Yan, Hulk Robot
Fix the following sparse warning:
drivers/scsi/fnic/vnic_dev.c:257:5: warning: symbol 'vnic_dev_cmd1' was
not declared. Should it be static?
drivers/scsi/fnic/vnic_dev.c:319:5: warning: symbol 'vnic_dev_cmd2' was
not declared. Should it be static?
drivers/scsi/fnic/vnic_dev.c:414:5: warning: symbol
'vnic_dev_init_devcmd1' was not declared. Should it be static?
drivers/scsi/fnic/vnic_dev.c:425:5: warning: symbol
'vnic_dev_init_devcmd2' was not declared. Should it be static?
drivers/scsi/fnic/vnic_dev.c:495:6: warning: symbol
'vnic_dev_deinit_devcmd2' was not declared. Should it be static?
drivers/scsi/fnic/vnic_dev.c:506:5: warning: symbol
'vnic_dev_cmd_no_proxy' was not declared. Should it be static?
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Jason Yan <yanaijie@huawei.com>
---
drivers/scsi/fnic/vnic_dev.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/scsi/fnic/vnic_dev.c b/drivers/scsi/fnic/vnic_dev.c
index 1b88a3b53eee..a2beee6e09f0 100644
--- a/drivers/scsi/fnic/vnic_dev.c
+++ b/drivers/scsi/fnic/vnic_dev.c
@@ -254,7 +254,7 @@ void vnic_dev_free_desc_ring(struct vnic_dev *vdev, struct vnic_dev_ring *ring)
}
}
-int vnic_dev_cmd1(struct vnic_dev *vdev, enum vnic_devcmd_cmd cmd, int wait)
+static int vnic_dev_cmd1(struct vnic_dev *vdev, enum vnic_devcmd_cmd cmd, int wait)
{
struct vnic_devcmd __iomem *devcmd = vdev->devcmd;
int delay;
@@ -316,7 +316,7 @@ int vnic_dev_cmd1(struct vnic_dev *vdev, enum vnic_devcmd_cmd cmd, int wait)
return -ETIMEDOUT;
}
-int vnic_dev_cmd2(struct vnic_dev *vdev, enum vnic_devcmd_cmd cmd,
+static int vnic_dev_cmd2(struct vnic_dev *vdev, enum vnic_devcmd_cmd cmd,
int wait)
{
struct devcmd2_controller *dc2c = vdev->devcmd2;
@@ -411,7 +411,7 @@ int vnic_dev_cmd2(struct vnic_dev *vdev, enum vnic_devcmd_cmd cmd,
}
-int vnic_dev_init_devcmd1(struct vnic_dev *vdev)
+static int vnic_dev_init_devcmd1(struct vnic_dev *vdev)
{
vdev->devcmd = vnic_dev_get_res(vdev, RES_TYPE_DEVCMD, 0);
if (!vdev->devcmd)
@@ -422,7 +422,7 @@ int vnic_dev_init_devcmd1(struct vnic_dev *vdev)
}
-int vnic_dev_init_devcmd2(struct vnic_dev *vdev)
+static int vnic_dev_init_devcmd2(struct vnic_dev *vdev)
{
int err;
unsigned int fetch_index;
@@ -492,7 +492,7 @@ int vnic_dev_init_devcmd2(struct vnic_dev *vdev)
}
-void vnic_dev_deinit_devcmd2(struct vnic_dev *vdev)
+static void vnic_dev_deinit_devcmd2(struct vnic_dev *vdev)
{
vnic_dev_free_desc_ring(vdev, &vdev->devcmd2->results_ring);
vnic_wq_disable(&vdev->devcmd2->wq);
@@ -503,7 +503,7 @@ void vnic_dev_deinit_devcmd2(struct vnic_dev *vdev)
}
-int vnic_dev_cmd_no_proxy(struct vnic_dev *vdev,
+static int vnic_dev_cmd_no_proxy(struct vnic_dev *vdev,
enum vnic_devcmd_cmd cmd, u64 *a0, u64 *a1, int wait)
{
int err;
--
2.21.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/3] scsi: fnic: make fnic_list and fnic_list_lock static
2020-04-15 9:38 [PATCH 1/3] scsi: fnic: make some symbols static Jason Yan
@ 2020-04-15 9:38 ` Jason Yan
2020-04-15 9:38 ` [PATCH 3/3] scsi: fnic: make vnic_wq_get_ctrl and vnic_wq_alloc_ring static Jason Yan
2020-04-17 21:32 ` [PATCH 1/3] scsi: fnic: make some symbols static Martin K. Petersen
2 siblings, 0 replies; 4+ messages in thread
From: Jason Yan @ 2020-04-15 9:38 UTC (permalink / raw)
To: satishkh, sebaddel, kartilak, jejb, martin.petersen, linux-scsi,
linux-kernel
Cc: Jason Yan, Hulk Robot
Fix the following sparse warning:
drivers/scsi/fnic/fnic_main.c:52:1: warning: symbol 'fnic_list' was not
declared. Should it be static?
drivers/scsi/fnic/fnic_main.c:53:1: warning: symbol 'fnic_list_lock' was
not declared. Should it be static?
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Jason Yan <yanaijie@huawei.com>
---
drivers/scsi/fnic/fnic_main.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/scsi/fnic/fnic_main.c b/drivers/scsi/fnic/fnic_main.c
index 18584ab27c32..7910b573bacb 100644
--- a/drivers/scsi/fnic/fnic_main.c
+++ b/drivers/scsi/fnic/fnic_main.c
@@ -49,8 +49,8 @@
static struct kmem_cache *fnic_sgl_cache[FNIC_SGL_NUM_CACHES];
static struct kmem_cache *fnic_io_req_cache;
-LIST_HEAD(fnic_list);
-DEFINE_SPINLOCK(fnic_list_lock);
+static LIST_HEAD(fnic_list);
+static DEFINE_SPINLOCK(fnic_list_lock);
/* Supported devices by fnic module */
static struct pci_device_id fnic_id_table[] = {
--
2.21.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 3/3] scsi: fnic: make vnic_wq_get_ctrl and vnic_wq_alloc_ring static
2020-04-15 9:38 [PATCH 1/3] scsi: fnic: make some symbols static Jason Yan
2020-04-15 9:38 ` [PATCH 2/3] scsi: fnic: make fnic_list and fnic_list_lock static Jason Yan
@ 2020-04-15 9:38 ` Jason Yan
2020-04-17 21:32 ` [PATCH 1/3] scsi: fnic: make some symbols static Martin K. Petersen
2 siblings, 0 replies; 4+ messages in thread
From: Jason Yan @ 2020-04-15 9:38 UTC (permalink / raw)
To: satishkh, sebaddel, kartilak, jejb, martin.petersen, linux-scsi,
linux-kernel
Cc: Jason Yan, Hulk Robot
Fix the following sparse warning:
drivers/scsi/fnic/vnic_wq.c:28:5: warning: symbol 'vnic_wq_get_ctrl' was
not declared. Should it be static?
drivers/scsi/fnic/vnic_wq.c:40:5: warning: symbol 'vnic_wq_alloc_ring'
was not declared. Should it be static?
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Jason Yan <yanaijie@huawei.com>
---
drivers/scsi/fnic/vnic_wq.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/scsi/fnic/vnic_wq.c b/drivers/scsi/fnic/vnic_wq.c
index 015af2cdabaf..442972c04e65 100644
--- a/drivers/scsi/fnic/vnic_wq.c
+++ b/drivers/scsi/fnic/vnic_wq.c
@@ -25,7 +25,7 @@
#include "vnic_wq.h"
-int vnic_wq_get_ctrl(struct vnic_dev *vdev, struct vnic_wq *wq,
+static int vnic_wq_get_ctrl(struct vnic_dev *vdev, struct vnic_wq *wq,
unsigned int index, enum vnic_res_type res_type)
{
wq->ctrl = vnic_dev_get_res(vdev, res_type, index);
@@ -37,7 +37,7 @@ int vnic_wq_get_ctrl(struct vnic_dev *vdev, struct vnic_wq *wq,
}
-int vnic_wq_alloc_ring(struct vnic_dev *vdev, struct vnic_wq *wq,
+static int vnic_wq_alloc_ring(struct vnic_dev *vdev, struct vnic_wq *wq,
unsigned int desc_count, unsigned int desc_size)
{
return vnic_dev_alloc_desc_ring(vdev, &wq->ring, desc_count, desc_size);
--
2.21.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/3] scsi: fnic: make some symbols static
2020-04-15 9:38 [PATCH 1/3] scsi: fnic: make some symbols static Jason Yan
2020-04-15 9:38 ` [PATCH 2/3] scsi: fnic: make fnic_list and fnic_list_lock static Jason Yan
2020-04-15 9:38 ` [PATCH 3/3] scsi: fnic: make vnic_wq_get_ctrl and vnic_wq_alloc_ring static Jason Yan
@ 2020-04-17 21:32 ` Martin K. Petersen
2 siblings, 0 replies; 4+ messages in thread
From: Martin K. Petersen @ 2020-04-17 21:32 UTC (permalink / raw)
To: Jason Yan
Cc: satishkh, sebaddel, kartilak, jejb, martin.petersen, linux-scsi,
linux-kernel, Hulk Robot
Jason,
> Fix the following sparse warning:
Applied patches 1-3 to 5.8/scsi-queue, thanks!
--
Martin K. Petersen Oracle Linux Engineering
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-04-17 21:33 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-15 9:38 [PATCH 1/3] scsi: fnic: make some symbols static Jason Yan
2020-04-15 9:38 ` [PATCH 2/3] scsi: fnic: make fnic_list and fnic_list_lock static Jason Yan
2020-04-15 9:38 ` [PATCH 3/3] scsi: fnic: make vnic_wq_get_ctrl and vnic_wq_alloc_ring static Jason Yan
2020-04-17 21:32 ` [PATCH 1/3] scsi: fnic: make some symbols static Martin K. Petersen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).