From: 黄涛 Date: Tue, 1 Jul 2014 07:43:00 +0000 (+0800) Subject: ARM: rockchip: pm-rk3288.c fix compilation warning when RK_LAST_LOG is not selected X-Git-Tag: firefly_0821_release~5012 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=0b3023b70ce07d6689311e68035ebfaf072ef123;p=firefly-linux-kernel-4.4.55.git ARM: rockchip: pm-rk3288.c fix compilation warning when RK_LAST_LOG is not selected --- diff --git a/arch/arm/mach-rockchip/pm-rk3288.c b/arch/arm/mach-rockchip/pm-rk3288.c index 043f259b4a5e..86fe55a9eca2 100755 --- a/arch/arm/mach-rockchip/pm-rk3288.c +++ b/arch/arm/mach-rockchip/pm-rk3288.c @@ -1347,19 +1347,15 @@ extern void rk_last_log_text(char *text, size_t size); static void ddr_printch(char byte) { - char last_char; - uart_printch(byte); #ifdef CONFIG_RK_LAST_LOG - last_char=byte; - rk_last_log_text(&last_char,1); - - if (byte == '\n') { - last_char='\r'; - rk_last_log_text(&last_char,1); - } - + rk_last_log_text(&byte, 1); + + if (byte == '\n') { + byte = '\r'; + rk_last_log_text(&byte, 1); + } #endif pll_udelay(2); }