mirror of
https://github.com/u-boot/u-boot.git
synced 2025-04-25 23:06:15 +00:00
pci_ep: Fix Coverity warning
Fix the following Coverity warning:
CID 244086: Incorrect expression (BAD_COMPARE)
Comparing pointer "ep_bar" against NULL using anything besides == or
is likely to be incorrect.
Fixes: 914026d258
("drivers: pci_ep: Introduce UCLASS_PCI_EP uclass")
Signed-off-by: Ramon Fried <rfried.dev@gmail.com>
This commit is contained in:
parent
2d88b5a38e
commit
6948f1023f
1 changed files with 1 additions and 1 deletions
|
@ -43,7 +43,7 @@ int pci_ep_set_bar(struct udevice *dev, uint func_no, struct pci_bar *ep_bar)
|
||||||
int flags = ep_bar->flags;
|
int flags = ep_bar->flags;
|
||||||
|
|
||||||
/* Some basic bar validity checks */
|
/* Some basic bar validity checks */
|
||||||
if (ep_bar->barno > BAR_5 || ep_bar < BAR_0)
|
if (ep_bar->barno > BAR_5 || ep_bar->barno < BAR_0)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
|
||||||
if ((ep_bar->barno == BAR_5 &&
|
if ((ep_bar->barno == BAR_5 &&
|
||||||
|
|
Loading…
Add table
Reference in a new issue