Commit 762c2a36 authored by Arend van Spriel's avatar Arend van Spriel Committed by Greg Kroah-Hartman

staging: brcm80211: replace DHD_DEBUG macro with BCMDBG

The common Makefile for both brcm80211 drivers defines the macro
BCMDBG upon select Kconfig item BRCMDBG. The fullmac source add
another macro DHD_DEBUG with the same meaning. This is removed
and all conditional code now checks for BCMDBG definition.
Signed-off-by: default avatarArend van Spriel <arend@broadcom.com>
Reviewed-by: default avatarRoland Vossen <rvossen@broadcom.com>
Reviewed-by: default avatarFranky Lin <frankyl@broadcom.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent ca9c786d
......@@ -22,7 +22,7 @@ ccflags-y := \
-DBRCMF_SDALIGN=64 \
-DMAX_HDR_READ=64
ccflags-$(CONFIG_BRCMDBG) += -DDHD_DEBUG -DSHOW_EVENTS
ccflags-$(CONFIG_BRCMDBG) += -DSHOW_EVENTS
ccflags-y += \
-Idrivers/staging/brcm80211/brcmfmac \
......
......@@ -57,7 +57,7 @@ brcmf_sdioh_interrupt_query(struct sdioh_info *si, bool *onoff);
extern int
brcmf_sdioh_interrupt_set(struct sdioh_info *si, bool enable_disable);
#if defined(DHD_DEBUG)
#if defined(BCMDBG)
extern bool brcmf_sdioh_interrupt_pending(struct sdioh_info *si);
#endif
......
......@@ -160,7 +160,7 @@ int brcmf_sdcard_intr_dereg(void *sdh)
return SDIOH_API_SUCCESS(status) ? 0 : -EIO;
}
#if defined(DHD_DEBUG)
#if defined(BCMDBG)
bool brcmf_sdcard_intr_pending(void *sdh)
{
struct brcmf_sdio *bcmsdh = (struct brcmf_sdio *) sdh;
......
......@@ -330,7 +330,7 @@ brcmf_sdioh_interrupt_query(struct sdioh_info *sd, bool *onoff)
return SDIOH_API_RC_SUCCESS;
}
#if defined(DHD_DEBUG)
#if defined(BCMDBG)
extern bool brcmf_sdioh_interrupt_pending(struct sdioh_info *sd)
{
return 0;
......
......@@ -777,10 +777,10 @@ extern atomic_t brcmf_mmc_suspend;
/* Watchdog timer interval */
extern uint brcmf_watchdog_ms;
#if defined(DHD_DEBUG)
#if defined(BCMDBG)
/* Console output poll interval */
extern uint brcmf_console_ms;
#endif /* defined(DHD_DEBUG) */
#endif /* defined(BCMDBG) */
/* Use interrupts */
extern uint brcmf_intr;
......@@ -933,9 +933,9 @@ extern int brcmf_custom_get_mac_address(unsigned char *buf);
extern void brcmf_os_sdunlock_sndup_rxq(dhd_pub_t *pub);
extern void brcmf_os_sdlock_eventq(dhd_pub_t *pub);
extern void brcmf_os_sdunlock_eventq(dhd_pub_t *pub);
#ifdef DHD_DEBUG
#ifdef BCMDBG
extern int brcmf_write_to_file(dhd_pub_t *dhd, u8 *buf, int size);
#endif /* DHD_DEBUG */
#endif /* BCMDBG */
#if defined(OOB_INTR_ONLY)
extern int brcmf_customer_oob_irq_map(unsigned long *irq_flags_ptr);
#endif /* defined(OOB_INTR_ONLY) */
......
......@@ -58,11 +58,11 @@ brcmf_sdbrcm_bus_rxctl(struct dhd_bus *bus, unsigned char *msg, uint msglen);
/* Watchdog timer function */
extern bool brcmf_sdbrcm_bus_watchdog(dhd_pub_t *dhd);
#ifdef DHD_DEBUG
#ifdef BCMDBG
/* Device console input function */
extern int
brcmf_sdbrcm_bus_console_in(dhd_pub_t *dhd, unsigned char *msg, uint msglen);
#endif /* DHD_DEBUG */
#endif /* BCMDBG */
/* Deferred processing for the bus, return true requests reschedule */
extern bool dhd_bus_dpc(struct dhd_bus *bus);
......
......@@ -39,7 +39,7 @@ char brcmf_nv_path[MOD_PARAM_PATHLEN];
#define EPI_VERSION_STR "4.218.248.5"
#define MSGTRACE_VERSION 1
#ifdef DHD_DEBUG
#ifdef BCMDBG
const char brcmf_version[] =
"Dongle Host Driver, version " EPI_VERSION_STR "\nCompiled on " __DATE__
" at " __TIME__;
......@@ -55,7 +55,7 @@ enum {
IOV_BCMERROR,
IOV_WDTICK,
IOV_DUMP,
#ifdef DHD_DEBUG
#ifdef BCMDBG
IOV_CONS,
IOV_DCONSOLE_POLL,
#endif
......@@ -71,10 +71,10 @@ enum {
const struct brcmu_iovar brcmf_iovars[] = {
{"version", IOV_VERSION, 0, IOVT_BUFFER, sizeof(brcmf_version)}
,
#ifdef DHD_DEBUG
#ifdef BCMDBG
{"msglevel", IOV_MSGLEVEL, 0, IOVT_UINT32, 0}
,
#endif /* DHD_DEBUG */
#endif /* BCMDBG */
{"bcmerrorstr", IOV_BCMERRORSTR, 0, IOVT_BUFFER, BCME_STRLEN}
,
{"bcmerror", IOV_BCMERROR, 0, IOVT_INT8, 0}
......@@ -83,7 +83,7 @@ const struct brcmu_iovar brcmf_iovars[] = {
,
{"dump", IOV_DUMP, 0, IOVT_BUFFER, DHD_IOCTL_MAXLEN}
,
#ifdef DHD_DEBUG
#ifdef BCMDBG
{"dconpoll", IOV_DCONSOLE_POLL, 0, IOVT_UINT32, 0}
,
{"cons", IOV_CONS, 0, IOVT_BUFFER, 0}
......@@ -255,7 +255,7 @@ brcmf_c_doiovar(dhd_pub_t *dhd_pub, const struct brcmu_iovar *vi, u32 actionid,
bcmerror = brcmf_c_dump(dhd_pub, arg, len);
break;
#ifdef DHD_DEBUG
#ifdef BCMDBG
case IOV_GVAL(IOV_DCONSOLE_POLL):
int_val = (s32) brcmf_console_ms;
memcpy(arg, &int_val, val_size);
......
......@@ -17,7 +17,7 @@
#ifndef _dhd_dbg_
#define _dhd_dbg_
#if defined(DHD_DEBUG)
#if defined(BCMDBG)
#define DHD_ERROR(args) \
do {if ((brcmf_msg_level & DHD_ERROR_VAL) && (net_ratelimit())) \
......@@ -61,7 +61,7 @@
#define DHD_BTA_ON() (brcmf_msg_level & DHD_BTA_VAL)
#define DHD_ISCAN_ON() (brcmf_msg_level & DHD_ISCAN_VAL)
#else /* (defined BCMDBG) || (defined DHD_DEBUG) */
#else /* (defined BCMDBG) || (defined BCMDBG) */
#define DHD_ERROR(args) do {if (net_ratelimit()) printk args; } while (0)
#define DHD_TRACE(args)
......@@ -90,7 +90,7 @@
#define DHD_EVENT_ON() 0
#define DHD_BTA_ON() 0
#define DHD_ISCAN_ON() 0
#endif /* defined(DHD_DEBUG) */
#endif /* defined(BCMDBG) */
#define DHD_LOG(args)
......
......@@ -262,11 +262,11 @@ module_param(brcmf_sysioc, uint, 0);
uint brcmf_watchdog_ms = 10;
module_param(brcmf_watchdog_ms, uint, 0);
#ifdef DHD_DEBUG
#ifdef BCMDBG
/* Console poll interval */
uint brcmf_console_ms;
module_param(brcmf_console_ms, uint, 0);
#endif /* DHD_DEBUG */
#endif /* BCMDBG */
/* ARP offload agent mode : Enable ARP Host Auto-Reply
and ARP Peer Auto-Reply */
......@@ -357,7 +357,7 @@ module_param(brcmf_pktgen_len, uint, 0);
#endif
/* Version string to report */
#ifdef DHD_DEBUG
#ifdef BCMDBG
#define DHD_COMPILED "\nCompiled in " SRCBASE
#else
#define DHD_COMPILED
......@@ -2632,7 +2632,7 @@ void brcmf_netdev_os_wd_timer(struct net_device *ndev, uint wdtick)
brcmf_os_wd_timer(&dhd->pub, wdtick);
}
#ifdef DHD_DEBUG
#ifdef BCMDBG
int brcmf_write_to_file(dhd_pub_t *dhd, u8 *buf, int size)
{
int ret = 0;
......@@ -2666,7 +2666,7 @@ int brcmf_write_to_file(dhd_pub_t *dhd, u8 *buf, int size)
return ret;
}
#endif /* DHD_DEBUG */
#endif /* BCMDBG */
#if defined(BCMDBG)
void osl_assert(char *exp, char *file, int line)
......
......@@ -87,7 +87,7 @@ extern int brcmf_sdcard_intr_disable(void *sdh);
extern int brcmf_sdcard_intr_reg(void *sdh, bcmsdh_cb_fn_t fn, void *argh);
extern int brcmf_sdcard_intr_dereg(void *sdh);
#if defined(DHD_DEBUG)
#if defined(BCMDBG)
/* Query pending interrupt status from the host controller */
extern bool brcmf_sdcard_intr_pending(void *sdh);
#endif
......
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