uhley@truebalt.caltech.edu (John D. Uhley) (05/18/91)
I'm running X11R4 with patches 1-18 applied on SPARCstation 2's running SUN OS 4.1.1. Occasionally, on exiting X I find that I am unable to restart X until I either reboot the machine or drop down into the bootprom monitor and resume my unix session. When trying to restart X I get the message: Fatal server bug! Unsupported keyboard type 0 Does anyone know what this is or what patch I might need to avoid it? Thanks, John uhley@albion.dei.caltech.edu message
kaleb@thyme.jpl.nasa.gov (Kaleb Keithley) (05/18/91)
In article <1991May17.171718.12393@nntp-server.caltech.edu> uhley@truebalt.caltech.edu (John D. Uhley) writes: > >I'm running X11R4 with patches 1-18 applied on SPARCstation 2's running >SUN OS 4.1.1. Occasionally, on exiting X I find that I am unable to > >Fatal server bug! >Unsupported keyboard type 0 > Are you sure it's 0? Here's the only fragment of code with "Unsupported keyboard type": if (sysKbPriv.type < 0 || sysKbPriv.type > KB_SUN4 || sunKeySyms[sysKbPriv.type].map == NULL) FatalError("Unsupported keyboard type %d\n", sysKbPriv.type); And you can clearly see that 0 is legal. The FatalError call eventually calls abort(), so you're probably getting a core dump too. Are you sure it isn't -1? If so I used to see this all the time running xdm. Sun's keyboard and/or kbd driver takes almost half a second to "settle down" and return the correct keyboard type after a mode set. xdm was starting a new server faster than the keyboard could reset. It is admittedly a kludge, but adding a "sleep(1);" after line 153 of sunKbd.c makes the problem go away. Another, sort of unrelated, but related item, are the lines: #ifndef (i386) #define TYPE4KEYBOARDOVERRIDE around line 142 of sunKbd.c. As of SunOS 4.1 this is no longer correct, and at least one way to make it right is to change them as follows: #if !defined(i386) && OSMajorVersion == 4 && OSMinorVersion == 0 #define TYPE4KEYBOARDOVERRIDE #endif -- Kaleb Keithley kaleb@thyme.jpl.nasa.gov Meep Meep Roadrunner Veep veep Quayle
guy@auspex.auspex.com (Guy Harris) (05/25/91)
>And you can clearly see that 0 is legal. No, you can clearly see that 0 is legal *only* if sunKeySyms[0].map is not NULL, and if you take a look at "mit/server/ddx/sun/sunKeyMap.c", you'll see that it *is* NULL. 0 is KB_KLUNK; only some old and, well, *klunky*, at this point, Sun-1s had the "klunker" Micro Switch 1032D32-2 keyboard; I don't know if anybody's done an X server port to them (the MIT server doesn't support them out of the box). Goodness knows why KIOCTYPE is reporting that he has a KB_KLUNK; the "sleep()" you recommend might fix the problem. >Are you sure it isn't -1? If so I used to see this all the time running >xdm. Sun's keyboard and/or kbd driver takes almost half a second to >"settle down" and return the correct keyboard type after a mode set. It's the keyboard; the driver resets the keyboard whenever the translation mode is changed, and the reset takes a while to complete.