diff options
author | Tudor Ambarus <tudor.ambarus@microchip.com> | 2022-01-06 16:16:10 +0300 |
---|---|---|
committer | Miquel Raynal <miquel.raynal@bootlin.com> | 2022-01-23 18:37:18 +0300 |
commit | 65a01be4f5286af4e0af83292377a5904df642d9 (patch) | |
tree | 7394ea7265918fd62c7ce9d7e80768eb36c0563d /tools/perf/scripts/python/export-to-sqlite.py | |
parent | dbfbe79dbb6339196d5a26eaed70c3a50d6d154a (diff) | |
download | linux-65a01be4f5286af4e0af83292377a5904df642d9.tar.xz |
mtd: rawnand: Rework of_get_nand_bus_width()
of_get_nand_bus_width() had a wrong behavior because:
1/ it ignored the -ENODATA and -EOVERFLOW return values of
of_property_read_u32(). "nand-bus-width" without value was tolerated
while it shouldn't have been according to the devicetree bindings.
2/ returned -EIO when the nand-bus-width was neither 8 nor 16, when it
should have returned -EINVAL instead.
3/ returned the 8 or 16 bus-width integer, but it was never used it its
caller. A simply return 0 on success is enough.
Rework of_get_nand_bus_width() and address all the above. The execution
is now stopped in case of errors.
Signed-off-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20220106131610.225661-2-tudor.ambarus@microchip.com
Diffstat (limited to 'tools/perf/scripts/python/export-to-sqlite.py')
0 files changed, 0 insertions, 0 deletions