Skip to content

Commit b868078

Browse files
mszyprowJean Delvare
authored andcommitted
i2c-gpio: Move initialization code to subsys_initcall()
GPIO driven I2C bus can be used for controlling the PMIC chip. The example of such configuration is Samsung Aquila board. This patch moves initialization code to subsys_initcall() to ensure that the i2c bus is available early so the regulators can be quickly probed and available for other devices on their probe() call. Such solution has been proposed by Mark Brown to fix the problem of the regulators not beeing available on the peripheral device probe(): http://lists.infradead.org/pipermail/linux-arm-kernel/2010-March/011971.html Cc: Mark Brown <broonie@opensource.wolfsonmicro.com> Reviewed-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com> Acked-by: Wolfram Sang <w.sang@pengutronix.de> Signed-off-by: Jean Delvare <khali@linux-fr.org>
1 parent bfdcad9 commit b868078

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎drivers/i2c/busses/i2c-gpio.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ static int __init i2c_gpio_init(void)
211211

212212
return ret;
213213
}
214-
module_init(i2c_gpio_init);
214+
subsys_initcall(i2c_gpio_init);
215215

216216
static void __exit i2c_gpio_exit(void)
217217
{

0 commit comments

Comments
 (0)