Skip to content
Commit b610c4bb authored by Carlos Song's avatar Carlos Song Committed by Wolfram Sang
Browse files

i2c: imx-lpi2c: return -EINVAL when i2c peripheral clk doesn't work



On MX8X platforms, the default clock rate is 0 if without explicit
clock setting in dts nodes. I2c can't work when i2c peripheral clk
rate is 0.

Add a i2c peripheral clk rate check before configuring the clock
register. When i2c peripheral clk rate is 0 and directly return
-EINVAL.

Signed-off-by: default avatarCarlos Song <carlos.song@nxp.com>
Acked-by: default avatarDong Aisheng <Aisheng.dong@nxp.com>
Reviewed-by: default avatarAndi Shyti <andi.shyti@kernel.org>
Signed-off-by: default avatarWolfram Sang <wsa@kernel.org>
parent 2ccdd1b1
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment