mirror of
https://gitlab.com/nonguix/nonguix.git
synced 2024-11-25 09:58:09 +01:00
services: nvidia: No longer unload ‘nvidia_uvm’ module on powering off.
Shepherd now handles kernel processes properly, no longer need to unload the module here. * nongnu/services/nvidia.scm (nvidia-shepherd-service)[requirement]: Remove 'user-processes. [one-shot?]: Set to #t. [stop]: Remove field. Signed-off-by: John Kehayias <john.kehayias@protonmail.com>
This commit is contained in:
parent
e4e34b7da4
commit
97925d2091
1 changed files with 4 additions and 7 deletions
|
@ -28,19 +28,16 @@
|
|||
|
||||
(define (nvidia-shepherd-service config)
|
||||
(let ((nvidia-driver (nvidia-configuration-driver config))
|
||||
(nvidia-smi (file-append nvidia-driver "/bin/nvidia-smi"))
|
||||
(rmmod (file-append kmod "/bin/rmmod")))
|
||||
(nvidia-smi (file-append nvidia-driver "/bin/nvidia-smi")))
|
||||
(list (shepherd-service
|
||||
(documentation "Prepare system environment for NVIDIA driver.")
|
||||
(provision '(nvidia))
|
||||
(requirement '(udev user-processes))
|
||||
(requirement '(udev))
|
||||
(one-shot? #t)
|
||||
(start
|
||||
#~(lambda _
|
||||
(when (file-exists? #$nvidia-smi)
|
||||
(system* #$nvidia-smi))))
|
||||
(stop
|
||||
#~(lambda _
|
||||
(system* #$rmmod "nvidia_uvm")))))))
|
||||
(system* #$nvidia-smi))))))))
|
||||
|
||||
(define nvidia-service-type
|
||||
(service-type
|
||||
|
|
Loading…
Reference in a new issue