Commit 934c3e47 authored by Arend van Spriel's avatar Arend van Spriel Committed by Greg Kroah-Hartman

staging: brcm80211: use static qualifier for local symbols in brcmfmac

Cleanup resulted in merging several files and made several symbols
local to a source file. These were found by running sparse as it
gave the warning: symbol 'foo' was not declared. Should it be static?
Reported-by: default avatarAaro Koskinen <aaro.koskinen@iki.fi>
Reviewed-by: default avatarFranky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: default avatarRoland Vossen <rvossen@broadcom.com>
Signed-off-by: default avatarRoland Vossen <rvossen@broadcom.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent debc71cd
...@@ -49,7 +49,7 @@ enum { ...@@ -49,7 +49,7 @@ enum {
IOV_RXCHAIN IOV_RXCHAIN
}; };
const struct brcmu_iovar sdioh_iovars[] = { static const struct brcmu_iovar sdioh_iovars[] = {
{"sd_devreg", IOV_DEVREG, 0, IOVT_BUFFER, sizeof(struct brcmf_sdreg)} {"sd_devreg", IOV_DEVREG, 0, IOVT_BUFFER, sizeof(struct brcmf_sdreg)}
, ,
{"sd_rxchain", IOV_RXCHAIN, 0, IOVT_BOOL, 0} {"sd_rxchain", IOV_RXCHAIN, 0, IOVT_BOOL, 0}
......
...@@ -50,10 +50,10 @@ static const struct sdio_device_id brcmf_sdmmc_ids[] = { ...@@ -50,10 +50,10 @@ static const struct sdio_device_id brcmf_sdmmc_ids[] = {
MODULE_DEVICE_TABLE(sdio, brcmf_sdmmc_ids); MODULE_DEVICE_TABLE(sdio, brcmf_sdmmc_ids);
#ifdef CONFIG_PM_SLEEP #ifdef CONFIG_PM_SLEEP
DECLARE_WAIT_QUEUE_HEAD(sdioh_request_byte_wait); static DECLARE_WAIT_QUEUE_HEAD(sdioh_request_byte_wait);
DECLARE_WAIT_QUEUE_HEAD(sdioh_request_word_wait); static DECLARE_WAIT_QUEUE_HEAD(sdioh_request_word_wait);
DECLARE_WAIT_QUEUE_HEAD(sdioh_request_packet_wait); static DECLARE_WAIT_QUEUE_HEAD(sdioh_request_packet_wait);
DECLARE_WAIT_QUEUE_HEAD(sdioh_request_buffer_wait); static DECLARE_WAIT_QUEUE_HEAD(sdioh_request_buffer_wait);
#endif /* CONFIG_PM_SLEEP */ #endif /* CONFIG_PM_SLEEP */
static bool static bool
...@@ -379,7 +379,7 @@ brcmf_sdioh_request_buffer(struct brcmf_sdio_dev *sdiodev, ...@@ -379,7 +379,7 @@ brcmf_sdioh_request_buffer(struct brcmf_sdio_dev *sdiodev,
} }
/* Read client card reg */ /* Read client card reg */
int static int
brcmf_sdioh_card_regread(struct brcmf_sdio_dev *sdiodev, int func, u32 regaddr, brcmf_sdioh_card_regread(struct brcmf_sdio_dev *sdiodev, int func, u32 regaddr,
int regsize, u32 *data) int regsize, u32 *data)
{ {
......
...@@ -36,11 +36,12 @@ int brcmf_msg_level; ...@@ -36,11 +36,12 @@ int brcmf_msg_level;
#define MSGTRACE_VERSION 1 #define MSGTRACE_VERSION 1
#ifdef BCMDBG #ifdef BCMDBG
const char brcmf_version[] = static const char brcmf_version[] =
"Dongle Host Driver, version " BRCMF_VERSION_STR "\nCompiled on " __DATE__ "Dongle Host Driver, version " BRCMF_VERSION_STR "\nCompiled on "
" at " __TIME__; __DATE__ " at " __TIME__;
#else #else
const char brcmf_version[] = "Dongle Host Driver, version " BRCMF_VERSION_STR; static const char brcmf_version[] =
"Dongle Host Driver, version " BRCMF_VERSION_STR;
#endif #endif
/* IOVar table */ /* IOVar table */
...@@ -58,7 +59,7 @@ enum { ...@@ -58,7 +59,7 @@ enum {
IOV_LAST IOV_LAST
}; };
const struct brcmu_iovar brcmf_iovars[] = { static const struct brcmu_iovar brcmf_iovars[] = {
{"version", IOV_VERSION, 0, IOVT_BUFFER, sizeof(brcmf_version)} {"version", IOV_VERSION, 0, IOVT_BUFFER, sizeof(brcmf_version)}
, ,
#ifdef BCMDBG #ifdef BCMDBG
...@@ -1038,7 +1039,7 @@ void brcmf_c_pktfilter_offload_set(struct brcmf_pub *drvr, char *arg) ...@@ -1038,7 +1039,7 @@ void brcmf_c_pktfilter_offload_set(struct brcmf_pub *drvr, char *arg)
kfree(buf); kfree(buf);
} }
void brcmf_c_arp_offload_set(struct brcmf_pub *drvr, int arp_mode) static void brcmf_c_arp_offload_set(struct brcmf_pub *drvr, int arp_mode)
{ {
char iovbuf[32]; char iovbuf[32];
int retcode; int retcode;
...@@ -1055,7 +1056,7 @@ void brcmf_c_arp_offload_set(struct brcmf_pub *drvr, int arp_mode) ...@@ -1055,7 +1056,7 @@ void brcmf_c_arp_offload_set(struct brcmf_pub *drvr, int arp_mode)
arp_mode); arp_mode);
} }
void brcmf_c_arp_offload_enable(struct brcmf_pub *drvr, int arp_enable) static void brcmf_c_arp_offload_enable(struct brcmf_pub *drvr, int arp_enable)
{ {
char iovbuf[32]; char iovbuf[32];
int retcode; int retcode;
......
...@@ -831,7 +831,7 @@ static void brcmf_ethtool_get_drvinfo(struct net_device *net, ...@@ -831,7 +831,7 @@ static void brcmf_ethtool_get_drvinfo(struct net_device *net,
dev_name(&brcmf_cfg80211_get_sdio_func()->dev)); dev_name(&brcmf_cfg80211_get_sdio_func()->dev));
} }
struct ethtool_ops brcmf_ethtool_ops = { static struct ethtool_ops brcmf_ethtool_ops = {
.get_drvinfo = brcmf_ethtool_get_drvinfo .get_drvinfo = brcmf_ethtool_get_drvinfo
}; };
...@@ -1494,15 +1494,6 @@ int brcmf_os_proto_unblock(struct brcmf_pub *drvr) ...@@ -1494,15 +1494,6 @@ int brcmf_os_proto_unblock(struct brcmf_pub *drvr)
return 0; return 0;
} }
int brcmf_netdev_reset(struct net_device *dev, u8 flag)
{
struct brcmf_info *drvr_priv = *(struct brcmf_info **)netdev_priv(dev);
brcmf_bus_devreset(&drvr_priv->pub, flag);
return 1;
}
static int brcmf_get_pend_8021x_cnt(struct brcmf_info *drvr_priv) static int brcmf_get_pend_8021x_cnt(struct brcmf_info *drvr_priv)
{ {
return atomic_read(&drvr_priv->pend_8021x_cnt); return atomic_read(&drvr_priv->pend_8021x_cnt);
......
...@@ -769,7 +769,7 @@ uint brcmf_txbound; ...@@ -769,7 +769,7 @@ uint brcmf_txbound;
uint brcmf_rxbound; uint brcmf_rxbound;
module_param(brcmf_txbound, uint, 0); module_param(brcmf_txbound, uint, 0);
module_param(brcmf_rxbound, uint, 0); module_param(brcmf_rxbound, uint, 0);
uint brcmf_txminmax; static uint brcmf_txminmax;
int brcmf_idletime = 1; int brcmf_idletime = 1;
module_param(brcmf_idletime, int, 0); module_param(brcmf_idletime, int, 0);
...@@ -1151,7 +1151,7 @@ static int brcmf_sdbrcm_clkctl(struct brcmf_bus *bus, uint target, bool pendok) ...@@ -1151,7 +1151,7 @@ static int brcmf_sdbrcm_clkctl(struct brcmf_bus *bus, uint target, bool pendok)
return 0; return 0;
} }
int brcmf_sdbrcm_bussleep(struct brcmf_bus *bus, bool sleep) static int brcmf_sdbrcm_bussleep(struct brcmf_bus *bus, bool sleep)
{ {
uint retries = 0; uint retries = 0;
...@@ -1765,7 +1765,7 @@ enum { ...@@ -1765,7 +1765,7 @@ enum {
IOV_VARS IOV_VARS
}; };
const struct brcmu_iovar brcmf_sdio_iovars[] = { static const struct brcmu_iovar brcmf_sdio_iovars[] = {
{"intr", IOV_INTR, 0, IOVT_BOOL, 0}, {"intr", IOV_INTR, 0, IOVT_BOOL, 0},
{"sleep", IOV_SLEEP, 0, IOVT_BOOL, 0}, {"sleep", IOV_SLEEP, 0, IOVT_BOOL, 0},
{"pollrate", IOV_POLLRATE, 0, IOVT_UINT32, 0}, {"pollrate", IOV_POLLRATE, 0, IOVT_UINT32, 0},
...@@ -2287,7 +2287,7 @@ static int brcmf_sdbrcm_readconsole(struct brcmf_bus *bus) ...@@ -2287,7 +2287,7 @@ static int brcmf_sdbrcm_readconsole(struct brcmf_bus *bus)
} }
#endif /* BCMDBG */ #endif /* BCMDBG */
int brcmf_sdbrcm_downloadvars(struct brcmf_bus *bus, void *arg, int len) static int brcmf_sdbrcm_downloadvars(struct brcmf_bus *bus, void *arg, int len)
{ {
int bcmerror = 0; int bcmerror = 0;
...@@ -4497,7 +4497,7 @@ void brcmf_sdbrcm_isr(void *arg) ...@@ -4497,7 +4497,7 @@ void brcmf_sdbrcm_isr(void *arg)
brcmf_sdbrcm_sched_dpc(bus); brcmf_sdbrcm_sched_dpc(bus);
} }
extern bool brcmf_sdbrcm_bus_watchdog(struct brcmf_pub *drvr) static bool brcmf_sdbrcm_bus_watchdog(struct brcmf_pub *drvr)
{ {
struct brcmf_bus *bus; struct brcmf_bus *bus;
......
...@@ -38,7 +38,7 @@ static struct sdio_func *cfg80211_sdio_func; ...@@ -38,7 +38,7 @@ static struct sdio_func *cfg80211_sdio_func;
static struct brcmf_cfg80211_dev *cfg80211_dev; static struct brcmf_cfg80211_dev *cfg80211_dev;
static const u8 ether_bcast[ETH_ALEN] = {255, 255, 255, 255, 255, 255}; static const u8 ether_bcast[ETH_ALEN] = {255, 255, 255, 255, 255, 255};
u32 brcmf_dbg_level = WL_DBG_ERR; static u32 brcmf_dbg_level = WL_DBG_ERR;
/* /*
** cfg80211_ops api/callback list ** cfg80211_ops api/callback list
...@@ -3830,7 +3830,8 @@ brcmf_dongle_scantime(struct net_device *ndev, s32 scan_assoc_time, ...@@ -3830,7 +3830,8 @@ brcmf_dongle_scantime(struct net_device *ndev, s32 scan_assoc_time,
return err; return err;
} }
s32 brcmf_config_dongle(struct brcmf_cfg80211_priv *cfg_priv, bool need_lock) static s32 brcmf_config_dongle(struct brcmf_cfg80211_priv *cfg_priv,
bool need_lock)
{ {
struct net_device *ndev; struct net_device *ndev;
struct wireless_dev *wdev; struct wireless_dev *wdev;
......
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