1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-07 00:48:01 +01:00
Files
openshift-docs/modules/kmm-setting-soft-dependencies-between-kernel-modules.adoc
2023-10-30 10:13:25 -04:00

42 lines
1.3 KiB
Plaintext

// Module included in the following assemblies:
//
// * hardware_enablement/kmm-kernel-module-management.adoc
:_mod-docs-content-type: CONCEPT
[id="kmm-setting-soft-dependencies-between-kernel-modules_{context}"]
= Set soft dependencies between kernel modules
Some configurations require that several kernel modules be loaded in a specific order to work properly, even though the modules do not directly depend on each other through symbols.
These are called soft dependencies.
`depmod` is usually not aware of these dependencies, and they do not appear in the files it produces.
For example, if `mod_a` has a soft dependency on `mod_b`, `modprobe mod_a` will not load `mod_b`.
You can resolve these situations by declaring soft dependencies in the Module Custom Resource Definition (CRD) using the `modulesLoadingOrder` field.
[source,yaml]
----
# ...
spec:
moduleLoader:
container:
modprobe:
moduleName: mod_a
dirName: /opt
firmwarePath: /firmware
parameters:
- param=1
modulesLoadingOrder:
- mod_a
- mod_b
----
In the configuration above:
* The loading order is `mod_b`, then `mod_a`.
* The unloading order is `mod_a`, then `mod_b`.
[NOTE]
====
The first value in the list, to be loaded last, must be equivalent to the `moduleName`.
====