Commit f8c41a92 authored by Jes Sorensen's avatar Jes Sorensen Committed by Greg Kroah-Hartman

staging: rtl8723au: rtl8723au_led.c: Use BIT() instead of BITx

Signed-off-by: default avatarJes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 68c9da90
...@@ -41,14 +41,17 @@ void SwLedOn23a(struct rtw_adapter *padapter, struct led_8723a *pLed) ...@@ -41,14 +41,17 @@ void SwLedOn23a(struct rtw_adapter *padapter, struct led_8723a *pLed)
case LED_PIN_GPIO0: case LED_PIN_GPIO0:
break; break;
case LED_PIN_LED0: case LED_PIN_LED0:
rtw_write8(padapter, REG_LEDCFG0, (LedCfg&0xf0)|BIT5|BIT6); /* SW control led0 on. */ /* SW control led0 on. */
rtw_write8(padapter, REG_LEDCFG0, (LedCfg&0xf0)|BIT(5)|BIT(6));
break; break;
case LED_PIN_LED1: case LED_PIN_LED1:
rtw_write8(padapter, REG_LEDCFG1, (LedCfg&0x00)|BIT6); /* SW control led1 on. */ /* SW control led1 on. */
rtw_write8(padapter, REG_LEDCFG1, (LedCfg&0x00)|BIT(6));
break; break;
case LED_PIN_LED2: case LED_PIN_LED2:
LedCfg = rtw_read8(padapter, REG_LEDCFG2); LedCfg = rtw_read8(padapter, REG_LEDCFG2);
rtw_write8(padapter, REG_LEDCFG2, (LedCfg&0x80)|BIT5); /* SW control led1 on. */ /* SW control led1 on. */
rtw_write8(padapter, REG_LEDCFG2, (LedCfg&0x80)|BIT(5));
break; break;
default: default:
break; break;
...@@ -70,14 +73,17 @@ void SwLedOff23a(struct rtw_adapter *padapter, struct led_8723a *pLed) ...@@ -70,14 +73,17 @@ void SwLedOff23a(struct rtw_adapter *padapter, struct led_8723a *pLed)
case LED_PIN_GPIO0: case LED_PIN_GPIO0:
break; break;
case LED_PIN_LED0: case LED_PIN_LED0:
rtw_write8(padapter, REG_LEDCFG0, (LedCfg&0xf0)|BIT5|BIT6); /* SW control led0 on. */ /* SW control led0 on. */
rtw_write8(padapter, REG_LEDCFG0, (LedCfg&0xf0)|BIT(5)|BIT(6));
break; break;
case LED_PIN_LED1: case LED_PIN_LED1:
rtw_write8(padapter, REG_LEDCFG1, (LedCfg&0x00)|BIT5|BIT6); /* SW control led1 on. */ /* SW control led1 on. */
rtw_write8(padapter, REG_LEDCFG1, (LedCfg&0x00)|BIT(5)|BIT(6));
break; break;
case LED_PIN_LED2: case LED_PIN_LED2:
LedCfg = rtw_read8(padapter, REG_LEDCFG2); LedCfg = rtw_read8(padapter, REG_LEDCFG2);
rtw_write8(padapter, REG_LEDCFG2, (LedCfg&0x80)|BIT3|BIT5); /* SW control led1 on. */ /* SW control led1 on. */
rtw_write8(padapter, REG_LEDCFG2, (LedCfg&0x80)|BIT(3)|BIT(5));
break; break;
default: default:
break; break;
......
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