Subject: [WIP 0/6] Add kernel-module-configuration service

From: Brice Waegeneire <[email-masked]>
Date: Sat, 4 Jul 2020 20:52:34 +0200

Hello Guix,

Here is a work-in-progress to create a service centralizing the configuration
for built-in and loadable kernel modules.  The kernel module configuration
service has been implemented by making some fields from 'operating-system'
custom from the 'services' field.

Here are are some example of how to use it.
--8<---------------cut here---------------start------------->8---
;; Loadable kernel module
(simple-service 'ddcci-module kernel-module-configuration-service-type
                   (list (kernel-module
                          (name "ddcci")
                          (package ddcci-driver-linux)
                          (load? #t)
                          (options '("dyndbg" "delay=600")))
                         (kernel-module
                          (name "ddcci-backlight")
                          (blacklist? #t))))
;; Built-in kernel module
(simple-service 'intel-module
                         kernel-module-configuration-service-type
                         (list (kernel-module
                                (name "i915")
                                (options '("fastboot=1")))))
--8<---------------cut here---------------end--------------->8---

This WIP version is mainly missing the ability to configure built-in modules
trough the kernel arguments. It's the continuation of the work on
kernel-module-loader-service[1] and is needed to help fixing #41082[2].

I will try to go back to it after the GSOC network boot project.

[1]: https://issues.guix.info/40274
[2]: https://issues.guix.info/41082

- Brice

Brice Waegeneire (6):
  services: simulated-wifi: Use 'kernel-module-loader'.
  services: Add 'kernel-profile-service-type'.
  services: Add 'modprobe-service-type'.
  services: kernel-module-loader: Return a single 'shepherd-service'.
  WIP services: Add kernel-arguments-service-type.
  WIP services: Add kernel-module-configuration service.

 gnu/services.scm               | 102 +++++++++---
 gnu/services/linux.scm         | 276 +++++++++++++++++++++++++++++----
 gnu/services/networking.scm    |  25 +--
 gnu/system.scm                 |  55 +++++--
 gnu/system/linux-container.scm |   2 +
 gnu/tests/linux-modules.scm    |  65 +++++---
 6 files changed, 420 insertions(+), 105 deletions(-)

-- 
2.26.2