tegra124: Add a macro specifically for configuring the I2C controller clocks

Hardware / Coreboot - Gabe Black [google.com] - 12 November 2014 23:27 UTC

The divider for the I2C clocks works differently than for other IP blocks and needs to be set up to reflect that. There's also a large internal divider which means you have to do extra calculations to determine what the frequency of the bus itself will be based on the I2C controller clock. The new macro takes the desired frequency of the bus itself and figures everything else out.

BUG=chrome-os-partner:25467 TEST=Built and booted on nyan rev1 using this function to set up the i2c busses. BRANCH=None

Original-Change-Id: Ib62a5659bcc0d0e15de41887514ae8efb8c8129a

51f6fb2 tegra124: Add a macro specifically for configuring the I2C controller clocks.
src/soc/nvidia/tegra124/include/soc/clock.h | 11 +++++++++++
1 file changed, 11 insertions(+)

Upstream: review.coreboot.org


  • Share