On Wed, Apr 26, 2023 at 01:56:44PM +0200, Geert Uytterhoeven wrote:
Enabling a (modular) test must not silently enable additional kernel functionality, as that may increase the attack vector of a product.
Fix this by making REGMAP_KUNIT depend on REGMAP instead.
This doesn't work since regmap is a selected library so there's no way to directly enable regmap other than by enabling something that uses it and it is very likely that the virtual configurations people often use with KUnit will not have any physical hardware and therefore will not need regmap. It seems a lot more likely that someone would want to run the tests on a platform that doesn't otherwise use regmap than that someone would end up building in regmap on a production kernel that wouldn't otherwise have enabled it.