From: ye xingchen Date: Fri, 25 Nov 2022 07:44:36 +0000 (+0800) Subject: hwspinlock: Use device_match_of_node() X-Git-Tag: v6.3-rc1~70^2~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ec5c05e5ac8bcb4a6bcd92970e15494a85400d34;p=thirdparty%2Flinux.git hwspinlock: Use device_match_of_node() Replace the open-code with device_match_of_node(). Signed-off-by: ye xingchen Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Baolin Wang Signed-off-by: Bjorn Andersson Link: https://lore.kernel.org/r/202211251544369078587@zte.com.cn --- diff --git a/drivers/hwspinlock/hwspinlock_core.c b/drivers/hwspinlock/hwspinlock_core.c index fd5f5c5a5244d..22b8f2a70b3b8 100644 --- a/drivers/hwspinlock/hwspinlock_core.c +++ b/drivers/hwspinlock/hwspinlock_core.c @@ -367,7 +367,7 @@ int of_hwspin_lock_get_id(struct device_node *np, int index) continue; } - if (hwlock->bank->dev->of_node == args.np) { + if (device_match_of_node(hwlock->bank->dev, args.np)) { ret = 0; break; }