From 014e4c27c68a3ec40b19fef6ae0431e639632531 Mon Sep 17 00:00:00 2001 From: Valentina Manea Date: Tue, 29 Oct 2013 20:58:48 +0200 Subject: [PATCH] staging: rtl8192e: use true and false for bool variables This patch fixes coccinelle errors for bool variables initialized with 1 or 0 instead of true and false. Signed-off-by: Valentina Manea Signed-off-by: Greg Kroah-Hartman --- drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c | 2 +- drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 10 +++++----- drivers/staging/rtl8192e/rtl8192e/rtl_dm.c | 6 +++--- drivers/staging/rtl8192e/rtllib_rx.c | 4 ++-- drivers/staging/rtl8192e/rtllib_softmac.c | 6 +++--- 5 files changed, 14 insertions(+), 14 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c index a816a57030fe..a28584128c91 100644 --- a/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c +++ b/drivers/staging/rtl8192e/rtl8192e/r8192E_dev.c @@ -2213,7 +2213,7 @@ rtl8192_InitializeVariables(struct net_device *dev) priv->MidHighPwrTHR_L2 = 0x40; priv->PwrDomainProtect = false; - priv->bfirst_after_down = 0; + priv->bfirst_after_down = false; } void rtl8192_EnableInterrupt(struct net_device *dev) diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c index bd8c9a2970fc..d93caca9657d 100644 --- a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c +++ b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c @@ -998,7 +998,7 @@ static int rtl8192_sta_down(struct net_device *dev, bool shutdownrf) priv->bDriverIsGoingToUnload = true; priv->up = 0; priv->rtllib->ieee_up = 0; - priv->bfirst_after_down = 1; + priv->bfirst_after_down = true; RT_TRACE(COMP_DOWN, "==========>%s()\n", __func__); if (!netif_queue_stopped(dev)) netif_stop_queue(dev); @@ -1117,8 +1117,8 @@ static void rtl8192_init_priv_variable(struct net_device *dev) priv->rtllib->hwscan_sem_up = 1; priv->rtllib->status = 0; priv->H2CTxCmdSeq = 0; - priv->bDisableFrameBursting = 0; - priv->bDMInitialGainEnable = 1; + priv->bDisableFrameBursting = false; + priv->bDMInitialGainEnable = true; priv->polling_timer_on = 0; priv->up_first_time = 1; priv->blinked_ingpio = false; @@ -1160,7 +1160,7 @@ static void rtl8192_init_priv_variable(struct net_device *dev) priv->CckPwEnl = 6; priv->ScanDelay = 50; priv->ResetProgress = RESET_TYPE_NORESET; - priv->bForcedSilentReset = 0; + priv->bForcedSilentReset = false; priv->bDisableNormalResetCheck = false; priv->force_reset = false; memset(priv->rtllib->swcamtable, 0, sizeof(struct sw_cam_table) * 32); @@ -1169,7 +1169,7 @@ static void rtl8192_init_priv_variable(struct net_device *dev) priv->RxCounter = 0; priv->rtllib->wx_set_enc = 0; priv->bHwRadioOff = false; - priv->RegRfOff = 0; + priv->RegRfOff = false; priv->isRFOff = false; priv->bInPowerSaveMode = false; priv->rtllib->RfOffReason = 0; diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c index bdab150d927e..2297fc20fd4e 100644 --- a/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c +++ b/drivers/staging/rtl8192e/rtl8192e/rtl_dm.c @@ -2265,7 +2265,7 @@ void dm_CheckRfCtrlGPIO(void *data) return; if (priv->bfirst_after_down) { - priv->bfirst_after_down = 1; + priv->bfirst_after_down = true; return; } @@ -2312,9 +2312,9 @@ void dm_rf_pathcheck_workitemcallback(void *data) for (i = 0; i < RF90_PATH_MAX; i++) { if (rfpath & (0x01<brfpath_rxenable[i] = 1; + priv->brfpath_rxenable[i] = true; else - priv->brfpath_rxenable[i] = 0; + priv->brfpath_rxenable[i] = false; } if (!DM_RxPathSelTable.Enable) return; diff --git a/drivers/staging/rtl8192e/rtllib_rx.c b/drivers/staging/rtl8192e/rtllib_rx.c index 6862172af172..1a011b9b9da6 100644 --- a/drivers/staging/rtl8192e/rtllib_rx.c +++ b/drivers/staging/rtl8192e/rtllib_rx.c @@ -873,11 +873,11 @@ static size_t rtllib_rx_get_hdrlen(struct rtllib_device *ieee, if (net_ratelimit()) printk(KERN_INFO "%s: find HTCControl!\n", __func__); hdrlen += 4; - rx_stats->bContainHTC = 1; + rx_stats->bContainHTC = true; } if (RTLLIB_QOS_HAS_SEQ(fc)) - rx_stats->bIsQosData = 1; + rx_stats->bIsQosData = true; return hdrlen; } diff --git a/drivers/staging/rtl8192e/rtllib_softmac.c b/drivers/staging/rtl8192e/rtllib_softmac.c index 671fb5ac5744..933bd6deaca1 100644 --- a/drivers/staging/rtl8192e/rtllib_softmac.c +++ b/drivers/staging/rtl8192e/rtllib_softmac.c @@ -705,7 +705,7 @@ static void rtllib_softmac_stop_scan(struct rtllib_device *ieee) ieee->scan_watch_dog = 0; if (ieee->scanning_continue == 1) { ieee->scanning_continue = 0; - ieee->actscanning = 0; + ieee->actscanning = false; cancel_delayed_work(&ieee->softmac_scan_wq); } @@ -1574,7 +1574,7 @@ static void rtllib_associate_complete_wq(void *data) if (ieee->is_silent_reset) { printk(KERN_INFO "silent reset associate\n"); - ieee->is_silent_reset = 0; + ieee->is_silent_reset = false; } if (ieee->data_hard_resume) @@ -3097,7 +3097,7 @@ void rtllib_softmac_init(struct rtllib_device *ieee) ieee->sta_edca_param[2] = 0x005E4342; ieee->sta_edca_param[3] = 0x002F3262; ieee->aggregation = true; - ieee->enable_rx_imm_BA = 1; + ieee->enable_rx_imm_BA = true; ieee->tx_pending.txb = NULL; _setup_timer(&ieee->associate_timer, -- 2.20.1