[PATCH] i2c: Prevent deadlock on i2c client registration
authorJean Delvare <khali@linux-fr.org>
Sat, 30 Sep 2006 15:18:59 +0000 (17:18 +0200)
committerLinus Torvalds <torvalds@g5.osdl.org>
Sat, 30 Sep 2006 17:58:47 +0000 (10:58 -0700)
Delay the call to adapter->client_register() until after we are
certain that the client registration is a success. At this point the
client is fully initialized and we no longer hold the adapter->clist
mutex, so this should prevent the deadlocks if the client_register()
callback needs to take that mutex too, as is the case for the bttv
driver.

This fixes bug #7234.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>

No differences found