On Tue, Mar 20, 2018 at 02:48:50PM +0100, Sergio Paracuellos wrote: > This commit replaces custom KS_WLAN_DEBUG which is not being used anymore > in favour of DEBUG which is the one included when debugging is enabled. > > Signed-off-by: Sergio Paracuellos <sergio.paracuellos@xxxxxxxxx> > --- > This patch was in a previous patch series and only this one wasn't applied. > So include here v3 only for this remaining one. > v3: > * Review KS_WLAN_DEBUG in driver sources properly replacing it to DEBUG directive. > > drivers/staging/ks7010/Makefile | 1 - > drivers/staging/ks7010/ks7010_sdio.c | 9 ++++----- > drivers/staging/ks7010/ks_hostif.c | 6 +++--- > drivers/staging/ks7010/ks_wlan.h | 2 +- > 4 files changed, 8 insertions(+), 10 deletions(-) > > diff --git a/drivers/staging/ks7010/Makefile b/drivers/staging/ks7010/Makefile > index 69fcf8d..07dc16c 100644 > --- a/drivers/staging/ks7010/Makefile > +++ b/drivers/staging/ks7010/Makefile > @@ -1,4 +1,3 @@ > obj-$(CONFIG_KS7010) += ks7010.o > > -ccflags-y += -DKS_WLAN_DEBUG=0 > ks7010-y := michael_mic.o ks_hostif.o ks_wlan_net.o ks7010_sdio.o > diff --git a/drivers/staging/ks7010/ks7010_sdio.c b/drivers/staging/ks7010/ks7010_sdio.c > index 50a7a15..b8f55a1 100644 > --- a/drivers/staging/ks7010/ks7010_sdio.c > +++ b/drivers/staging/ks7010/ks7010_sdio.c > @@ -385,11 +385,10 @@ static void ks_wlan_hw_rx(struct ks_wlan_private *priv, uint16_t size) > > /* length check */ > if (size > 2046 || size == 0) { > -#ifdef KS_WLAN_DEBUG > - if (KS_WLAN_DEBUG > 5) > - print_hex_dump_bytes("INVALID DATA dump: ", > - DUMP_PREFIX_OFFSET, > - rx_buffer->data, 32); > +#ifdef DEBUG > + print_hex_dump_bytes("INVALID DATA dump: ", > + DUMP_PREFIX_OFFSET, > + rx_buffer->data, 32); > #endif > ret = ks7010_sdio_writeb(priv, READ_STATUS, REG_STATUS_IDLE); > if (ret) > diff --git a/drivers/staging/ks7010/ks_hostif.c b/drivers/staging/ks7010/ks_hostif.c > index d644a1d..81391df 100644 > --- a/drivers/staging/ks7010/ks_hostif.c > +++ b/drivers/staging/ks7010/ks_hostif.c > @@ -2409,10 +2409,10 @@ void hostif_sme_enqueue(struct ks_wlan_private *priv, unsigned short event) > if (cnt_smeqbody(priv) < (SME_EVENT_BUFF_SIZE - 1)) { > priv->sme_i.event_buff[priv->sme_i.qtail] = event; > inc_smeqtail(priv); > -#ifdef KS_WLAN_DEBUG > +#ifdef DEBUG > if (priv->sme_i.max_event_count < cnt_smeqbody(priv)) > priv->sme_i.max_event_count = cnt_smeqbody(priv); priv->sme_i.max_event_count is a write only variable. Just delete it and the related code. regards, dan carpenter _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel