summaryrefslogtreecommitdiffstats
path: root/sys/dev/wscons/wsmouse.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Remove redundant conditional. Inspecting flags is the correct way toanton2019-05-241-5/+3
| | | | | | determine if the device was opened in read/write mode. ok mpi@ visa@
* Cleanup debug macros in wscons. Favor __func__ over spelling out the actualanton2019-05-221-9/+7
| | | | | function name in order to reduce grep noise. Also, some of them where referring to the wrong function.
* A wscons device may only be opened in read/write mode once. However,anton2019-05-221-2/+3
| | | | | | | | | | | after checking for exclusive access, malloc() can sleep in wsevent_init() opening up for a potential race where more than one thread may be able open the device. Prevent this by checking if the race was won after calling malloc(). While here, switch to mallocarray as proposed by both cheloha@ and mpi@ ok mpi@
* Switch to precision scrolling in wstpad.bru2019-03-241-5/+13
|
* favor C99 initializers for improved grepability; ok mpi@anton2019-02-191-3/+7
|
* Add support for TIOCGPGRP ioctl commands to wscons.anton2018-11-201-1/+8
| | | | ok visa@
* No need for wscons to handle FIOSETOWN ioctl requests since sys_ioctl()anton2018-11-201-8/+1
| | | | | | translates such requests into TIOCSPGRP. ok visa@
* Utilize sigio with wscons. The old behavior of always making the process groupanton2018-11-191-12/+12
| | | | | | | | | | | | | | of the process who opens the device the default recipient of sigio is removed as a side-effect of this change. Issuing ioctl(FIOSETOWN) is therefore mandatory in order to receive sigio, which is more consistent with other subsystems supporting sigio. This change is all made possible by the new sigio(9) API and prevents wscons from keeping a pointer to the recipient process. Usage of such pointer could cause a panic since wscons is not inform on process deallocation, leaving a dangling pointer behind. ok mpi@ visa@
* in the magical language gcc, adding brackets allows correct code to compile.deraadt2018-11-111-3/+3
|
* Remove the strong hysteresis filter.bru2018-11-101-46/+28
| | | | | | | It seems that the filter is obsolete, the default method is sufficient. Simplify and clean up some related code in wsmouse. ok mpi@
* Add logging options to wsmouse. Input and event logging for debugbru2018-05-071-1/+72
| | | | | purposes can be enabled and disabled by WSMOUSEIO_SETPARAMS requests.
* replace add_*_randomness with enqueue_randomness()jasper2018-04-281-2/+2
| | | | | | | | | this gets rid of the source annotation which doesn't really add anything other than adding complexitiy. randomess is generally good enough that the few extra bits that the source type would add are not worth it. ok mikeb@ deraadt@
* coordinate again: polishingbru2018-01-131-1/+5
|
* Improve the handling of coordinate inputs and filters.bru2018-01-111-64/+126
| | | | | | | | | | | | | | Single-touch and multi-touch coordinate inputs are treated more uniformly, and the hysteresis filters have a more consistent implementation. If possible, pointer control will be assigned to touches with coordinate updates that pass the default hysteresis filter (the function has been moved to wsmouse.c). The "strong" variant of hysteresis has been improved, the new version won't double the threshold when a movement changes the orientation on an axis. There is an additional change in wstpad_configure, which ensures that a zero size disables an edge area even if the coordinate limits are misconfigured.
* 1. Prepare a consistent treatment of edge areas. 2. Add mechanismsbru2017-11-231-6/+11
| | | | that identify and mask touches resting in the bottom area.
* Explain the multi-touch tracking function.bru2017-07-161-1/+11
|
* improved coordinate filtersbru2017-05-081-1/+19
| | | | ok mpi@
* Simplify wstpad option handling:mpi2017-03-161-96/+96
| | | | | | | | | - Remove unnecessary abstraction - Make it possible to support new features/options without ABI break - Remove some complexity and hard limits - Simplify & keep documentation close to options ok bru@
* Use 'inline' rather than _any of_ __the __other__ variants__.mpi2017-03-061-5/+5
| | | | ok bru@
* Handle touchpad input in wsmouse.bru2017-02-271-104/+139
| | | | | | | | The wstpad file contains the core of a touchpad-input driver that is coupled with wsmouse. It is active in compat-mode if wsmouse has been configured for it. ok @matthieu @stsp @mpi
* Improved parameter handling in wsmouse and new ioctls for reading andbru2016-10-231-73/+175
| | | | | | setting parameter values. ok matthieu@
* Reset the input state completely when wsmouse is (re-)opened.bru2016-08-181-2/+28
| | | | ok mpi@
* remove <0 check for an unsigned variablederaadt2016-07-131-2/+2
| | | | from tom
* Reset the mt state completely in wsmouse_mt_init.bru2016-07-121-5/+2
| | | | ok kettenis@
* Improve the tracking functions in wsmouse.bru2016-07-051-4/+7
| | | | ok mpi@
* Remove wsmouse_input.bru2016-06-061-216/+17
| | | | ok mpi@
* Add support for multitouch input to wsmouse.bru2016-03-301-1/+842
| | | | | | | This change adds new input-processing functions to wsmouse and adapts the touchpad drivers. ok mpi@, shadchin@
* kqueue(2) support for wsmouse(4), wskbd(4) and wsmux(4).mpi2015-09-101-1/+11
| | | | | | Needed for libinput port. ok guenther@, miod@
* Remove some includes include-what-you-use claims don'tjsg2015-03-141-2/+1
| | | | | | | have any direct symbols used. Tested for indirect use by compiling amd64/i386/sparc64 kernels. ok tedu@ deraadt@
* Stop supporting wsmoused and X in parallel. This code is racy andmpi2014-10-271-10/+1
| | | | | | known to break mice upon resume. ok shadchin@
* Fix jagged diagonal lines (kernel part)shadchin2013-10-301-8/+6
| | | | | | | | | Send WSCONS_EVENT_SYNC every time you call wsmouse_input(). Used to synchronize and separate events into packets of input data changes occurring at the same moment in time. For example, motion of a mouse may set the DELTA_X and DELTA_Y values for one motion, then emit a SYNC. ok matthieu@. tested edd@, Henri Kemppainen and Alf Schlichting.
* Introduce a dedicated private header file to control the optional featuresmiod2013-10-181-6/+3
| | | | | | | of wscons (which usually get disabled for installation kernels, to save space), instead of duplicating parts of it to too many places. No functional change.
* Fix for ClickPad. On issue pointed gilles@ and matthieu@shadchin2012-07-221-1/+9
| | | | ok gilles@, matthieu@, mpi@, miod@, deraadt@
* Adding support Synaptics touchpad. Thanks all for test.shadchin2011-08-171-1/+24
| | | | ok miod@, matthieu@
* Correct the links between threads, processes, pgrps, and sessions,guenther2010-07-261-5/+5
| | | | | | | | | so that the process-level stuff is to/from struct process and not struct proc. This fixes a bunch of problem cases in rthreads. Based on earlier work by blambert and myself, but mostly written at c2k10. Tested by many: deraadt, sthen, krw, ray, and in snapshots
* Get rid of devact enum, substitute it with an int and coresponding defines.pirofti2009-10-131-3/+3
| | | | | | This is needed for the addition of further suspend/resume actions. Okay deraadt@, marco@.
* Add support for a fourth axis on wsmouse devices, e.g. on the Apple Mightmiod2007-04-101-3/+28
| | | | | | Mouse. Currently limited to USB mice. Adapted from a diff from Gareth <garf@loveandnature.co.za> on tech@
* poll errors should be POLLERR, not some random E valuetedu2006-11-011-2/+3
| | | | from alexandre ratchov. ok claudio
* Honor (the lack of) FWRITE in the various ioctl routines; with input frommiod2005-08-141-1/+10
| | | | fgs@ and mickey@; ok deraadt@.
* Do not kill the event sink when closing a wsmouse device opened in write-onlymiod2005-06-011-1/+4
| | | | | | mode, thus only been used to issue ioctls. This chunk was lost in r1.14; reported by Douglas Santos.
* Do not compile the screen burner code if SMALL_KERNEL, helps floppies.miod2005-05-181-3/+7
| | | | ok deraadt@
* Partial sync to the NetBSD wscons code, bringing a better wsmux behaviourmiod2005-05-151-191/+174
| | | | | | | and bugfixes (the kqueue code, /dev/wsmuxctl and screen border color changes have not been picked), keeping local changes. Tested by many on alpha/cats/hp300/i386/macppc/sparc/sparc64/zaurus if not more.
* This moves access to wall and uptime variables in MI code,tholo2004-06-241-5/+2
| | | | | | | | | | | | | | encapsulating all such access into wall-defined functions that makes sure locking is done as needed. It also cleans up some uses of wall time vs. uptime some places, but there is sure to be more of these needed as well, particularily in MD code. Also, many current calls to microtime() should probably be changed to getmicrotime(), or to the {,get}microuptime() versions. ok art@ deraadt@ aaron@ matthieu@ beck@ sturm@ millert@ others "Oh, that is not your problem!" from miod@
* Replace select backends with poll backends. selscan() and pollscan()millert2003-09-231-2/+2
| | | | | | | now call the poll backend. With this change we implement greater poll(2) functionality instead of emulating it via the select backend. Adapted from NetBSD and including some changes from FreeBSD. Tested by many, deraadt@ OK
* Remove the advertising clause in the UCB license which Berkeleymillert2003-06-021-6/+2
| | | | rescinded 22 July 1999. Proofed by myself and Theo.
* cdev_decl is done in conf.h, do not dupe heremickey2002-04-301-3/+1
|
* Add X-Window support to wsmoused(8). This allows running wsmoused(8) andjbm2002-03-271-1/+11
| | | | | X-Window at the same time, removing the need to kill wsmoused(8) before starting X-Window.
* First round of __P removal in sysmillert2002-03-141-10/+10
|
* supply entropy from heremickey2001-10-041-1/+4
|
* inplement screen burner in screenblank(1) style (no program though).mickey2001-05-081-1/+3
| | | | | disabled by default, also supports vsync blanking, disabled by default. aaron@ looked at it a while back and i fixed problems he had indicated.