Hi Adam,

I've seen a similar problem on my laptop. Does the following patch help?
It's not pretty, but it does work on my box and it looks like always
doing a write to the AUX port doesn't hurt amd64 (at least it hasn't on
the boxes I've tried it on).

-- 
        Gregor

Index: dev/ic/pckbc.c
===================================================================
RCS file: /home/cvs/src/sys/dev/ic/pckbc.c,v
retrieving revision 1.49
diff -u -p -r1.49 pckbc.c
--- dev/ic/pckbc.c      24 May 2015 10:57:47 -0000      1.49
+++ dev/ic/pckbc.c      23 Jan 2017 13:41:43 -0000
@@ -378,11 +378,17 @@ pckbc_attach(struct pckbc_softc *sc, int
        bus_space_write_1(iot, ioh_d, 0, 0x5a); /* a random value */
        res = pckbc_poll_data1(iot, ioh_d, ioh_c, PCKBC_AUX_SLOT, 1);
 
-       if (ISSET(t->t_flags, PCKBC_NEED_AUXWRITE)) {
+#if defined(__amd64__)
+       t->t_flags |= PCKBC_NEED_AUXWRITE;
+#endif
+
+       if (ISSET(t->t_flags, PCKBC_NEED_AUXWRITE))
+       {
                /*
                 * The following code is necessary to find the aux port on the
-                * oqo-1 machine, among others.  However if confuses old
-                * (non-ps/2) keyboard controllers (at least UMC880x again).
+                * oqo-1 and Schenker S406 machines, among others.  However if
+                * confuses old (non-ps/2) keyboard controllers (at least
+                * UMC880x again).
                 */
                if (res == -1) {
                        /* Read of aux echo timed out, try again */
Index: dev/ic/pckbcvar.h
===================================================================
RCS file: /home/cvs/src/sys/dev/ic/pckbcvar.h,v
retrieving revision 1.15
diff -u -p -r1.15 pckbcvar.h
--- dev/ic/pckbcvar.h   24 May 2015 10:57:47 -0000      1.15
+++ dev/ic/pckbcvar.h   23 Jan 2017 13:41:43 -0000
@@ -53,7 +53,7 @@ struct pckbc_internal { 
 
        int t_flags;
 #define        PCKBC_CANT_TRANSLATE    0x0001  /* can't translate to XT 
scancodes */
-#define        PCKBC_NEED_AUXWRITE     0x0002  /* need auxwrite command to 
find aux */
+#define        PCKBC_NEED_AUXWRITE     0x0002  /* need auxwrite command to 
find aux, always set on amd64 */
        int t_haveaux; /* controller has an aux port */
 
        struct pckbc_slotdata *t_slotdata[PCKBC_NSLOTS];

Reply via email to