moused(8): Start moused with devd
It is appeared that currently starting of moused does not depend on moused_enable variable value in rc.conf. That leads to missing USB mice support in default configuration. Start moused in traditional per device mode with devd to follow POLA. One daemon per system mode still can be enabled with setting of moused_port="auto" moused_nondefault_enable="NO" variables in /etc/rc.conf To revert to sysmouse mode add moused_type="sysmouse" to /etc/rc.conf Reported by: many Requested by: glebius Reviewed by: glebius MFC after: 1 day Differential Revision: https://reviews.freebsd.org/D52430
This commit is contained in:
+2
-2
@@ -586,11 +586,11 @@ font8x14="NO" # font 8x14 from /usr/share/{syscons,vt}/fonts/* (or NO).
|
||||
font8x8="NO" # font 8x8 from /usr/share/{syscons,vt}/fonts/* (or NO).
|
||||
blanktime="300" # blank time (in seconds) or "NO" to turn it off.
|
||||
saver="NO" # screen saver: Uses /boot/kernel/${saver}_saver.ko
|
||||
moused_nondefault_enable="NO" # Treat non-default mice as enabled unless
|
||||
moused_nondefault_enable="YES" # Treat non-default mice as enabled unless
|
||||
# specifically overridden in rc.conf(5).
|
||||
moused_enable="NO" # Run the mouse daemon.
|
||||
moused_type="evdev" # See man page for rc.conf(5) for available settings.
|
||||
moused_port="auto" # Set to your mouse port.
|
||||
moused_port="/dev/psm0" # Set to your mouse port.
|
||||
moused_flags="" # Any additional flags to moused.
|
||||
mousechar_start="NO" # if 0xd0-0xd3 default range is occupied in your
|
||||
# language code table, specify alternative range
|
||||
|
||||
@@ -28,9 +28,10 @@ moused_svcj="NO"
|
||||
# expected to be the mouse device.
|
||||
#
|
||||
if [ -n "$2" ]; then
|
||||
eval moused_$2_enable=\${moused_$2_enable-${moused_nondefault_enable}}
|
||||
rcvar="moused_${2}_enable"
|
||||
pidfile="${pidprefix}.$2.pid"
|
||||
ms=`basename $2`
|
||||
eval moused_${ms}_enable=\${moused_${ms}_enable-${moused_nondefault_enable}}
|
||||
rcvar="moused_${ms}_enable"
|
||||
pidfile="${pidprefix}.${ms}.pid"
|
||||
pidarg="-I $pidfile"
|
||||
fi
|
||||
|
||||
@@ -45,10 +46,10 @@ moused_start()
|
||||
# the moused_port variable, which if not defined sets it to the
|
||||
# passed in device name.
|
||||
#
|
||||
ms=$1
|
||||
ms=`basename $1`
|
||||
if [ -n "$ms" ]; then
|
||||
eval myflags=\${moused_${ms}_flags-$moused_flags}
|
||||
eval myport=\${moused_${ms}_port-/dev/$ms}
|
||||
eval myport=\${moused_${ms}_port-/dev/$1}
|
||||
eval mytype=\${moused_${ms}_type-$moused_type}
|
||||
if [ -n "$mytype" ] && check_kern_features evdev_support; then
|
||||
typearg="-t ${mytype}"
|
||||
|
||||
Reference in New Issue
Block a user