Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1608778
| From | Brian Norris <briannorris@chromium.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 5/5] firmware: google memconsole: Add ARM/ARM64 support |
| Date | 2017-03-24 19:10 +0100 |
| Message-ID | <toBOY-5jj-81@gated-at.bofh.it> (permalink) |
| References | <toi9A-84L-13@gated-at.bofh.it> <toi9A-84L-19@gated-at.bofh.it> <towvU-1tO-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Fri, Mar 24, 2017 at 12:28:59PM +0000, Mark Rutland wrote:
> On Thu, Mar 23, 2017 at 10:04:29PM +0100, Thierry Escande wrote:
> > +static const struct of_device_id coreboot_of_match[] = {
> > + { .compatible = "coreboot" },
> > + {},
> > +};
> > +
> > +static struct platform_driver coreboot_table_of_driver = {
> > + .probe = coreboot_table_of_probe,
> > + .remove = coreboot_table_of_remove,
> > + .driver = {
> > + .name = "coreboot_table_of",
> > + .of_match_table = coreboot_of_match,
> > + },
> > +};
> > +
> > +static int __init platform_coreboot_table_of_init(void)
> > +{
> > + struct platform_device *pdev;
> > + struct device_node *of_node;
> > +
> > + /* Limit device creation to the presence of /firmware/coreboot node */
> > + of_node = of_find_node_by_path("/firmware/coreboot");
> > + if (!of_node)
> > + return -ENODEV;
> > +
>
> I don't beleive that you need this module init function. Please use the
> usual DT probing infrastrucutre instead, e.g. add:
>
> MODULE_DEVICE_TABLE(of, coreboot_of_match);
> module_platform_driver(coreboot_table_of_driver);
That doesn't work. If this node is placed under /firmware, which isn't a
proper "bus", then we have to explicitly look for the sub-device.
Due to this, the MODULE_DEVICE_TABLE() also isn't useful, because the
/firmware/coreboot/ device won't be generated automatically, and so no
matching uevent will occur.
Brian
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 0/5] firmware: google memconsole Thierry Escande <thierry.escande@collabora.com> - 2017-03-23 22:10 +0100
[PATCH 4/5] firmware: Add coreboot device tree binding documentation Thierry Escande <thierry.escande@collabora.com> - 2017-03-23 22:10 +0100
Re: [PATCH 4/5] firmware: Add coreboot device tree binding documentation Mark Rutland <mark.rutland@arm.com> - 2017-03-24 13:30 +0100
Re: [PATCH 4/5] firmware: Add coreboot device tree binding documentation Brian Norris <briannorris@chromium.org> - 2017-03-24 19:00 +0100
Re: [PATCH 4/5] firmware: Add coreboot device tree binding documentation Julius Werner <jwerner@chromium.org> - 2017-03-24 20:40 +0100
[PATCH 5/5] firmware: google memconsole: Add ARM/ARM64 support Thierry Escande <thierry.escande@collabora.com> - 2017-03-23 22:10 +0100
Re: [PATCH 5/5] firmware: google memconsole: Add ARM/ARM64 support Mark Rutland <mark.rutland@arm.com> - 2017-03-24 13:30 +0100
Re: [PATCH 5/5] firmware: google memconsole: Add ARM/ARM64 support Brian Norris <briannorris@chromium.org> - 2017-03-24 19:10 +0100
Re: [PATCH 5/5] firmware: google memconsole: Add ARM/ARM64 support Julius Werner <jwerner@chromium.org> - 2017-03-24 21:00 +0100
Re: [PATCH 5/5] firmware: google memconsole: Add ARM/ARM64 support Brian Norris <briannorris@chromium.org> - 2017-03-27 19:00 +0200
[PATCH 3/5] firmware: google memconsole: Add coreboot support Thierry Escande <thierry.escande@collabora.com> - 2017-03-23 22:10 +0100
[PATCH 1/5] firmware: google memconsole: Remove useless submenu in Kconfig Thierry Escande <thierry.escande@collabora.com> - 2017-03-23 22:10 +0100
csiph-web