Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 4 May 2017 23:04:52 +0000 (UTC)
From:      Vladimir Kondratyev <wulf@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r317815 - head/sys/dev/atkbdc
Message-ID:  <201705042304.v44N4qHT014143@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: wulf
Date: Thu May  4 23:04:52 2017
New Revision: 317815
URL: https://svnweb.freebsd.org/changeset/base/317815

Log:
  Enable palm detection on two finger touches for multitouch trackpads.
  
  Reviewed by:	gonzo
  Approved by:	gonzo (mentor)
  MFC after:	2 weeks
  Differential Revision:	https://reviews.freebsd.org/D10266

Modified:
  head/sys/dev/atkbdc/psm.c

Modified: head/sys/dev/atkbdc/psm.c
==============================================================================
--- head/sys/dev/atkbdc/psm.c	Thu May  4 23:02:34 2017	(r317814)
+++ head/sys/dev/atkbdc/psm.c	Thu May  4 23:04:52 2017	(r317815)
@@ -3065,8 +3065,9 @@ static int
 psmpalmdetect(struct psm_softc *sc, finger_t *f, int nfingers)
 {
 	if (!(
-	    ((sc->synhw.capMultiFinger ||
-	      sc->synhw.capAdvancedGestures) && nfingers > 1) ||
+	    ((sc->synhw.capMultiFinger || sc->synhw.capAdvancedGestures) &&
+	      !sc->synhw.capReportsV && nfingers > 1) ||
+	    (sc->synhw.capReportsV && nfingers > 2) ||
 	    (sc->synhw.capPalmDetect && f->w <= sc->syninfo.max_width) ||
 	    (!sc->synhw.capPalmDetect && f->p <= sc->syninfo.max_pressure) ||
 	    (sc->synhw.capPen && f->flags & PSM_FINGER_IS_PEN))) {
@@ -6188,7 +6189,10 @@ elantech_init_synaptics(struct psm_softc
 	sc->synhw.capPassthrough = sc->elanhw.hastrackpoint;
 	sc->synhw.capClickPad = sc->elanhw.isclickpad;
 	sc->synhw.capMultiFinger = 1;
-	sc->synhw.capAdvancedGestures = 1;
+	if (sc->elanhw.issemimt)
+		sc->synhw.capAdvancedGestures = 1;
+	else
+		sc->synhw.capReportsV = 1;
 	sc->synhw.capPalmDetect = 1;
 	sc->synhw.capPen = 0;
 	sc->synhw.capReportsMax = 1;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201705042304.v44N4qHT014143>