Skip to contentSkip to conversation

NFC: hci/core.c: local variables should not be exposed globally

PATCH New H Hartley Sweeten 1 participant 1 message Apr 26, 2012

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 NFC: hci/core.c: local variables should not be exposed globally

The variable 'hci_nfc_ops' is only referenced in this file and should be marked static to prevent it from being exposed globally.

Quites the sparse warning:

warning: symbol 'hci_nfc_ops' was not declared. Should it be static?

Cc Lauro Ramos Venancio <[email protected]>
Cc Aloisio Almeida Jr <[email protected]>
Cc Samuel Ortiz <[email protected]>
Cc "David S. Miller" <[email protected]>

---

net/nfc/hci/core.c +1 -1
index 86fd00d..0ce5ee4 100644
@@ -605,7 +605,7 @@ static int hci_data_exchange(struct nfc_dev *nfc_dev, u32 target_idx,
 	return 0;
 }
 
-struct nfc_ops hci_nfc_ops = {
+static struct nfc_ops hci_nfc_ops = {
 	.dev_up = hci_dev_up,
 	.dev_down = hci_dev_down,
 	.start_poll = hci_start_poll,