Commit 1e0dca67 authored by Bartosz Golaszewski's avatar Bartosz Golaszewski Committed by Linus Walleij
Browse files

gpio: mockup: modify the return value check for devm_irq_sim_init()

As discussed with Marc Zyngier: irq_sim_init() and its devres variant
should return the base of the allocated interrupt range on success
rather than 0. This will be modified later - first, change the way
users handle the return value of these routines.

Signed-off-by: default avatarBartosz Golaszewski <>
Signed-off-by: default avatarLinus Walleij <>
parent c47bee95
......@@ -297,7 +297,7 @@ static int gpio_mockup_probe(struct platform_device *pdev)
rv = devm_irq_sim_init(dev, &chip->irqsim, gc->ngpio);
if (rv)
if (rv < 0)
return rv;
rv = devm_gpiochip_add_data(dev, &chip->gc, chip);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment