summaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@sun.com>2007-07-12 16:36:27 -0700
committerAlan Coopersmith <alan.coopersmith@sun.com>2007-07-12 16:36:27 -0700
commit6b4231e3b5b49b731c9a00930ae465fff8539831 (patch)
treefa7b6860f9a06461f37b1b878e1b9fa17ecaa736 /hw
parent9fcb30ebf7b7b2137955f759e95c1d58c4f27a11 (diff)
Use kbd driver when xorg.conf specifies "keyboard" or "Keyboard" (bug #11301)
X.Org Bug #11301 <https://bugs.freedesktop.org/show_bug.cgi?id=11301> Sun Bug #6560332 <http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=6560332>
Diffstat (limited to 'hw')
-rw-r--r--hw/xfree86/common/xf86Init.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/hw/xfree86/common/xf86Init.c b/hw/xfree86/common/xf86Init.c
index 8f3b23a73..d20a2714a 100644
--- a/hw/xfree86/common/xf86Init.c
+++ b/hw/xfree86/common/xf86Init.c
@@ -979,6 +979,17 @@ InitInput(argc, argv)
if (serverGeneration == 1) {
/* Call the PreInit function for each input device instance. */
for (pDev = xf86ConfigLayout.inputs; pDev && *pDev; pDev++) {
+ /* Replace obsolete keyboard driver with kbd */
+ if (!xf86NameCmp((*pDev)->driver, "keyboard")) {
+ xf86MsgVerb(X_WARNING, 0,
+ "*** WARNING the legacy keyboard driver \"%s\" has been removed\n",
+ (*pDev)->driver);
+ xf86MsgVerb(X_WARNING, 0,
+ "*** Using the new \"kbd\" driver for \"%s\".\n",
+ (*pDev)->identifier);
+ strcpy((*pDev)->driver, "kbd");
+ }
+
if ((pDrv = xf86LookupInputDriver((*pDev)->driver)) == NULL) {
xf86Msg(X_ERROR, "No Input driver matching `%s'\n", (*pDev)->driver);
/* XXX For now, just continue. */
@@ -1834,6 +1845,11 @@ xf86LoadModules(char **list, pointer *optlist)
if (name == NULL || *name == '\0')
continue;
+ /* Replace obsolete keyboard driver with kbd */
+ if (!xf86NameCmp(name, "keyboard")) {
+ strcpy(name, "kbd");
+ }
+
if (optlist)
opt = optlist[i];
else