mirror of
https://github.com/torvalds/linux.git
synced 2026-03-08 03:04:51 +01:00
pinctrl: bcm: use PTR_ERR_OR_ZERO() to simplify code
Use the standard error pointer macro to shorten the code and simplify. Signed-off-by: Xichao Zhao <zhao.xichao@vivo.com> Link: https://lore.kernel.org/20250812081243.22659-1-zhao.xichao@vivo.com Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
This commit is contained in:
parent
4b4dbf0f26
commit
faba66cfce
1 changed files with 1 additions and 3 deletions
|
|
@ -343,10 +343,8 @@ static int bcm6358_pinctrl_probe(struct platform_device *pdev)
|
|||
pc = platform_get_drvdata(pdev);
|
||||
|
||||
priv->overlays = devm_regmap_field_alloc(dev, pc->regs, overlays);
|
||||
if (IS_ERR(priv->overlays))
|
||||
return PTR_ERR(priv->overlays);
|
||||
|
||||
return 0;
|
||||
return PTR_ERR_OR_ZERO(priv->overlays);
|
||||
}
|
||||
|
||||
static const struct of_device_id bcm6358_pinctrl_match[] = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue