Module Name: xsrc
Committed By: mrg
Date: Fri Jun 12 05:53:58 UTC 2009
Modified Files:
xsrc/external/mit/xf86-input-mouse/dist/src: mouse.c
Log Message:
merge WSMOUSEIO_SETVERSION fixes.
now my mouse works and my radeon works, with xorg-server 1.6!
To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c
diff -u xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c:1.4 xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c:1.5
--- xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c:1.4 Thu Jun 11 15:54:50 2009
+++ xsrc/external/mit/xf86-input-mouse/dist/src/mouse.c Fri Jun 12 05:53:58 2009
@@ -74,6 +74,11 @@
#define NEED_XF86_TYPES /* for xisb.h when !XFree86LOADER */
#endif
+#ifdef __NetBSD__
+#include <time.h>
+#include <dev/wscons/wsconsio.h>
+#endif
+
#include "compiler.h"
#include "xisb.h"
@@ -1751,6 +1756,13 @@
if (pInfo->fd == -1)
xf86Msg(X_WARNING, "%s: cannot open input device\n", pInfo->name);
else {
+#if defined(__NetBSD__) && defined(WSCONS_SUPPORT) && defined(WSMOUSEIO_SETVERSION)
+ if (!strcmp(pMse->protocol, "wsmouse")) {
+ int version = WSMOUSE_EVENT_VERSION;
+ if (ioctl(pInfo->fd, WSMOUSEIO_SETVERSION, &version) == -1)
+ xf86Msg(X_WARNING, "%s: cannot set version\n", pInfo->name);
+ }
+#endif
if (pMse->xisbscale)
pMse->buffer = XisbNew(pInfo->fd, pMse->xisbscale * 4);
else