Skip to contentSkip to conversation

linux-next: build warning after merge of the scsi tree

DISCUSSION Stephen Rothwell 3 participants 3 messages Apr 5, 2019 Linux-next tree

lore
Share & tools
lore
#0 lore raw

Hi James,

After merging the scsi tree, today's linux-next build (powerpc ppc64_defconfig) produced this warning:

drivers/scsi/lpfc/lpfc_nvme.c:2140:1: warning: 'lpfc_nvme_lport_unreg_wait' defined but not used [-Wunused-function]
lpfc_nvme_lport_unreg_wait(struct lpfc_vport *vport,
^~~~~~~~~~~~~~~~~~~~~~~~~~

Introduced by commit

3999df75bccb ("scsi: lpfc: Declare local functions static")

It use is guarded by IS_ENABLED(CONFIG_NVME_FC).

Signature · 2 lines
Cheers,
Stephen Rothwell
#1 lore raw
Quoted 9 lines · Stephen Rothwell

Hi James,

After merging the scsi tree, today's linux-next build (powerpc ppc64_defconfig) produced this warning:

drivers/scsi/lpfc/lpfc_nvme.c:2140:1: warning: 'lpfc_nvme_lport_unreg_wait' defined but not used [-Wunused-function]
lpfc_nvme_lport_unreg_wait(struct lpfc_vport *vport,
^~~~~~~~~~~~~~~~~~~~~~~~~~

Quoted 5 lines

Introduced by commit

3999df75bccb ("scsi: lpfc: Declare local functions static")

It use is guarded by IS_ENABLED(CONFIG_NVME_FC).

I will have a closer look at this tomorrow.

Bart.

#2 lore raw
Quoted 12 lines · Bart Van Assche
Quoted 11 lines · Stephen Rothwell

Hi James,

After merging the scsi tree, today's linux-next build (powerpc ppc64_defconfig) produced this warning:

drivers/scsi/lpfc/lpfc_nvme.c:2140:1: warning:
'lpfc_nvme_lport_unreg_wait' defined but not used [-Wunused- function]
lpfc_nvme_lport_unreg_wait(struct lpfc_vport *vport, ^~~~~~~~~~~~~~~~~~~~~~~~~~

Quoted 7 lines
Quoted 5 lines

Introduced by commit

3999df75bccb ("scsi: lpfc: Declare local functions static")

It use is guarded by IS_ENABLED(CONFIG_NVME_FC).

I will have a closer look at this tomorrow.

In the meantime, we can just revert the patch. Making functions static serves no real purpose except it does tell the compiler they have to be used internally which is where the problem is coming from. Once the issue is sorted, the static patch can be reapplied.

James