Commit 828e66c
i2c: omap: fix bus recovery setup
At least on the AM335x, enabling OMAP_I2C_SYSTEST_ST_EN is not enough to
allow direct access to the SCL and SDA pins. In addition to ST_EN, we
need to set the TMODE to 0b11 (Loop back & SDA/SCL IO mode select).
Also, as the reset values of SCL_O and SDA_O are 0 (which means "drive
low level"), we need to set them to 1 (which means "high-impedance") to
avoid unwanted changes on the pins.
As a precaution, reset all these bits to their default values after
recovery is complete.
Signed-off-by: Jan Luebbe <[email protected]>
Tested-by: Alexander Sverdlin <[email protected]>
Reviewed-by: Grygorii Strashko <[email protected]>
Signed-off-by: Wolfram Sang <[email protected]>1 parent 8b06260 commit 828e66c
1 file changed
+11
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1247 | 1247 | | |
1248 | 1248 | | |
1249 | 1249 | | |
| 1250 | + | |
1250 | 1251 | | |
| 1252 | + | |
| 1253 | + | |
| 1254 | + | |
| 1255 | + | |
| 1256 | + | |
| 1257 | + | |
1251 | 1258 | | |
1252 | 1259 | | |
1253 | 1260 | | |
| |||
1257 | 1264 | | |
1258 | 1265 | | |
1259 | 1266 | | |
| 1267 | + | |
1260 | 1268 | | |
| 1269 | + | |
| 1270 | + | |
| 1271 | + | |
1261 | 1272 | | |
1262 | 1273 | | |
1263 | 1274 | | |
| |||
0 commit comments