OSDN Git Service

init: HACK: Try multiple times to open console
authorAndrew Boie <andrew.p.boie@intel.com>
Tue, 27 Nov 2012 20:58:19 +0000 (12:58 -0800)
committerChih-Wei Huang <cwhuang@linux.org.tw>
Sun, 16 Jun 2013 06:52:01 +0000 (14:52 +0800)
commitb0a534161ef9581c79451ffa06931878fa8760d9
treeea6520d373d4ac31f63c4f439f0d885a16ac1003
parent58a114dee59a093f41ad01c9cb15503572e02600
init: HACK: Try multiple times to open console

If the console is set to be a USB-to-serial adapter, there is
a bootup race for the creation of its associated device nodes
and init's one-time console detection.

If the console can't be opened, try polling up to 5 seconds. Log
an error if it ultimately fails.

A better solution would be to reimplement the console functionality
to be hot-pluggable, but this would require much more invasive changes
to make it robust.

Change-Id: I20b19095a2f22efffafe2a7ac22d2be753a62d4b
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
init/init.c