Re: Locking API testsuite: Failures

From: Ingo Molnar
Date: Wed Aug 27 2008 - 02:46:18 EST



* Peter Teoh <htmldeveloper@xxxxxxxxx> wrote:

> Several questions:

[...]
> 3. My current .config (which gave rise to the failure errors) [...]

You should have read this bit of the self-test printout:

[ 0.004000] 133 out of 218 testcases failed, as expected. |

there was no unexpected failure. A real test-case failure is displayed
as: 'FAILED', and you'll get a verbose printout about the unexpected
testcase failures.

> 1. I noticed there is a Kconfig.debug with this entry:
>
> config DEBUG_LOCKING_API_SELFTESTS
> bool "Locking API boot-time self-tests"
> depends on DEBUG_KERNEL
> help
> Say Y here if you want the kernel to run a short self-test during
> bootup. The self-test checks whether common types of locking bugs
> are detected by debugging mechanisms or not. (if you disable
> lock debugging then those bugs wont be detected of course.)
> The following locking APIs are covered: spinlocks, rwlocks,
> mutexes and rwsems.
>
> How do I use this Kconfig.debug, just overwriting the standard
> lib/Kconfig? [...]

no, that messes up the kernel. Kconfig.debug is a separate, unique
kconfig file with debugging related options.

> 2. So does it make sense to compile with
> CONFIG_DEBUG_LOCKING_API_SELFTESTS without CONFIG_LOCKDEP?

yes. It shows the kinds of bugs we dont find when PROVE_LOCKING is
disabled. It also shows that the test-cases are working as expected.

Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/