On Sunday, 27 September 2015 13:37:01 UTC+1, Clive Messer wrote: > > On Sun, 2015-09-27 at 12:37 +0200, Hans de Goede wrote: > > > This is likely a problem with your kernel config, make sure that > > you've the axp209 mfd and regulator drivers enabled and loaded. > > Thanks, Hans. I really should have figured that out on my own! > > Do you think it's worth asking PeterR if he will change the default > Fedora armv7 config to CONFIG_REGULATOR_AXP20X=y rather than the > current CONFIG_REGULATOR_AXP20X=m? (I suspect that request might > carry more weight if it comes from you rather than me. ;) >
Hans, Do you have an opinion, (or anyone else for that matter), on what would be the upstream preferred way of getting the axp20x regulator driver to auto-load, from a DT reference, assuming it is built as a module? Something like the attached patch? (Not tested, just thinking out loud.) Regards Clive -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
--- a/drivers/regulator/axp20x-regulator.c 2015-09-27 20:45:59.476111129 +0100 +++ b/drivers/regulator/axp20x-regulator.c 2015-09-27 20:50:59.309998456 +0100 @@ -393,10 +393,17 @@ return 0; } +static const struct of_device_id of_axp20x_regulator_match_tbl[] = { + { .compatible = "x-powers,axp209", }, + { /* end */ } +}; +MODULE_DEVICE_TABLE(of, of_axp20x_regulator_match_tbl); + static struct platform_driver axp20x_regulator_driver = { .probe = axp20x_regulator_probe, .driver = { .name = "axp20x-regulator", + .of_match_table = of_axp20x_regulator_match_tbl, }, };