20 May, 2010

1 commit

  • While waiting for completion of the i2c transfer, the
    MPU could hit OFF mode and cause several msecs of
    delay that made i2c transfers fail more often. The
    extra delays and subsequent re-trys cause i2c clocks
    to be active more often. This has also an negative
    effect on power consumption.

    Created a mechanism for passing and using the
    constraint setting function in driver code. The used
    mpu wake up latency constraints are now set individually
    per bus, and they are calculated based on clock rate
    and fifo size.

    Thanks to Jarkko Nikula, Moiz Sonasath, Paul Walmsley,
    and Nishanth Menon for tuning out the details of
    this patch.

    Updates by Kevin as requested by Tony:

    - Remove omap_set_i2c_constraint_func() in favor of conditionally
    adding the flag in omap_i2c_add_bus() in order to keep all the OMAP
    conditional checking in a single location.
    - Update set_mpu_wkup_lat prototypes to match OMAP PM layer so
    OMAP PM function can be used directly in pdata.

    Cc: Moiz Sonasath
    Cc: Jarkko Nikula
    Cc: Paul Walmsley
    Cc: Nishanth Menon
    Signed-off-by: Kalle Jokiniemi
    Signed-off-by: Kevin Hilman
    Signed-off-by: Tony Lindgren
    Signed-off-by: Ben Dooks

    Kalle Jokiniemi