i2c-pxa: prepare clock before use
authorDaniel Drake <dsd@laptop.org>
Mon, 17 Jun 2013 15:30:36 +0000 (11:30 -0400)
committerWolfram Sang <wsa@the-dreams.de>
Tue, 18 Jun 2013 16:11:32 +0000 (18:11 +0200)
commit7a10f4732972b48f75a547a42f9cdfef340124a6
tree9e8953c887e06377a50d18ab7cd74bc084cd1280
parent661f6c1cd926c6c973e03c6b5151d161f3a666ed
i2c-pxa: prepare clock before use

On OLPC XO-1.75 (MMP2), a WARN_ON() was occurring during boot
since the clock being enabled by i2c-pxa had not been prepared.

Use clk_prepare_enable() to ensure that the prepare operation
has taken place, and use clk_disable_unprepare() in the matching
shutdown paths.

Signed-off-by: Daniel Drake <dsd@laptop.org>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
drivers/i2c/busses/i2c-pxa.c