[PATCH] gnu: kmod: Update to 27.

  • Done
  • quality assurance status badge
Details
3 participants
  • Brice Waegeneire
  • Danny Milosavljevic
  • Marius Bakke
Owner
unassigned
Submitted by
Brice Waegeneire
Severity
normal
B
B
Brice Waegeneire wrote on 4 Apr 2020 09:15
(address . guix-patches@gnu.org)
20200404071534.17291-1-brice@waegenei.re
* gnu/packages/linux.scm (kmod): Update to 27. Enable tests.
---

This patch need to be merge on core-updates because > 2200 packages will need
to be rebuilt. Without this patch (in particular `--sysconfdir=/etc`) it's
not possible to pass module arguments to `kernel-module-loader` from

gnu/packages/linux.scm | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)

Toggle diff (43 lines)
diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index 945c15d972..10783c0f5a 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -42,6 +42,7 @@
;;; Copyright © 2020 Pierre Neidhardt <mail@ambrevar.xyz>
;;; Copyright © 2020 Chris Marusich <cmmarusich@gmail.com>
;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
+;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -2731,7 +2732,7 @@ to use Linux' inotify mechanism, which allows file accesses to be monitored.")
(define-public kmod
(package
(name "kmod")
- (version "26")
+ (version "27")
(source (origin
(method url-fetch)
(uri
@@ -2739,7 +2740,7 @@ to use Linux' inotify mechanism, which allows file accesses to be monitored.")
"kmod-" version ".tar.xz"))
(sha256
(base32
- "17dvrls70nr3b3x1wm8pwbqy4r8a5c20m0dhys8mjhsnpg425fsp"))
+ "035wzfzjx4nwidk747p8n085mgkvy531ppn16krrajx2dkqzply1"))
(patches (search-patches "kmod-module-directory.patch"))))
(build-system gnu-build-system)
(native-inputs
@@ -2748,8 +2749,8 @@ to use Linux' inotify mechanism, which allows file accesses to be monitored.")
`(("xz" ,xz)
("zlib" ,zlib)))
(arguments
- `(#:tests? #f ; FIXME: Investigate test failures
- #:configure-flags '("--with-xz" "--with-zlib")
+ `(#:configure-flags '("--with-xz" "--with-zlib" "--sysconfdir=/etc"
+ "--disable-test-modules")
#:phases
(modify-phases %standard-phases
(add-after 'install 'install-modprobe&co
--
2.26.0
M
M
Marius Bakke wrote on 5 Apr 2020 16:45
87y2rang83.fsf@devup.no
Brice Waegeneire <brice@waegenei.re> writes:

Toggle quote (8 lines)
> * gnu/packages/linux.scm (kmod): Update to 27. Enable tests.
> ---
>
> This patch need to be merge on core-updates because > 2200 packages will need
> to be rebuilt. Without this patch (in particular `--sysconfdir=/etc`) it's
> not possible to pass module arguments to `kernel-module-loader` from
> <https://issues.guix.info/issue/40274>.

As the core-updates branch is frozen right now, could you submit this
patch as a 'kmod/next' variable? See e.g. 'help2man/latest' or
'automake-1.16.2' for inspiration.

After the core-updates merge, we can do a larger 'staging' round that
updates the default 'kmod'.

I wonder if we should patch eudev to use
/run/current-system/profile/bin/ instead of /gnu/store/...kmod/bin so
that we can update kmod without triggering a huge rebuild.
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAl6J7xwACgkQoqBt8qM6
VPriLAf+Oq3tiSFXVXZPgTOzf9ah9kMUQFiKjiqy0BIp16ayx9ebkC2RXN1g26il
Tdv6XaPu3g/kq/Ftt/LhKWVKNUIr6NumXZjb0gBnJg8vrdIg7qFE6OjbFmrtI8jB
W9HjvjxYAmaffh4ukue/lUzKv+0avV5JjVnOlbImoeOqQ4nK3WE1qeLF6aX7/yjj
PCjbkx1fZX+V+sHIGsS5TmlAAq+RThE9dWbX3JBruDqi79MQuRUyOkjdScrFapWh
JiLyOmZXlU6zcwQIpjhZuDQgKRqWv6psfzhvhFIQlzdTBA4u7IcoZh3NyvDACPsM
pHXd03Rjhfs2CFkeVWWVay0gA3yvVA==
=fkQW
-----END PGP SIGNATURE-----

B
B
Brice Waegeneire wrote on 5 Apr 2020 17:57
(name . Marius Bakke)(address . mbakke@fastmail.com)(address . 40422@debbugs.gnu.org)
43344bcdc6c4b8ebf028f9fb76d9707c@waegenei.re
On 2020-04-05 14:45, Marius Bakke wrote:
Toggle quote (16 lines)
> Brice Waegeneire <brice@waegenei.re> writes:
>
>> * gnu/packages/linux.scm (kmod): Update to 27. Enable tests.
>> ---
>>
>> This patch need to be merge on core-updates because > 2200 packages
>> will need
>> to be rebuilt. Without this patch (in particular `--sysconfdir=/etc`)
>> it's
>> not possible to pass module arguments to `kernel-module-loader` from
>> <https://issues.guix.info/issue/40274>.
>
> As the core-updates branch is frozen right now, could you submit this
> patch as a 'kmod/next' variable? See e.g. 'help2man/latest' or
> 'automake-1.16.2' for inspiration.

I can do that but I would need to adjust %modprobe-wrapper for
`kernel-loader-module` to work without the crutch at 8c88e24229 since
the service
gets its modprobe from "/proc/sys/kernel/modprobe".

Toggle quote (7 lines)
> After the core-updates merge, we can do a larger 'staging' round that
> updates the default 'kmod'.
>
> I wonder if we should patch eudev to use
> /run/current-system/profile/bin/ instead of /gnu/store/...kmod/bin so
> that we can update kmod without triggering a huge rebuild.

eudev uses libkmod to to use it's kmod feature so I'm not sure how to do
this.
M
M
Marius Bakke wrote on 6 Apr 2020 00:14
(name . Brice Waegeneire)(address . brice@waegenei.re)(address . 40422@debbugs.gnu.org)
87tv1xoa0o.fsf@devup.no
Brice Waegeneire <brice@waegenei.re> writes:

Toggle quote (22 lines)
> On 2020-04-05 14:45, Marius Bakke wrote:
>> Brice Waegeneire <brice@waegenei.re> writes:
>>
>>> * gnu/packages/linux.scm (kmod): Update to 27. Enable tests.
>>> ---
>>>
>>> This patch need to be merge on core-updates because > 2200 packages
>>> will need
>>> to be rebuilt. Without this patch (in particular `--sysconfdir=/etc`)
>>> it's
>>> not possible to pass module arguments to `kernel-module-loader` from
>>> <https://issues.guix.info/issue/40274>.
>>
>> As the core-updates branch is frozen right now, could you submit this
>> patch as a 'kmod/next' variable? See e.g. 'help2man/latest' or
>> 'automake-1.16.2' for inspiration.
>
> I can do that but I would need to adjust %modprobe-wrapper for
> `kernel-loader-module` to work without the crutch at 8c88e24229 since
> the service
> gets its modprobe from "/proc/sys/kernel/modprobe".

Huh, what kind of sorcery is this? :-)

Let's hold this patch until core-updates is merged, then I think we can
run it through 'staging'.

Toggle quote (10 lines)
>> After the core-updates merge, we can do a larger 'staging' round that
>> updates the default 'kmod'.
>>
>> I wonder if we should patch eudev to use
>> /run/current-system/profile/bin/ instead of /gnu/store/...kmod/bin so
>> that we can update kmod without triggering a huge rebuild.
>
> eudev uses libkmod to to use it's kmod feature so I'm not sure how to do
> this.

Oh right, I didn't realize there was a libkmod.
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAl6KWEcACgkQoqBt8qM6
VPqUPAgAn5jDsoxusjdRa9Nw4BksU295peQjAuaHfRG2VFO+2YjrFpZGUvBEJBkG
jMOdq4xwO7ZkOGgm3JBqKcOMPT+lfE/HtaJNmND9acPTmyXVgXdimWn8Z98GVg37
jtcZUw99lqX5Mfu2p6O1jXRUE+QQsV4vki2V6zZxvCe0czgXtim+nxYiBPt0Rjev
cz8x5ZJFLK+Im6kTQCa4wgK/wxgdo4Au/MuHmRXOmGeUqPrQW//XB+arLIrwTl8v
TD/2DHsj4c0DjyNd2ZZogKKm9xa/XEKZaGNN03b3Na81ITneAU9bjNfaYwEiFO5Y
vJ0KBfYMmYUqTzhA6b45hRXBDI5jvA==
=NIuN
-----END PGP SIGNATURE-----

B
B
Brice Waegeneire wrote on 8 Apr 2020 09:11
[PATCH v3] gnu: kmod: Update to 27.
(address . guix-patches@gnu.org)
20200408071155.22620-1-brice@waegenei.re
* gnu/packages/linux.scm (kmod): Update to 27. Enable tests.
---

This patch isn't related with #40274[0] anymore, the “--sysconfdir” flag has
been removed as well as the reverting commit. As discussed in[1] the
configuration of modprobe will be done, in an other patch series, by setting
the “MODPROBE_OPTIONS” varaible in the wrapper returned by
“/proc/sys/kernel/modprobe”.


gnu/packages/linux.scm | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)

Toggle diff (43 lines)
diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index c8acb42352..386158290f 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -42,6 +42,7 @@
;;; Copyright © 2020 Pierre Neidhardt <mail@ambrevar.xyz>
;;; Copyright © 2020 Chris Marusich <cmmarusich@gmail.com>
;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
+;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -2779,7 +2780,7 @@ to use Linux' inotify mechanism, which allows file accesses to be monitored.")
(define-public kmod
(package
(name "kmod")
- (version "26")
+ (version "27")
(source (origin
(method url-fetch)
(uri
@@ -2787,7 +2788,7 @@ to use Linux' inotify mechanism, which allows file accesses to be monitored.")
"kmod-" version ".tar.xz"))
(sha256
(base32
- "17dvrls70nr3b3x1wm8pwbqy4r8a5c20m0dhys8mjhsnpg425fsp"))
+ "035wzfzjx4nwidk747p8n085mgkvy531ppn16krrajx2dkqzply1"))
(patches (search-patches "kmod-module-directory.patch"))))
(build-system gnu-build-system)
(native-inputs
@@ -2796,8 +2797,8 @@ to use Linux' inotify mechanism, which allows file accesses to be monitored.")
`(("xz" ,xz)
("zlib" ,zlib)))
(arguments
- `(#:tests? #f ; FIXME: Investigate test failures
- #:configure-flags '("--with-xz" "--with-zlib")
+ `(#:configure-flags '("--with-xz" "--with-zlib"
+ "--disable-test-modules")
#:phases
(modify-phases %standard-phases
(add-after 'install 'install-modprobe&co
--
2.26.0
D
D
Danny Milosavljevic wrote on 13 Apr 2020 13:20
(name . Brice Waegeneire)(address . brice@waegenei.re)(address . 40422@debbugs.gnu.org)
20200413132047.0cb6a80d@scratchpost.org
Hi Brice,

I get

depmod: WARNING: could not open modules.order at /lib/modules/4.4.4: No such file or directory
depmod: WARNING: could not open modules.builtin at /lib/modules/4.4.4: No such file or directory
depmod: WARNING: could not open modules.order at /lib/modules/4.4.4: No such file or directory
depmod: WARNING: could not open modules.builtin at /lib/modules/4.4.4: No such file or directory
[...]
TESTSUITE: 'depmod_search_order_external_last' [7595] exited with return code 0
TESTSUITE: ERR: sizes do not match /tmp/guix-build-kmod-27.drv-0/kmod-27/testsuite/rootfs/test-depmod/search-order-external-last/lib/modules/4.4.4/correct-modules.dep /tmp/guix-build-kmod-27.drv-0/kmod-27/testsuite/rootfs/test-depmod/search-order-external-last/lib/modules/4.4.4/modules.dep
TESTSUITE: ERR: FAILED: exit ok but outputs do not match: depmod_search_order_external_last
TESTSUITE: ------
FAIL testsuite/test-depmod (exit status: 1)

with your patch on staging...
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCAAdFiEEds7GsXJ0tGXALbPZ5xo1VCwwuqUFAl6USw8ACgkQ5xo1VCww
uqXKrQf/TnGM/8PVQCYFFa5uVj+NX+8Bx3jEGSdfTEqZTta6Kp+AZa72K6oQmrD/
UY3G9PCuZfK3VtQUEqNQq6Fzr9PIqDCVHWG+iA1NQEmJZ4LUFUADilz89GMnDkYt
h0yPN4ZJTjI6opLXgtVLGnqyz20VaS2QbZR4z5a4clc4wxzqWCsXAnaWjiWYEY8N
b1sbJecfhBX2gmNcXBZQCv3hGvsu2PjSI1TEA0xFaAWARvM/VZKtWheH8rkr3q7M
j1CN9RVj4ulhtW0XeWVO6dFwvrZ4DwgmNHA/9jLwmG+Ad+vvpGA6lhuIXAtkFbSg
GnUe74Js4fPz++eJSF88JQ4rfIM7JQ==
=NbW8
-----END PGP SIGNATURE-----


B
B
Brice Waegeneire wrote on 13 Apr 2020 15:34
[PATCH v4] gnu: kmod: Update to 27.
(address . guix-patches@gnu.org)
20200413133431.8039-1-brice@waegenei.re
* gnu/packages/linux.scm (kmod): Update to version 27.
[native-inputs]: Add 'automake' and 'autoconf'.
[arguments]: Add phase 'disable-tests'. Add configure flag
'--disable-test-modules'. Enable tests.
---

This version disable the 3 tests failling when '--sysconfdir=/etc' isn't used
as warned by “warning: Some tests will fail without --sysconfdir=/etc”.

gnu/packages/linux.scm | 20 +++++++++++++++-----
1 file changed, 15 insertions(+), 5 deletions(-)

Toggle diff (56 lines)
diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index 1c23489bc2..1de5ea8eaf 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -42,6 +42,7 @@
;;; Copyright © 2020 Pierre Neidhardt <mail@ambrevar.xyz>
;;; Copyright © 2020 Chris Marusich <cmmarusich@gmail.com>
;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
+;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -2731,7 +2732,7 @@ to use Linux' inotify mechanism, which allows file accesses to be monitored.")
(define-public kmod
(package
(name "kmod")
- (version "26")
+ (version "27")
(source (origin
(method url-fetch)
(uri
@@ -2739,19 +2740,28 @@ to use Linux' inotify mechanism, which allows file accesses to be monitored.")
"kmod-" version ".tar.xz"))
(sha256
(base32
- "17dvrls70nr3b3x1wm8pwbqy4r8a5c20m0dhys8mjhsnpg425fsp"))
+ "035wzfzjx4nwidk747p8n085mgkvy531ppn16krrajx2dkqzply1"))
(patches (search-patches "kmod-module-directory.patch"))))
(build-system gnu-build-system)
(native-inputs
- `(("pkg-config" ,pkg-config)))
+ `(("automake" ,automake)
+ ("autoconf" ,autoconf)
+ ("pkg-config" ,pkg-config)))
(inputs
`(("xz" ,xz)
("zlib" ,zlib)))
(arguments
- `(#:tests? #f ; FIXME: Investigate test failures
- #:configure-flags '("--with-xz" "--with-zlib")
+ `(#:configure-flags (list "--with-xz" "--with-zlib"
+ "--disable-test-modules")
#:phases
(modify-phases %standard-phases
+ (add-after 'unpack 'disable-tests
+ (lambda _
+ ;; XXX: These tests need '--sysconfdir=/etc' to pass.
+ (substitute* "Makefile.am"
+ (("testsuite/test-modprobe") "")
+ (("testsuite/test-depmod") "")
+ (("testsuite/test-blacklist") ""))))
(add-after 'install 'install-modprobe&co
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
--
2.26.0
B
B
Brice Waegeneire wrote on 13 Apr 2020 15:39
Re: [bug#40422] [PATCH v3] gnu: kmod: Update to 27.
(name . Danny Milosavljevic)(address . dannym@scratchpost.org)(address . 40422@debbugs.gnu.org)
6b075dde44256de061c7a6316081b65f@waegenei.re
Hello Danny,

On 2020-04-13 11:20, Danny Milosavljevic wrote:
Toggle quote (25 lines)
> Hi Brice,
>
> I get
>
> depmod: WARNING: could not open modules.order at /lib/modules/4.4.4:
> No such file or directory
> depmod: WARNING: could not open modules.builtin at /lib/modules/4.4.4:
> No such file or directory
> depmod: WARNING: could not open modules.order at /lib/modules/4.4.4:
> No such file or directory
> depmod: WARNING: could not open modules.builtin at /lib/modules/4.4.4:
> No such file or directory
> [...]
> TESTSUITE: 'depmod_search_order_external_last' [7595] exited with
> return code 0
> TESTSUITE: ERR: sizes do not match
> /tmp/guix-build-kmod-27.drv-0/kmod-27/testsuite/rootfs/test-depmod/search-order-external-last/lib/modules/4.4.4/correct-modules.dep
> /tmp/guix-build-kmod-27.drv-0/kmod-27/testsuite/rootfs/test-depmod/search-order-external-last/lib/modules/4.4.4/modules.dep
> TESTSUITE: ERR: FAILED: exit ok but outputs do not match:
> depmod_search_order_external_last
> TESTSUITE: ------
> FAIL testsuite/test-depmod (exit status: 1)
>
> with your patch on staging...

Thanks for the heads up. As written in the Makefile not using
“--sysconfdir=/etc” will make some tests fail, these tests are now
disable
in v4. BTW this patch should go on core-updates.

Cheers,
- Brice
B
B
Brice Waegeneire wrote on 21 Apr 2020 10:57
Re: [bug#40422] [PATCH v4] gnu: kmod: Update to 27.
(name . Danny Milosavljevic)(address . dannym@scratchpost.org)(address . 40422@debbugs.gnu.org)
954fbed54099f6b49b6e3f07466c6450@waegenei.re
Ping?
B
B
Brice Waegeneire wrote on 27 Apr 2020 15:51
[PATCH v5] gnu: Update kmod to 27.
(address . guix-patches@gnu.org)
20200427135145.18884-1-brice@waegenei.re
* gnu/packages/linux.scm (kmod): Update to version 27.
[native-inputs]: Add 'automake' and 'autoconf'.
[arguments]: Add phase 'disable-tests'. Add configure flag
'--disable-test-modules'. Enable tests.
---

Phase 'disable-tests' returns #t.

gnu/packages/linux.scm | 21 ++++++++++++++++-----
1 file changed, 16 insertions(+), 5 deletions(-)

Toggle diff (57 lines)
diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
index 12cb39ff9b..2b813286ff 100644
--- a/gnu/packages/linux.scm
+++ b/gnu/packages/linux.scm
@@ -42,6 +42,7 @@
;;; Copyright © 2020 Pierre Neidhardt <mail@ambrevar.xyz>
;;; Copyright © 2020 Chris Marusich <cmmarusich@gmail.com>
;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
+;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -2793,7 +2794,7 @@ to use Linux' inotify mechanism, which allows file accesses to be monitored.")
(define-public kmod
(package
(name "kmod")
- (version "26")
+ (version "27")
(source (origin
(method url-fetch)
(uri
@@ -2801,19 +2802,29 @@ to use Linux' inotify mechanism, which allows file accesses to be monitored.")
"kmod-" version ".tar.xz"))
(sha256
(base32
- "17dvrls70nr3b3x1wm8pwbqy4r8a5c20m0dhys8mjhsnpg425fsp"))
+ "035wzfzjx4nwidk747p8n085mgkvy531ppn16krrajx2dkqzply1"))
(patches (search-patches "kmod-module-directory.patch"))))
(build-system gnu-build-system)
(native-inputs
- `(("pkg-config" ,pkg-config)))
+ `(("automake" ,automake)
+ ("autoconf" ,autoconf)
+ ("pkg-config" ,pkg-config)))
(inputs
`(("xz" ,xz)
("zlib" ,zlib)))
(arguments
- `(#:tests? #f ; FIXME: Investigate test failures
- #:configure-flags '("--with-xz" "--with-zlib")
+ `(#:configure-flags (list "--with-xz" "--with-zlib"
+ "--disable-test-modules")
#:phases
(modify-phases %standard-phases
+ (add-after 'unpack 'disable-tests
+ (lambda _
+ ;; XXX: These tests need '--sysconfdir=/etc' to pass.
+ (substitute* "Makefile.am"
+ (("testsuite/test-modprobe") "")
+ (("testsuite/test-depmod") "")
+ (("testsuite/test-blacklist") ""))
+ #t))
(add-after 'install 'install-modprobe&co
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
--
2.26.0
B
B
Brice Waegeneire wrote on 10 May 2020 19:22
Pushed [PATCH] gnu: kmod: Update to 27
(address . 40422-done@debbugs.gnu.org)
37b16189859b812f02c983cf28fa3371@waegenei.re
Pushed on staging as 8229ce3116c1f522c7157ab2dcd50dc2d765686a.
Closed
?