Message ID | 20220413092454.1073-1-tzimmermann@suse.de |
---|---|
Headers | show |
Series | of: Register platform device for each framebuffer | expand |
Hi Am 13.04.22 um 14:51 schrieb Rob Herring: ... >> + >> /** >> * of_platform_populate() - Populate platform_devices from device tree data >> * @root: parent of the first level to probe or NULL for the root of the tree >> @@ -541,9 +595,7 @@ static int __init of_platform_default_populate_init(void) >> of_node_put(node); >> } >> >> - node = of_get_compatible_child(of_chosen, "simple-framebuffer"); >> - of_platform_device_create(node, NULL, NULL); >> - of_node_put(node); >> + of_platform_populate_framebuffers(); >> >> /* Populate everything else. */ >> of_platform_default_populate(NULL, NULL, NULL); > > I'm pretty sure it's just this call that's the problem for PPC though > none of the above existed when adding this caused a regression. Can we > remove the ifdef and just make this call conditional on > !IS_ENABLED(CONFIG_PPC). That didn't work. The boot process stops at some point. I'll send you an updated patch that covers most of the function with IS_ENABLED(CONFIG_PPC) Best regards Thomas > > >> @@ -551,6 +603,20 @@ static int __init of_platform_default_populate_init(void) >> return 0; >> } >> arch_initcall_sync(of_platform_default_populate_init); >> +#else >> +static int __init of_platform_default_populate_init(void) >> +{ >> + device_links_supplier_sync_state_pause(); >> + >> + if (!of_have_populated_dt()) >> + return -ENODEV; >> + >> + of_platform_populate_framebuffers(); >> + >> + return 0; >> +} >> +arch_initcall_sync(of_platform_default_populate_init); >> +#endif >> >> static int __init of_platform_sync_state_init(void) >> { >> @@ -558,7 +624,6 @@ static int __init of_platform_sync_state_init(void) >> return 0; >> } >> late_initcall_sync(of_platform_sync_state_init); >> -#endif >> >> int of_platform_device_destroy(struct device *dev, void *data) >> {