Re: [PATCH v9 08/24] wfx: add bus_sdio.c

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

 



On Wednesday 12 January 2022 11:58:59 CET Pali Rohár wrote:
> On Tuesday 11 January 2022 18:14:08 Jerome Pouiller wrote:
> > +static const struct sdio_device_id wfx_sdio_ids[] = {
> > +     { SDIO_DEVICE(SDIO_VENDOR_ID_SILABS, SDIO_DEVICE_ID_SILABS_WF200) },
> > +     { },
> > +};
> 
> Hello! Is this table still required?

As far as I understand, if the driver does not provide an id_table, the
probe function won't be never called (see sdio_match_device()).

Since, we rely on the device tree, we could replace SDIO_VENDOR_ID_SILABS
and SDIO_DEVICE_ID_SILABS_WF200 by SDIO_ANY_ID. However, it does not hurt
to add an extra filter here.

> > +MODULE_DEVICE_TABLE(sdio, wfx_sdio_ids);
> > +
> > +struct sdio_driver wfx_sdio_driver = {
> > +     .name = "wfx-sdio",
> > +     .id_table = wfx_sdio_ids,
> > +     .probe = wfx_sdio_probe,
> > +     .remove = wfx_sdio_remove,
> > +     .drv = {
> > +             .owner = THIS_MODULE,
> > +             .of_match_table = wfx_sdio_of_match,
> > +     }
> > +};
> > --
> > 2.34.1
> >
> 


-- 
Jérôme Pouiller







[Index of Archives]     [Linux Memonry Technology]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux