return dev_remap_addr_index(dev, 0);
}
-fdt_addr_t dev_read_addr_size(const struct udevice *dev, const char *property,
- fdt_size_t *sizep)
+fdt_addr_t dev_read_addr_size(const struct udevice *dev, fdt_size_t *sizep)
{
- return ofnode_get_addr_size(dev_ofnode(dev), property, sizep);
+ return dev_read_addr_size_index(dev, 0, sizep);
}
const char *dev_read_name(const struct udevice *dev)
fdt_addr_t addr;
fdt_size_t size;
- addr = dev_read_addr_size(dev, "reg", &size);
+ addr = dev_read_addr_size(dev, &size);
if (addr == FDT_ADDR_T_NONE)
return -EINVAL;
void *dev_remap_addr(const struct udevice *dev);
/**
- * dev_read_addr_size() - get address and size from a device property
- *
- * This does no address translation. It simply reads an property that contains
- * an address and a size value, one after the other.
+ * dev_read_addr_size() - Get the reg property of a device
*
* @dev: Device to read from
- * @propname: property to read
* @sizep: place to put size value (on success)
* Return: address value, or FDT_ADDR_T_NONE on error
*/
-fdt_addr_t dev_read_addr_size(const struct udevice *dev, const char *propname,
- fdt_size_t *sizep);
+fdt_addr_t dev_read_addr_size(const struct udevice *dev, fdt_size_t *sizep);
/**
* dev_read_name() - get the name of a device's node
}
static inline fdt_addr_t dev_read_addr_size(const struct udevice *dev,
- const char *propname,
fdt_size_t *sizep)
{
- return ofnode_get_addr_size(dev_ofnode(dev), propname, sizep);
+ return dev_read_addr_size_index(dev, 0, sizep);
}
static inline const char *dev_read_name(const struct udevice *dev)