Change-Id: Id664cdfe02f87b1f8bb37b9a4e3985c1eafef226
Signed-off-by: Huibin Hong <huibin.hong@rock-chips.com>
} else {
while (count--) {
if (*s == '\n') {
- kfifo_put(&fifo, &r);
+ kfifo_put(&fifo, r);
}
- kfifo_put(&fifo, s++);
+ kfifo_put(&fifo, *s++);
}
wake_up_process(t->console_task);
}
select FIQ_DEBUGGER
select PSTORE_RAM
default n
+
+config RK_CONSOLE_THREAD
+ bool "Console write by thread"
+ default n
+ help
+ Normal kernel printk will write out to UART by "kconsole" kthread
if (!state->console_enable && !state->syslog_dumping)
return;
+#ifdef CONFIG_RK_CONSOLE_THREAD
+ if (state->pdata->console_write) {
+ state->pdata->console_write(state->pdev, s, count);
+ return;
+ }
+#endif
+
fiq_debugger_uart_enable(state);
spin_lock_irqsave(&state->console_lock, flags);
while (count--) {
void (*force_irq)(struct platform_device *pdev, unsigned int irq);
void (*force_irq_ack)(struct platform_device *pdev, unsigned int irq);
+
+#ifdef CONFIG_RK_CONSOLE_THREAD
+ void (*console_write)(struct platform_device *pdev, const char *s,
+ unsigned int count);
+#endif
};
#endif