[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180920201833.2d2skjn7fkrbdsqx@valkosipuli.retiisi.org.uk>
Date: Thu, 20 Sep 2018 23:18:34 +0300
From: Sakari Ailus <sakari.ailus@....fi>
To: Laurent Pinchart <laurent.pinchart@...asonboard.com>
Cc: Ricardo Ribalda Delgado <ricardo.ribalda@...il.com>,
Pavel Machek <pavel@....cz>,
Mauro Carvalho Chehab <mchehab@...nel.org>,
linux-media@...r.kernel.org, linux-kernel@...r.kernel.org,
Hans Verkuil <hans.verkuil@...co.com>
Subject: Re: [PATCH v2 4/4] [media] ad5820: Add support for of-autoload
Hi Laurent,
On Thu, Sep 20, 2018 at 11:10:23PM +0300, Laurent Pinchart wrote:
> > +MODULE_DEVICE_TABLE(of, ad5820_of_table);
> > +
> > static SIMPLE_DEV_PM_OPS(ad5820_pm, ad5820_suspend, ad5820_resume);
> >
> > static struct i2c_driver ad5820_i2c_driver = {
> > .driver = {
> > .name = AD5820_NAME,
> > .pm = &ad5820_pm,
> > + .of_match_table = ad5820_of_table,
>
> As the driver doesn't depend on CONFIG_OF, would it make sense to use
> of_config_ptr() (and to compile the of table conditionally on CONFIG_OF) ?
You get ACPI support as a bonus if you don't use of_config_ptr(). :-) Other
changes could be needed but this enables probing the driver for a device.
In this case the probability of anyone using this device on an ACPI system
could be pretty low though.
--
Regards,
Sakari Ailus
e-mail: sakari.ailus@....fi
Powered by blists - more mailing lists