[PATCH v1 u-boot-marvell 4/5] arm64: mvebu: a37xx: add device-tree fixer for PCIe regions

Marek Behun marek.behun at nic.cz
Thu Apr 9 15:29:03 CEST 2020


Hi Stefan,

sorry I overlooked the other two things you commented on the code.

On Thu, 9 Apr 2020 10:09:52 +0200
Stefan Roese <sr at denx.de> wrote:

> > +	return -1;  
> 
> 	return -ENOENT; ?

The function returns u32. The error is reported by returning (u32)-1.
The check base < 0 won't work. I would specifically have to check for
-ENOENT, or use something like ERR_PTR from Linux.

> 	if (base < 0)
> 		return base; ?


More information about the U-Boot mailing list