Re: [PATCH 02/23] iio:adc:axp20x: Convert from OF to generic fw / device properties

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 28 Jun 2020 20:43:50 +0300
Andy Shevchenko <andy.shevchenko@xxxxxxxxx> wrote:

> On Sun, Jun 28, 2020 at 3:39 PM Jonathan Cameron <jic23@xxxxxxxxxx> wrote:
> 
> > Whilst fairly unlikely anyone will ever use this driver with anything
> > other than DT, we are trying to move IIO over to the generic interfaces
> > where easy to do so.
> >
> > In this case this involved moving to generic check on presence
> > of fw_node, generic device_get_match_data and dropping the of_match_ptr
> > protection.  Also relevant header changes to have property.h and
> > mod_devicetable.h only.  
> 
> ...
> 
> > -               info->data = (struct axp_data *)of_device_get_match_data(dev);
> > +               info->data = (struct axp_data *)device_get_match_data(dev);  
> 
> Casting is not needed, but if you remove it it reveals a hidden const
> qualifier drop.
> 

Doh.  I should have noticed the odd cast..

Will fix up.  Making info->data a const as well will tidy that up.

Thanks,

Jonathan




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux