One more questions about modules.

Didier Spaier didier at slint.fr
Thu Apr 18 17:53:57 EDT 2019


Hello,

this is somehow a follow-up of:
http://linux-speakup.org/pipermail/speakup/2019-April/061808.html

I have setup a procedure allowing to handle the same way hard
synthesizers, be the speakup drivers built-in the kernel or modularized.
I did that to allow users of hard synths to keep the
same kernel parameter when switching from the former case to the latter.

So, e.g. a user can in both cases append speakup.synth=apollo to the
boot command line.

In that aim I have included in /etc/rc.d/rc.S (the main startup script
run in Slackware and derivatives), soon in the startup sequence, this
code snippet:

# We want to handle synthesizers the same way regardless whether the
# speakup drivers are built-in the kernel or shipped as modules. So,
# parse the command line and if speakup.synth=<model> is found, try to
# load the corresponding module 
speakup_driver=$(grep 'speakup.synth=' /proc/cmdline| \
sed 's;.* speakup.synth=\([[:alpha:]]*\).*;\1;')
if [ ! "$speakup_driver" = "" ]; then
	modprobe speakup_$speakup_driver start=1 2>/dev/null
fi

Of course modprobe will fail if the driver is built in but this won't
hurt.

However, this leads to a question: as now speakup handles devices
connected through USB, should I handle this case with an udev rule
(well, eudev here)?

If yes, please someone give an example of such a rule if possible.

As an aside, shouldn't spkguide.txt be updated? As an example it stills
states:
Note: Speakup does * NOT * support usb connections!

Before someone ask: I am willing  to help updating it, but am unable to
list all the changes that occurred.

Best regards,

Didier



More information about the Speakup mailing list