[U-Boot] [PATCH v11 04/16] regmap: Improve error handling

sjg at google.com sjg at google.com
Mon Oct 15 20:04:31 UTC 2018


ofnode_read_simple_addr_cells may fail and return a negative error code.
Check for this when initializing regmaps.

Also check if both_len is zero, since this is perfectly possible, and
would lead to a division-by-zero further down the line.

Reviewed-by: Anatolij Gustschin <agust at denx.de>
Reviewed-by: Simon Glass <sjg at chromium.org>
Signed-off-by: Mario Six <mario.six at gdsys.cc>

---
v10 -> v11:
No changes

v9 -> v10:
No changes

v8 -> v9:
No changes

v7 -> v8:
No changes

v6 -> v7:
No changes

v5 -> v6:
No changes

v4 -> v5:
No changes

v3 -> v4:
No changes

v2 -> v3:
New in v3
---
 drivers/core/regmap.c | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

Applied to u-boot-dm, thanks!


More information about the U-Boot mailing list