]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
serial: altera_uart: use BIT macro
authorThomas Chou <thomas@wytron.com.tw>
Thu, 29 Oct 2015 13:18:01 +0000 (21:18 +0800)
committerThomas Chou <thomas@wytron.com.tw>
Fri, 6 Nov 2015 01:14:11 +0000 (09:14 +0800)
Replace numerical bit shift with BIT macro
in altera_uart

:%s/(1 << nr)/BIT(nr)/g
where nr = 0, 1, 2 .... 31

Signed-off-by: Thomas Chou <thomas@wytron.com.tw>
Reviewed-by: Jagan Teki <jteki@openedev.com>
drivers/serial/altera_uart.c

index 4ff9fe27a8bca7bf70f52c574e8711ff2fe1373a..7d5197a73f763af43d90ede3164ef2ab765642a8 100644 (file)
@@ -27,9 +27,9 @@ struct altera_uart_platdata {
 };
 
 /* status register */
-#define ALTERA_UART_TMT                (1 << 5)        /* tx empty */
-#define ALTERA_UART_TRDY       (1 << 6)        /* tx ready */
-#define ALTERA_UART_RRDY       (1 << 7)        /* rx ready */
+#define ALTERA_UART_TMT                BIT(5)  /* tx empty */
+#define ALTERA_UART_TRDY       BIT(6)  /* tx ready */
+#define ALTERA_UART_RRDY       BIT(7)  /* rx ready */
 
 DECLARE_GLOBAL_DATA_PTR;