From b847099fdcc855b04b017a67bd6d3097ce277175 Mon Sep 17 00:00:00 2001 From: Geert Uytterhoeven Date: Thu, 3 Sep 2026 11:59:06 +0200 Subject: [PATCH] soc: atmel: Convert to of_machine_device_match() Use the of_machine_device_match() helper instead of open-coding the same operation. Signed-off-by: Geert Uytterhoeven Reviewed-by: Claudiu Beznea Link: https://lore.kernel.org/r/c3b4f8aceb5f0bc95fa10e6fa469574cfdaa8ee6.1788429505.git.geert+renesas@glider.be Signed-off-by: Claudiu Beznea --- drivers/soc/atmel/soc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/soc/atmel/soc.c b/drivers/soc/atmel/soc.c index d89f9dcade7d..7e60c5681ad0 100644 --- a/drivers/soc/atmel/soc.c +++ b/drivers/soc/atmel/soc.c @@ -404,9 +404,7 @@ static const struct of_device_id at91_soc_allowed_list[] __initconst = { static int __init atmel_soc_device_init(void) { - struct device_node *np __free(device_node) = of_find_node_by_path("/"); - - if (!of_match_node(at91_soc_allowed_list, np)) + if (!of_machine_device_match(at91_soc_allowed_list)) return 0; at91_soc_init(socs);