mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-08-05 16:54:27 +00:00
bus: ti-sysc: Use PTR_ERR_OR_ZERO() to simplify code
Fixes coccicheck warning: drivers/bus/ti-sysc.c:506:1-3: WARNING: PTR_ERR_OR_ZERO can be used Reported-by: Hulk Robot <hulkci@huawei.com> Signed-off-by: zhengbin <zhengbin13@huawei.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
This commit is contained in:
parent
426d4447f9
commit
3f2c420596
1 changed files with 1 additions and 3 deletions
|
@ -503,10 +503,8 @@ static int sysc_init_resets(struct sysc *ddata)
|
|||
{
|
||||
ddata->rsts =
|
||||
devm_reset_control_get_optional_shared(ddata->dev, "rstctrl");
|
||||
if (IS_ERR(ddata->rsts))
|
||||
return PTR_ERR(ddata->rsts);
|
||||
|
||||
return 0;
|
||||
return PTR_ERR_OR_ZERO(ddata->rsts);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Reference in a new issue