Subject: linux modules does not support inferior kernel

From: Oleg Pykhalov <[email-masked]>
Date: Sat, 04 Dec 2021 22:25:44 +0300

Hi Guix,

I cannot build a system after adding '(kernel-loadable-modules (list
vendor-reset-linux-module))' to the Guix system config.

--8<---------------cut here---------------start------------->8---
      (kernel-loadable-modules (list vendor-reset-linux-module))
      (kernel
       (let*
           ((channels
             (list (channel
                    (name 'nonguix)
                    (url "https://gitlab.com/nonguix/nonguix")
                    (commit "10cdced375f835c8a1f51a00ac0eefe38c82d00a"))
                   (channel
                    (name 'guix)
                    (url "https://git.savannah.gnu.org/git/guix.git")
                    (commit "de81a58f79425dcab3d5e149657b97114be56325"))))
            (inferior
             (inferior-for-channels channels)))
         (first (lookup-inferior-packages inferior "linux" "5.14"))))
--8<---------------cut here---------------end--------------->8---

--8<---------------cut here---------------start------------->8---
Backtrace:
In guix/store.scm:
   1320:8 19 (call-with-build-handler #<procedure 7fc7fe1f4f60 at g…> …)
  2119:24 18 (run-with-store #<store-connection 256.99 7fc800864910> …)
In guix/gexp.scm:
   1156:2 17 (_ #<store-connection 256.99 7fc800864910>)
   1022:2 16 (_ _)
    868:4 15 (_ _)
In guix/store.scm:
  2004:12 14 (_ #<store-connection 256.99 7fc800864910>)
   1381:9 13 (map/accumulate-builds #<store-connection 256.99 7fc80…> …)
   1320:8 12 (call-with-build-handler #<procedure 7fc7fe29af60 at g…> …)
  2119:24 11 (run-with-store #<store-connection 256.99 7fc800864910> …)
In guix/gexp.scm:
   873:13 10 (_ _)
In guix/store.scm:
   1956:8  9 (_ _)
In guix/gexp.scm:
   275:18  8 (_ _)
In guix/store.scm:
  1991:38  7 (_ #<store-connection 256.99 7fc800864910>)
In guix/packages.scm:
  1343:16  6 (package-derivation _ #<package vendor-reset-linux-mod…> …)
  1660:22  5 (thunk)
  1343:16  4 (package->bag _ _ _ #:graft? _)
  1445:21  3 (thunk)
In guix/build-system/linux-module.scm:
   133:22  2 (lower "vendor-reset-linux-module-0.0.1-1.225a49a" # _ . #)
In ice-9/boot-9.scm:
  1685:16  1 (raise-exception _ #:continuable? _)
  1685:16  0 (raise-exception _ #:continuable? _)

ice-9/boot-9.scm:1685:16: In procedure raise-exception:
In procedure %package-native-inputs-real: Wrong type argument: #<inferior-package [email-masked] 7fc8055619f0>
--8<---------------cut here---------------end--------------->8---