evdevd: read raw input tap (consumer_raw), bump base

Point evdevd at /scheme/input/consumer_raw (the new raw device tap added in
base bd5e3db3) instead of /scheme/input/consumer. The console consumer handed
evdevd keymapped, VT-gated events — it only received input while its own VT
was active, and the character had already been keymapped, both wrong for a
libinput/xkbcommon (Wayland) feed. The raw tap delivers the pre-keymap event
stream for every device event regardless of the active VT, matching the Linux
evdev contract.

evdevd only ever used scancode+pressed (never character), so no translation
change is needed on its side.

Bumps the base submodule pointer to include the consumer_raw tap. Part of the
Linux-aligned input-stack consolidation
(local/docs/INPUT-STACK-LINUX-ALIGNMENT-PLAN.md). Compile-checked for
x86_64-unknown-redox.
This commit is contained in:
2026-07-24 11:58:14 +09:00
parent 1e5c080563
commit 8597609c3b
2 changed files with 11 additions and 4 deletions
+10 -3
View File
@@ -60,11 +60,18 @@ struct InputConsumer {
impl InputConsumer {
fn open() -> Result<Self, String> {
// Open the RAW device tap, not the console consumer. The raw tap gives us
// the pre-keymap event stream for every device event regardless of the
// active VT — the Linux `evdev` contract that libinput/xkbcommon expect.
// Reading the plain `/scheme/input/consumer` instead (the old wiring)
// handed evdevd keymapped, VT-gated events: it only saw input while its
// own VT was foregrounded and the `character` had already been mapped,
// which is wrong for a Wayland/libinput feed.
let file = OpenOptions::new()
.read(true)
.custom_flags(O_NONBLOCK as i32)
.open("/scheme/input/consumer")
.map_err(|e| format!("failed to open /scheme/input/consumer: {e}"))?;
.open("/scheme/input/consumer_raw")
.map_err(|e| format!("failed to open /scheme/input/consumer_raw: {e}"))?;
Ok(Self {
file,
@@ -253,7 +260,7 @@ fn run() -> Result<(), String> {
redox_scheme::scheme::register_sync_scheme(&socket, "evdev", &mut scheme)
.map_err(|e| format!("failed to register evdev scheme: {}", e))?;
info!("evdevd: registered scheme:evdev");
info!("evdevd: consuming orbclient::Event from /scheme/input/consumer");
info!("evdevd: consuming raw orbclient::Event from /scheme/input/consumer_raw");
#[cfg(target_os = "redox")]
{