hwspinlock: Use device_match_of_node()

Replace the open-code with device_match_of_node().

Signed-off-by: ye xingchen <ye.xingchen@zte.com.cn>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Baolin Wang <baolin.wang@linux.alibaba.com>
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Link: https://lore.kernel.org/r/202211251544369078587@zte.com.cn
This commit is contained in:
ye xingchen 2022-11-25 15:44:36 +08:00 committed by Bjorn Andersson
parent 1b929c02af
commit ec5c05e5ac
1 changed files with 1 additions and 1 deletions

View File

@ -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;
}