summaryrefslogtreecommitdiff
path: root/tools/zynqmp_psu_init_minimize.sh
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2020-04-22 10:13:53 -0600
committerHeiko Schocher <hs@denx.de>2020-05-28 05:50:00 +0200
commitbcf08503f571553074a4e9563977225446c183fa (patch)
tree08e36d1417a4c0797e60a65a56dc81389be5247c /tools/zynqmp_psu_init_minimize.sh
parentab80137cc436e977ef91a154372ae5aeae3f4fb0 (diff)
i2c: designware_i2c: Tidy up use of NULL priv
At present we still have pre-driver-model code in this driver and it makes things a bit confusing. In particular calc_bus_speed() is called with priv as NULL if not using driver model. This results in spk_cnt and comp_param1 being read from an invalid address if not using driver model. For comp_param1 this may not cause problems if reading from addresses close to 0 happens to be allowed, as high speed is only supported by DM code. But spk_cnt is subsequently used to calculate the bus periods and so this may cause problems (e.g. on spear600 board which has not been migrated yet). Add a new parameter regs parameter to calc_bus_speed() and add more comments to this function and to _dw_i2c_set_bus_speed(), which calls it. Signed-off-by: Simon Glass <sjg@chromium.org> Reported-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Diffstat (limited to 'tools/zynqmp_psu_init_minimize.sh')
0 files changed, 0 insertions, 0 deletions