i2c: Unregister dummy devices last on adapter removal
commitd941e905c951364db60f5ad802c8730fc2526d1a
authorJean Delvare <khali@linux-fr.org>
Fri, 14 Jan 2011 21:03:49 +0000 (14 22:03 +0100)
committerAK <andi@firstfloor.org>
Thu, 31 Mar 2011 18:57:50 +0000 (31 11:57 -0700)
treefa103f99e395f7e7a0102c6310d4ef803035f9b6
parentc8ff6363cfcfe2192cc45c14bfda8b99431aa65f
i2c: Unregister dummy devices last on adapter removal

commit 5219bf884b6e2b54e734ca1799b6f0014bb2b4b7 upstream.

Remove real devices first and dummy devices last. This gives device
driver which instantiated dummy devices themselves a chance to clean
them up before we do.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
Tested-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/i2c/i2c-core.c