lib/glob.c: add CONFIG_GLOB_SELFTEST
[sfrench/cifs-2.6.git] / lib / Kconfig
index 334f7722a999232aa46b706d8cda61b57c854708..df872659ddd3d699a3f204b50720c59ff0f29092 100644 (file)
@@ -396,6 +396,39 @@ config CPU_RMAP
 config DQL
        bool
 
+config GLOB
+       bool
+#      This actually supports modular compilation, but the module overhead
+#      is ridiculous for the amount of code involved.  Until an out-of-tree
+#      driver asks for it, we'll just link it directly it into the kernel
+#      when required.  Since we're ignoring out-of-tree users, there's also
+#      no need bother prompting for a manual decision:
+#      prompt "glob_match() function"
+       help
+         This option provides a glob_match function for performing
+         simple text pattern matching.  It originated in the ATA code
+         to blacklist particular drive models, but other device drivers
+         may need similar functionality.
+
+         All drivers in the Linux kernel tree that require this function
+         should automatically select this option.  Say N unless you
+         are compiling an out-of tree driver which tells you that it
+         depends on this.
+
+config GLOB_SELFTEST
+       bool "glob self-test on init"
+       default n
+       depends on GLOB
+       help
+         This option enables a simple self-test of the glob_match
+         function on startup.  It is primarily useful for people
+         working on the code to ensure they haven't introduced any
+         regressions.
+
+         It only adds a little bit of code and slows kernel boot (or
+         module load) by a small amount, so you're welcome to play with
+         it, but you probably don't need it.
+
 #
 # Netlink attribute parsing support is select'ed if needed
 #
@@ -451,7 +484,8 @@ config MPILIB
 
 config SIGNATURE
        tristate
-       depends on KEYS && CRYPTO
+       depends on KEYS
+       select CRYPTO
        select CRYPTO_SHA1
        select MPILIB
        help