dm: usb: Deal with USB keyboard persisting across tests
Clear any USB-keyboard devices before running a unit test, to avoid using a stale udevice pointer in stdio. Add a long comment to explain this situation and why this solution seems best, at least for now. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -179,6 +179,14 @@ void console_puts_select_stderr(bool serial_only, const char *s);
|
||||
*/
|
||||
int console_clear(void);
|
||||
|
||||
/**
|
||||
* console_remove_by_name() - Remove a console by its stdio name
|
||||
*
|
||||
* This must only be used in tests. It removes any use of the named stdio device
|
||||
* from the console tables.
|
||||
*/
|
||||
int console_remove_by_name(const char *name);
|
||||
|
||||
/*
|
||||
* CONSOLE multiplexing.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user