From 200282a0bc392a9c45fc9954daa48dee9a90d2ea Mon Sep 17 00:00:00 2001 From: Bernard Xiong Date: Sun, 9 Aug 2015 11:34:41 +0800 Subject: [PATCH] [BSP] use RT_UNUSED instead of UNUSED --- bsp/lm3s8962/applications/startup.c | 4 +--- bsp/lpc2148/drivers/serial.c | 2 +- bsp/lpc2478/drivers/serial.c | 2 +- bsp/mb9bf500r/startup.c | 4 +--- bsp/mini4020/drivers/board.c | 2 +- bsp/mini4020/drivers/sdcard.c | 2 +- bsp/nios_ii/startup.c | 4 +--- 7 files changed, 7 insertions(+), 13 deletions(-) diff --git a/bsp/lm3s8962/applications/startup.c b/bsp/lm3s8962/applications/startup.c index 7f34aeef95..1f206a51b7 100644 --- a/bsp/lm3s8962/applications/startup.c +++ b/bsp/lm3s8962/applications/startup.c @@ -142,10 +142,8 @@ void rtthread_startup(void) int main(void) { - rt_uint32_t level UNUSED; - /* disable interrupt first */ - level = rt_hw_interrupt_disable(); + rt_hw_interrupt_disable(); rtthread_startup(); return 0; diff --git a/bsp/lpc2148/drivers/serial.c b/bsp/lpc2148/drivers/serial.c index 6cfcbb18a8..e8dcda2d0f 100644 --- a/bsp/lpc2148/drivers/serial.c +++ b/bsp/lpc2148/drivers/serial.c @@ -66,7 +66,7 @@ void rt_hw_serial_init(void); void rt_hw_uart_isr(struct rt_lpcserial* lpc_serial) { - UNUSED rt_uint32_t iir; + RT_UNUSED rt_uint32_t iir; RT_ASSERT(lpc_serial != RT_NULL) diff --git a/bsp/lpc2478/drivers/serial.c b/bsp/lpc2478/drivers/serial.c index 8a0e1aa15b..9bb95f2e0d 100644 --- a/bsp/lpc2478/drivers/serial.c +++ b/bsp/lpc2478/drivers/serial.c @@ -66,7 +66,7 @@ void rt_hw_serial_init(void); void rt_hw_uart_isr(int irqno, void *param) { - UNUSED rt_uint32_t iir; + RT_UNUSED rt_uint32_t iir; struct rt_lpcserial* lpc_serial = (struct rt_lpcserial*)param; RT_ASSERT(lpc_serial != RT_NULL) diff --git a/bsp/mb9bf500r/startup.c b/bsp/mb9bf500r/startup.c index 2549441b99..dc65496ba6 100644 --- a/bsp/mb9bf500r/startup.c +++ b/bsp/mb9bf500r/startup.c @@ -90,10 +90,8 @@ void rtthread_startup(void) int main(void) { - rt_uint32_t UNUSED level; - /* disable interrupt first */ - level = rt_hw_interrupt_disable(); + rt_hw_interrupt_disable(); /* init system setting */ SystemInit(); diff --git a/bsp/mini4020/drivers/board.c b/bsp/mini4020/drivers/board.c index 72b75d4846..b77d8faf59 100644 --- a/bsp/mini4020/drivers/board.c +++ b/bsp/mini4020/drivers/board.c @@ -51,7 +51,7 @@ void rt_serial_handler(int vector, void *param) { //rt_kprintf("in rt_serial_handler\n"); rt_int32_t stat = *(RP)UART0_IIR ; - UNUSED char c; + RT_UNUSED char c; /*Received data*/ if (((stat & 0x0E) >> 1) == 0x02) diff --git a/bsp/mini4020/drivers/sdcard.c b/bsp/mini4020/drivers/sdcard.c index 9b802d2ecf..af3e3fd419 100644 --- a/bsp/mini4020/drivers/sdcard.c +++ b/bsp/mini4020/drivers/sdcard.c @@ -271,7 +271,7 @@ static rt_err_t sd_readblock(rt_uint32_t address, rt_uint8_t* buf) U32 complete,i; rt_uint8_t temp; rt_err_t err; - UNUSED rt_uint32_t discard; + RT_UNUSED rt_uint32_t discard; #ifdef USE_TIMEOUT rt_uint32_t to = 10; #endif diff --git a/bsp/nios_ii/startup.c b/bsp/nios_ii/startup.c index cb43a7ae0b..25ebb5e4ac 100644 --- a/bsp/nios_ii/startup.c +++ b/bsp/nios_ii/startup.c @@ -85,10 +85,8 @@ void rtthread_startup(void) int main(void) { - rt_uint32_t UNUSED level; - /* disable interrupt first */ - level = rt_hw_interrupt_disable(); + rt_hw_interrupt_disable(); /* startup RT-Thread RTOS */ rtthread_startup();