mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2025-01-21 13:24:15 +08:00
mfd: stmfx: Fix stmfx_irq_init error path
In case the interrupt signal can't be configured, IRQ domain needs to be
removed.
Fixes: 06252ade91
("mfd: Add ST Multi-Function eXpander (STMFX) core driver")
Signed-off-by: Amelie Delaunay <amelie.delaunay@st.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
This commit is contained in:
parent
e583649d87
commit
60c2c4bcb9
@ -287,13 +287,18 @@ static int stmfx_irq_init(struct i2c_client *client)
|
||||
|
||||
ret = regmap_write(stmfx->map, STMFX_REG_IRQ_OUT_PIN, irqoutpin);
|
||||
if (ret)
|
||||
return ret;
|
||||
goto irq_exit;
|
||||
|
||||
ret = devm_request_threaded_irq(stmfx->dev, client->irq,
|
||||
NULL, stmfx_irq_handler,
|
||||
irqtrigger | IRQF_ONESHOT,
|
||||
"stmfx", stmfx);
|
||||
if (ret)
|
||||
goto irq_exit;
|
||||
|
||||
return 0;
|
||||
|
||||
irq_exit:
|
||||
stmfx_irq_exit(client);
|
||||
|
||||
return ret;
|
||||
|
Loading…
Reference in New Issue
Block a user