expo: Add a function to poll for input
authorSimon Glass <sjg@chromium.org>
Fri, 2 May 2025 14:46:16 +0000 (08:46 -0600)
committerSimon Glass <sjg@chromium.org>
Fri, 30 May 2025 08:49:31 +0000 (09:49 +0100)
commitbf9860459516d1837e92270340ca307211cd961a
tree07a30de0e77474896d5a0f942fda3150ef14b44a
parent5c365ecabcac6d3218cf7e560bda01629a46d88e
expo: Add a function to poll for input

Both bootflow_menu and cedit use similar logic to poll an expo. Move
this into the expo library so the code can be shared.

Update bootflow_menu_run() to return -EPIPE when the user quits without
choosing anything, since -EAGAIN is ambiguous and elsewhere means that
there is no input yet.

Signed-off-by: Simon Glass <sjg@chromium.org>
boot/bootflow_menu.c
boot/cedit.c
boot/expo.c
cmd/bootflow.c
include/bootflow.h
include/expo.h