Commit f237216e authored by Tina Ruchandani's avatar Tina Ruchandani Committed by Greg Kroah-Hartman

Staging: rtl8723au: core: Dont have { on new line

This patch fixes the following checkpatch errors:
ERROR: that open brace { should be on the previous line
ERROR: else should follow close brace '}'

Exceptions: { is left on a new line to itself when fixing
this error makes the line longer than 80 characters.
Signed-off-by: default avatarTina Ruchandani <ruchandani.tina@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent eca6a887
This diff is collapsed.
...@@ -1020,8 +1020,7 @@ static void lps_ctrl_wk_hdl(struct rtw_adapter *padapter, u8 lps_ctrl_type) ...@@ -1020,8 +1020,7 @@ static void lps_ctrl_wk_hdl(struct rtw_adapter *padapter, u8 lps_ctrl_type)
check_fwstate(pmlmepriv, WIFI_ADHOC_STATE)) check_fwstate(pmlmepriv, WIFI_ADHOC_STATE))
return; return;
switch (lps_ctrl_type) switch (lps_ctrl_type) {
{
case LPS_CTRL_SCAN: case LPS_CTRL_SCAN:
rtl8723a_BT_wifiscan_notify(padapter, true); rtl8723a_BT_wifiscan_notify(padapter, true);
if (!rtl8723a_BT_using_antenna_1(padapter)) { if (!rtl8723a_BT_using_antenna_1(padapter)) {
...@@ -1308,8 +1307,7 @@ int rtw_drvextra_cmd_hdl23a(struct rtw_adapter *padapter, const u8 *pbuf) ...@@ -1308,8 +1307,7 @@ int rtw_drvextra_cmd_hdl23a(struct rtw_adapter *padapter, const u8 *pbuf)
pdrvextra_cmd = (struct drvextra_cmd_parm *)pbuf; pdrvextra_cmd = (struct drvextra_cmd_parm *)pbuf;
switch (pdrvextra_cmd->ec_id) switch (pdrvextra_cmd->ec_id) {
{
case DYNAMIC_CHK_WK_CID: case DYNAMIC_CHK_WK_CID:
dynamic_chk_wk_hdl(padapter, pdrvextra_cmd->pbuf, dynamic_chk_wk_hdl(padapter, pdrvextra_cmd->pbuf,
pdrvextra_cmd->type_size); pdrvextra_cmd->type_size);
......
...@@ -302,8 +302,7 @@ void rtw_set_supported_rate23a(u8 *SupportedRates, uint mode) ...@@ -302,8 +302,7 @@ void rtw_set_supported_rate23a(u8 *SupportedRates, uint mode)
memset(SupportedRates, 0, NDIS_802_11_LENGTH_RATES_EX); memset(SupportedRates, 0, NDIS_802_11_LENGTH_RATES_EX);
switch (mode) switch (mode) {
{
case WIRELESS_11B: case WIRELESS_11B:
memcpy(SupportedRates, WIFI_CCKRATES, IEEE80211_CCK_RATE_LEN); memcpy(SupportedRates, WIFI_CCKRATES, IEEE80211_CCK_RATE_LEN);
break; break;
......
...@@ -424,29 +424,23 @@ static void SwLedBlink3(struct led_8723a *pLed) ...@@ -424,29 +424,23 @@ static void SwLedBlink3(struct led_8723a *pLed)
u8 bStopBlinking = false; u8 bStopBlinking = false;
/* Change LED according to BlinkingLedState specified. */ /* Change LED according to BlinkingLedState specified. */
if (pLed->BlinkingLedState == RTW_LED_ON) if (pLed->BlinkingLedState == RTW_LED_ON) {
{
SwLedOn23a(padapter, pLed); SwLedOn23a(padapter, pLed);
RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("Blinktimes (%d): turn on\n", pLed->BlinkTimes)); RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("Blinktimes (%d): turn on\n", pLed->BlinkTimes));
} } else {
else
{
if (pLed->CurrLedState != LED_BLINK_WPS_STOP) if (pLed->CurrLedState != LED_BLINK_WPS_STOP)
SwLedOff23a(padapter, pLed); SwLedOff23a(padapter, pLed);
RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("Blinktimes (%d): turn off\n", pLed->BlinkTimes)); RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("Blinktimes (%d): turn off\n", pLed->BlinkTimes));
} }
switch (pLed->CurrLedState) switch (pLed->CurrLedState) {
{
case LED_BLINK_SCAN: case LED_BLINK_SCAN:
pLed->BlinkTimes--; pLed->BlinkTimes--;
if (pLed->BlinkTimes == 0) if (pLed->BlinkTimes == 0) {
{
bStopBlinking = true; bStopBlinking = true;
} }
if (bStopBlinking) if (bStopBlinking) {
{
if (padapter->pwrctrlpriv.rf_pwrstate != rf_on) if (padapter->pwrctrlpriv.rf_pwrstate != rf_on)
{ {
SwLedOff23a(padapter, pLed); SwLedOff23a(padapter, pLed);
...@@ -467,15 +461,11 @@ static void SwLedBlink3(struct led_8723a *pLed) ...@@ -467,15 +461,11 @@ static void SwLedBlink3(struct led_8723a *pLed)
RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("CurrLedState %d\n", pLed->CurrLedState)); RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("CurrLedState %d\n", pLed->CurrLedState));
} }
pLed->bLedScanBlinkInProgress = false; pLed->bLedScanBlinkInProgress = false;
} } else {
else
{
if (padapter->pwrctrlpriv.rf_pwrstate != rf_on) if (padapter->pwrctrlpriv.rf_pwrstate != rf_on)
{ {
SwLedOff23a(padapter, pLed); SwLedOff23a(padapter, pLed);
} } else {
else
{
if (pLed->bLedOn) if (pLed->bLedOn)
pLed->BlinkingLedState = RTW_LED_OFF; pLed->BlinkingLedState = RTW_LED_OFF;
else else
...@@ -488,12 +478,10 @@ static void SwLedBlink3(struct led_8723a *pLed) ...@@ -488,12 +478,10 @@ static void SwLedBlink3(struct led_8723a *pLed)
case LED_BLINK_TXRX: case LED_BLINK_TXRX:
pLed->BlinkTimes--; pLed->BlinkTimes--;
if (pLed->BlinkTimes == 0) if (pLed->BlinkTimes == 0) {
{
bStopBlinking = true; bStopBlinking = true;
} }
if (bStopBlinking) if (bStopBlinking) {
{
if (padapter->pwrctrlpriv.rf_pwrstate != rf_on) if (padapter->pwrctrlpriv.rf_pwrstate != rf_on)
{ {
SwLedOff23a(padapter, pLed); SwLedOff23a(padapter, pLed);
...@@ -516,15 +504,11 @@ static void SwLedBlink3(struct led_8723a *pLed) ...@@ -516,15 +504,11 @@ static void SwLedBlink3(struct led_8723a *pLed)
RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("CurrLedState %d\n", pLed->CurrLedState)); RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("CurrLedState %d\n", pLed->CurrLedState));
} }
pLed->bLedBlinkInProgress = false; pLed->bLedBlinkInProgress = false;
} } else {
else
{
if (padapter->pwrctrlpriv.rf_pwrstate != rf_on) if (padapter->pwrctrlpriv.rf_pwrstate != rf_on)
{ {
SwLedOff23a(padapter, pLed); SwLedOff23a(padapter, pLed);
} } else {
else
{
if (pLed->bLedOn) if (pLed->bLedOn)
pLed->BlinkingLedState = RTW_LED_OFF; pLed->BlinkingLedState = RTW_LED_OFF;
else else
...@@ -545,8 +529,7 @@ static void SwLedBlink3(struct led_8723a *pLed) ...@@ -545,8 +529,7 @@ static void SwLedBlink3(struct led_8723a *pLed)
break; break;
case LED_BLINK_WPS_STOP: /* WPS success */ case LED_BLINK_WPS_STOP: /* WPS success */
if (pLed->BlinkingLedState == RTW_LED_ON) if (pLed->BlinkingLedState == RTW_LED_ON) {
{
pLed->BlinkingLedState = RTW_LED_OFF; pLed->BlinkingLedState = RTW_LED_OFF;
mod_timer(&pLed->BlinkTimer, jiffies + mod_timer(&pLed->BlinkTimer, jiffies +
msecs_to_jiffies(LED_BLINK_WPS_SUCESS_INTERVAL_ALPHA)); msecs_to_jiffies(LED_BLINK_WPS_SUCESS_INTERVAL_ALPHA));
...@@ -555,8 +538,7 @@ static void SwLedBlink3(struct led_8723a *pLed) ...@@ -555,8 +538,7 @@ static void SwLedBlink3(struct led_8723a *pLed)
bStopBlinking = true; bStopBlinking = true;
} }
if (bStopBlinking) if (bStopBlinking) {
{
if (padapter->pwrctrlpriv.rf_pwrstate != rf_on) if (padapter->pwrctrlpriv.rf_pwrstate != rf_on)
{ {
SwLedOff23a(padapter, pLed); SwLedOff23a(padapter, pLed);
...@@ -586,8 +568,7 @@ static void SwLedBlink4(struct led_8723a *pLed) ...@@ -586,8 +568,7 @@ static void SwLedBlink4(struct led_8723a *pLed)
unsigned long delay = 0; unsigned long delay = 0;
/* Change LED according to BlinkingLedState specified. */ /* Change LED according to BlinkingLedState specified. */
if (pLed->BlinkingLedState == RTW_LED_ON) if (pLed->BlinkingLedState == RTW_LED_ON) {
{
SwLedOn23a(padapter, pLed); SwLedOn23a(padapter, pLed);
RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("Blinktimes (%d): turn on\n", pLed->BlinkTimes)); RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("Blinktimes (%d): turn on\n", pLed->BlinkTimes));
} else { } else {
...@@ -602,8 +583,7 @@ static void SwLedBlink4(struct led_8723a *pLed) ...@@ -602,8 +583,7 @@ static void SwLedBlink4(struct led_8723a *pLed)
SwLedOff23a(padapter, pLed1); SwLedOff23a(padapter, pLed1);
} }
switch (pLed->CurrLedState) switch (pLed->CurrLedState) {
{
case LED_BLINK_SLOWLY: case LED_BLINK_SLOWLY:
if (pLed->bLedOn) if (pLed->bLedOn)
pLed->BlinkingLedState = RTW_LED_OFF; pLed->BlinkingLedState = RTW_LED_OFF;
...@@ -752,8 +732,7 @@ static void SwLedBlink5(struct led_8723a *pLed) ...@@ -752,8 +732,7 @@ static void SwLedBlink5(struct led_8723a *pLed)
RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("Blinktimes (%d): turn off\n", pLed->BlinkTimes)); RT_TRACE(_module_rtl8712_led_c_, _drv_info_, ("Blinktimes (%d): turn off\n", pLed->BlinkTimes));
} }
switch (pLed->CurrLedState) switch (pLed->CurrLedState) {
{
case LED_BLINK_SCAN: case LED_BLINK_SCAN:
pLed->BlinkTimes--; pLed->BlinkTimes--;
if (pLed->BlinkTimes == 0) { if (pLed->BlinkTimes == 0) {
...@@ -855,8 +834,7 @@ SwLedControlMode1(struct rtw_adapter *padapter, enum led_ctl_mode LedAction) ...@@ -855,8 +834,7 @@ SwLedControlMode1(struct rtw_adapter *padapter, enum led_ctl_mode LedAction)
long delay = -1; long delay = -1;
switch (LedAction) switch (LedAction) {
{
case LED_CTL_POWER_ON: case LED_CTL_POWER_ON:
case LED_CTL_START_TO_LINK: case LED_CTL_START_TO_LINK:
case LED_CTL_NO_LINK: case LED_CTL_NO_LINK:
...@@ -1185,8 +1163,7 @@ SwLedControlMode2(struct rtw_adapter *padapter, enum led_ctl_mode LedAction) ...@@ -1185,8 +1163,7 @@ SwLedControlMode2(struct rtw_adapter *padapter, enum led_ctl_mode LedAction)
break; break;
case LED_CTL_START_TO_LINK: case LED_CTL_START_TO_LINK:
case LED_CTL_NO_LINK: case LED_CTL_NO_LINK:
if (!IS_LED_BLINKING(pLed)) if (!IS_LED_BLINKING(pLed)) {
{
pLed->CurrLedState = RTW_LED_OFF; pLed->CurrLedState = RTW_LED_OFF;
pLed->BlinkingLedState = RTW_LED_OFF; pLed->BlinkingLedState = RTW_LED_OFF;
delay = 0; delay = 0;
...@@ -1230,8 +1207,7 @@ SwLedControlMode3(struct rtw_adapter *padapter, enum led_ctl_mode LedAction) ...@@ -1230,8 +1207,7 @@ SwLedControlMode3(struct rtw_adapter *padapter, enum led_ctl_mode LedAction)
struct led_8723a *pLed = &ledpriv->SwLed0; struct led_8723a *pLed = &ledpriv->SwLed0;
long delay = -1; long delay = -1;
switch (LedAction) switch (LedAction) {
{
case LED_CTL_SITE_SURVEY: case LED_CTL_SITE_SURVEY:
if (pmlmepriv->LinkDetectInfo.bBusyTraffic) if (pmlmepriv->LinkDetectInfo.bBusyTraffic)
; ;
...@@ -1345,8 +1321,7 @@ SwLedControlMode3(struct rtw_adapter *padapter, enum led_ctl_mode LedAction) ...@@ -1345,8 +1321,7 @@ SwLedControlMode3(struct rtw_adapter *padapter, enum led_ctl_mode LedAction)
case LED_CTL_START_TO_LINK: case LED_CTL_START_TO_LINK:
case LED_CTL_NO_LINK: case LED_CTL_NO_LINK:
if (!IS_LED_BLINKING(pLed)) if (!IS_LED_BLINKING(pLed)) {
{
pLed->CurrLedState = RTW_LED_OFF; pLed->CurrLedState = RTW_LED_OFF;
pLed->BlinkingLedState = RTW_LED_OFF; pLed->BlinkingLedState = RTW_LED_OFF;
delay = 0; delay = 0;
...@@ -1392,8 +1367,7 @@ SwLedControlMode4(struct rtw_adapter *padapter, enum led_ctl_mode LedAction) ...@@ -1392,8 +1367,7 @@ SwLedControlMode4(struct rtw_adapter *padapter, enum led_ctl_mode LedAction)
struct led_8723a *pLed = &ledpriv->SwLed0; struct led_8723a *pLed = &ledpriv->SwLed0;
struct led_8723a *pLed1 = &ledpriv->SwLed1; struct led_8723a *pLed1 = &ledpriv->SwLed1;
switch (LedAction) switch (LedAction) {
{
case LED_CTL_START_TO_LINK: case LED_CTL_START_TO_LINK:
if (pLed1->bLedWPSBlinkInProgress) { if (pLed1->bLedWPSBlinkInProgress) {
pLed1->bLedWPSBlinkInProgress = false; pLed1->bLedWPSBlinkInProgress = false;
...@@ -1550,8 +1524,7 @@ SwLedControlMode4(struct rtw_adapter *padapter, enum led_ctl_mode LedAction) ...@@ -1550,8 +1524,7 @@ SwLedControlMode4(struct rtw_adapter *padapter, enum led_ctl_mode LedAction)
} }
pLed->bLedWPSBlinkInProgress = true; pLed->bLedWPSBlinkInProgress = true;
pLed->CurrLedState = LED_BLINK_WPS; pLed->CurrLedState = LED_BLINK_WPS;
if (pLed->bLedOn) if (pLed->bLedOn) {
{
pLed->BlinkingLedState = RTW_LED_OFF; pLed->BlinkingLedState = RTW_LED_OFF;
mod_timer(&pLed->BlinkTimer, jiffies + mod_timer(&pLed->BlinkTimer, jiffies +
msecs_to_jiffies(LED_BLINK_SLOWLY_INTERVAL)); msecs_to_jiffies(LED_BLINK_SLOWLY_INTERVAL));
...@@ -1697,8 +1670,7 @@ SwLedControlMode5(struct rtw_adapter *padapter, enum led_ctl_mode LedAction) ...@@ -1697,8 +1670,7 @@ SwLedControlMode5(struct rtw_adapter *padapter, enum led_ctl_mode LedAction)
struct mlme_priv *pmlmepriv = &padapter->mlmepriv; struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
struct led_8723a *pLed = &ledpriv->SwLed0; struct led_8723a *pLed = &ledpriv->SwLed0;
switch (LedAction) switch (LedAction) {
{
case LED_CTL_POWER_ON: case LED_CTL_POWER_ON:
case LED_CTL_NO_LINK: case LED_CTL_NO_LINK:
case LED_CTL_LINK: /* solid blue */ case LED_CTL_LINK: /* solid blue */
...@@ -1712,10 +1684,8 @@ SwLedControlMode5(struct rtw_adapter *padapter, enum led_ctl_mode LedAction) ...@@ -1712,10 +1684,8 @@ SwLedControlMode5(struct rtw_adapter *padapter, enum led_ctl_mode LedAction)
if (pmlmepriv->LinkDetectInfo.bBusyTraffic && if (pmlmepriv->LinkDetectInfo.bBusyTraffic &&
check_fwstate(pmlmepriv, _FW_LINKED)) check_fwstate(pmlmepriv, _FW_LINKED))
; ;
else if (pLed->bLedScanBlinkInProgress == false) else if (pLed->bLedScanBlinkInProgress == false) {
{ if (pLed->bLedBlinkInProgress == true) {
if (pLed->bLedBlinkInProgress == true)
{
del_timer_sync(&pLed->BlinkTimer); del_timer_sync(&pLed->BlinkTimer);
pLed->bLedBlinkInProgress = false; pLed->bLedBlinkInProgress = false;
} }
......
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