summaryrefslogtreecommitdiff
path: root/synaptics.c
diff options
context:
space:
mode:
Diffstat (limited to 'synaptics.c')
-rw-r--r--synaptics.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/synaptics.c b/synaptics.c
index 08e9f45..43ca30e 100644
--- a/synaptics.c
+++ b/synaptics.c
@@ -329,6 +329,15 @@ SynapticsPreInit(InputDriverPtr drv, IDevPtr dev, int flags)
if ((!str_par) || (xf86sscanf(str_par, "%lf", &priv->synpara->accl) != 1))
priv->synpara->accl=0.0015;
+ /* Warn about (and fix) mis-configured TopEdge/BottomEdge parameters */
+ if (priv->synpara->top_edge > priv->synpara->bottom_edge) {
+ int tmp = priv->synpara->top_edge;
+ priv->synpara->top_edge = priv->synpara->bottom_edge;
+ priv->synpara->bottom_edge = tmp;
+ xf86Msg(X_WARNING, "%s: TopEdge is bigger than BottomEdge. Fixing.\n",
+ local->name);
+ }
+
priv->buffer = XisbNew(local->fd, 200);
DBG(9, XisbTrace (priv->buffer, 1));