mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
synced 2025-01-09 15:29:16 +00:00
memory: renesas-rpc-if: simplify with PTR_ERR_OR_ZERO
Use PTR_ERR_OR_ZERO to make the code a little bit simpler. Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org> Link: https://lore.kernel.org/r/20200724074038.5597-17-krzk@kernel.org
This commit is contained in:
parent
dc1a9283f1
commit
3cd7040762
@ -199,10 +199,8 @@ int rpcif_sw_init(struct rpcif *rpc, struct device *dev)
|
||||
rpc->dirmap = NULL;
|
||||
|
||||
rpc->rstc = devm_reset_control_get_exclusive(&pdev->dev, NULL);
|
||||
if (IS_ERR(rpc->rstc))
|
||||
return PTR_ERR(rpc->rstc);
|
||||
|
||||
return 0;
|
||||
return PTR_ERR_OR_ZERO(rpc->rstc);
|
||||
}
|
||||
EXPORT_SYMBOL(rpcif_sw_init);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user