]> git.karo-electronics.de Git - karo-tx-linux.git/commit
ENGR00221671 - i2c :imx : fix some i2c devices can not suspend
authorFugang Duan <B38611@freescale.com>
Mon, 10 Sep 2012 05:05:26 +0000 (13:05 +0800)
committerLothar Waßmann <LW@KARO-electronics.de>
Fri, 24 May 2013 06:35:24 +0000 (08:35 +0200)
commitbfe7bd1edbb183c169691d99b9b1a26b6a41be16
tree8df270ebb3afe452f859d54cd9466ec8a660f670
parent8a7e0dcddd309bcb30a34f2953e8fb42e120d9a6
ENGR00221671 - i2c :imx : fix some i2c devices can not suspend

i2c device (isl29023) can not suspend once during hdmi
audio suspend/resume test, and print log:

pm_op(): i2c_device_pm_suspend+0x0/0x38 returns -4 PM: Device
2-0044 failed to suspend: error -4 PM: Some devices failed to
suspend PM: resume of devices complete after 40.936 msecs
Restarting tasks ... done.

Because suspend function in isl29023 driver requires i2c bus
to write isl29023 device. I2C apdater driver process any signal
as exception during waiting the bus idle, so once user space sent
out signal during suspend, I2C device cannot request bus.

Using "fatal_signal_pending()" instead of "signal_pending()"
to avoid the waiting of bus idle to be terminated by general
signals except SIGKILL. After the change, i2c adapter can be
terminated by kill signal from user space with "CTRL+C" or
kill command operation.

Signed-off-by: Fugang Duan <B38611@freescale.com>
drivers/i2c/busses/i2c-imx.c