Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1678919 > unrolled thread

[PATCH] kmod: add dependencies for test module

Started byArnd Bergmann <arnd@arndb.de>
First post2017-06-30 17:50 +0200
Last post2017-07-01 01:00 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] kmod: add dependencies for test module Arnd Bergmann <arnd@arndb.de> - 2017-06-30 17:50 +0200
    Re: [PATCH] kmod: add dependencies for test module "Luis R. Rodriguez" <mcgrof@kernel.org> - 2017-07-01 01:00 +0200

#1678919 — [PATCH] kmod: add dependencies for test module

FromArnd Bergmann <arnd@arndb.de>
Date2017-06-30 17:50 +0200
Subject[PATCH] kmod: add dependencies for test module
Message-ID<tY6ld-7hu-41@gated-at.bofh.it>
When we try to 'select' drivers whose dependencies are not met,
we get a kconfig warning and undefined behavior as further 'select'
statements in those drivers can not be honored:

warning: (TEST_KMOD) selects TUN which has unmet direct dependencies (NETDEVICES && NET_CORE && INET)
warning: (TEST_KMOD) selects XFS_FS which has unmet direct dependencies (BLOCK && (64BIT || LBDAF))
ERROR: "iomap_zero_range" [fs/xfs/xfs.ko] undefined!
ERROR: "iomap_fiemap" [fs/xfs/xfs.ko] undefined!
ERROR: "iomap_page_mkwrite" [fs/xfs/xfs.ko] undefined!

To work around that, this adds the dependencies required by the
'tun', 'xfs' and 'btrfs' modules for CONFIG_TEST_KMOD, guaranteeing
that we can always enable those, and fixing the 'randconfig' issues.

Unfortunately, there is another problem that I have not found a
good solution for: If any of the three drivers are built-in rather
than loadable modules, then the module load test will later fail
at runtime.

Fixes: ec159fed8677 ("kmod: add test driver to stress test the module loader")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 lib/Kconfig.debug | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
index 411cddd713c0..0f7ba738ef7a 100644
--- a/lib/Kconfig.debug
+++ b/lib/Kconfig.debug
@@ -1883,6 +1883,8 @@ config TEST_KMOD
 	tristate "kmod stress tester"
 	default n
 	depends on m
+	depends on BLOCK && (64BIT || LBDAF)	  # for XFS, BTRFS
+	depends on NETDEVICES && NET_CORE && INET # for TUN
 	select TEST_LKM
 	select XFS_FS
 	select TUN
-- 
2.9.0

[toc] | [next] | [standalone]


#1679205

From"Luis R. Rodriguez" <mcgrof@kernel.org>
Date2017-07-01 01:00 +0200
Message-ID<tYd3j-30T-1@gated-at.bofh.it>
In reply to#1678919
On Fri, Jun 30, 2017 at 05:47:44PM +0200, Arnd Bergmann wrote:
> When we try to 'select' drivers whose dependencies are not met,
> we get a kconfig warning and undefined behavior as further 'select'
> statements in those drivers can not be honored:
> 
> warning: (TEST_KMOD) selects TUN which has unmet direct dependencies (NETDEVICES && NET_CORE && INET)
> warning: (TEST_KMOD) selects XFS_FS which has unmet direct dependencies (BLOCK && (64BIT || LBDAF))
> ERROR: "iomap_zero_range" [fs/xfs/xfs.ko] undefined!
> ERROR: "iomap_fiemap" [fs/xfs/xfs.ko] undefined!
> ERROR: "iomap_page_mkwrite" [fs/xfs/xfs.ko] undefined!
> 
> To work around that, this adds the dependencies required by the
> 'tun', 'xfs' and 'btrfs' modules for CONFIG_TEST_KMOD, guaranteeing
> that we can always enable those, and fixing the 'randconfig' issues.
> 
> Unfortunately, there is another problem that I have not found a
> good solution for: If any of the three drivers are built-in rather
> than loadable modules, then the module load test will later fail
> at runtime.
> 
> Fixes: ec159fed8677 ("kmod: add test driver to stress test the module loader")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>

Acked-by: Luis R. Rodriguez <mcgrof@kernel.org>

  Luis

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web