Thread (13 messages) 13 messages, 3 authors, 2021-10-19

Re: Delaying i8042 probe?

From: Fabio Estevam <festevam@gmail.com>
Date: 2021-09-10 11:07:31

Hi Takashi,

On Fri, Sep 10, 2021 at 7:50 AM Takashi Iwai [off-list ref] wrote:
Hi,

we've received a bug report about the missing keyboard on ASUS Zenbook
14 with AMD Ryzen:
  https://bugzilla.suse.com/show_bug.cgi?id=1190256

In short, PS2 keyboard couldn't be probed at the cold boot, while it
could be detected fine at the warm boot.  The failure appears like:

[    0.512668] i8042: PNP: PS/2 Controller [PNP0303:PS2K] at 0x60,0x64 irq 1
[    0.512672] i8042: PNP: PS/2 appears to have AUX port disabled, if this is incorrect please boot with i8042.nopnp
[    1.033609] i8042: Can't read CTR while initializing i8042
[    1.033632] i8042: probe of i8042 failed with error -5

As openSUSE kernel builds PS2 drivers as built-in, and the probe at
the early boot failed.  Meanwhile, when we rebuilt the kernel with
those drivers as modules, it starts working magically.  So, this is
likely a timing problem.

A possibly workaround I can think of would be to allow re-probing the
device at a later point.  Do we have a good way for that, or a better
alternative solution?
Would probe defer help here?

Something like this:
--- a/drivers/input/serio/i8042.c
+++ b/drivers/input/serio/i8042.c
@@ -1549,7 +1549,7 @@ static int __init i8042_probe(struct platform_device *dev)

        error = i8042_controller_init();
        if (error)
-               return error;
+               return -EPROBE_DEFER;

 #ifdef CONFIG_X86
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help