]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
soc: sunxi: mbus: don't access of_root directly
authorBartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
Mon, 23 Feb 2026 13:37:24 +0000 (14:37 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 13 Mar 2026 09:21:31 +0000 (10:21 +0100)
Don't access of_root directly as it reduces the build test coverage for
this driver with COMPILE_TEST=y and OF=n. Use existing helper functions
to retrieve the relevant information.

Suggested-by: Rob Herring <robh@kernel.org>
Acked-by: Jernej Skrabec <jernej.skrabec@gmail.com>
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
Link: https://patch.msgid.link/20260223-soc-of-root-v2-9-b45da45903c8@oss.qualcomm.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/soc/sunxi/sunxi_mbus.c

index 1734da357ca21b249740e089698275507ea98a8a..8bc5f62ff258837d3f3b30cb84b60d1872b31c27 100644 (file)
@@ -118,7 +118,7 @@ static const char * const sunxi_mbus_platforms[] __initconst = {
 
 static int __init sunxi_mbus_init(void)
 {
-       if (!of_device_compatible_match(of_root, sunxi_mbus_platforms))
+       if (!of_machine_compatible_match(sunxi_mbus_platforms))
                return 0;
 
        bus_register_notifier(&platform_bus_type, &sunxi_mbus_nb);