mirror of
https://github.com/torvalds/linux.git
synced 2025-04-12 06:49:52 +00:00
irqchip/renesas-rzg2l: Simplify checks in rzg2l_irqc_common_init()
Both devm_pm_runtime_enable() and pm_runtime_resume_and_get() return 0 or a negative error code. Simplify the checks done with their respective return values accordingly. Signed-off-by: Fabrizio Castro <fabrizio.castro.jz@renesas.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/all/20250212182034.366167-7-fabrizio.castro.jz@renesas.com
This commit is contained in:
parent
4bd0317ce6
commit
0699e578e2
@ -565,11 +565,11 @@ static int rzg2l_irqc_common_init(struct device_node *node, struct device_node *
|
||||
}
|
||||
|
||||
ret = devm_pm_runtime_enable(dev);
|
||||
if (ret < 0)
|
||||
if (ret)
|
||||
return dev_err_probe(dev, ret, "devm_pm_runtime_enable failed: %d\n", ret);
|
||||
|
||||
ret = pm_runtime_resume_and_get(dev);
|
||||
if (ret < 0)
|
||||
if (ret)
|
||||
return dev_err_probe(dev, ret, "pm_runtime_resume_and_get failed: %d\n", ret);
|
||||
|
||||
raw_spin_lock_init(&rzg2l_irqc_data->lock);
|
||||
|
Loading…
x
Reference in New Issue
Block a user