Open sthibaul opened 3 years ago
I'm fairly new to kernel development and Speakup seems very interesting and meaningful project for me. Since this is tagged as "good first issue", I would start with this.
Modprobe command seems to take arguments specified in /etc/modprobe.d/something.conf for every kernel module. I think modprobe would do the same for speakup modules as well. This will be done by a user in userspace, writing arguments to a .conf file in /etc/modprobe.d/filename.conf and running modprobe command on a speakup module.
I'm trying to understand the issue, please correct me if I'm wrong. Is this the issue about specifying sane default arguments in the docs so the users can write to /etc/modprobe.d/filename.conf. Any help or elaboration would be appreciated.
Thank you.
Hello,
Thanks for joining!
Support for taking parameters from something.conf is already there indeed, but the parameters don't exist yet. In the speakup_dectlk case, speakup_dectlk.c only supports the ser, dev, and start parameters, see the calls to module_param_named
and MODULE_PARM_DESC
. It would be useful to introduce the other parameters, to change the compile-time default value already set in the vars
array.
See for instance https://lore.kernel.org/r/20220829203625.6s6x57miowu4p664@begin
In that example we hardcoded DIRECT
being the first entry of the vars
array. To make it more general, we'd probably want to introduce in each file an enum that provides the index of each variable.
Thank you for detailed answer. I will look into it.
Hi, There's spk_vars for core speakup module(speakup.ko), should they also be parametrized as module parameters?
That would be useful as well, yes
Moreover, there's a description for these vars in Documentation/ABI/stable/sysfs-driver-speakup. Should we add that description in the MODULE_PARAM_DESC() or just "set x variable on load" will be enough?
The description from Documentation would be useful yes.
It would be useful to be able to specify the default driver parameters among the module command parameters, so that one can record for instance
in
/etc/modprobe.d/something.conf