Re: [PATCH] ide: falconide: convert to platform driver

Michael Schmitz
2019-11-05T20:03:05Z

Hi Geert,

On Wed, Nov 6, 2019 at 7:46 AM Geert Uytterhoeven <geert@linux-m68k.org> wrote:
>
> > > > @@ -169,10 +177,21 @@ static int __init falconide_init(void)
> >
> > Should I remove the __init here? Doesn't hurt in the built-in use
> > case, what about use as a module?
>
> Should be fine.

OK, I'll leave it.

>
> >
> > > > err_free:
> > > > ide_host_free(host);
> > > > err:
> > > > - release_mem_region(ATA_HD_BASE, 0x40);
> > > > + release_mem_region(res->start, resource_size(res));
> > > > return rc;
> > > > }
> > > >
> > > > -module_init(falconide_init);
> > > > +static struct platform_driver ide_falcon_driver = {
> > > > + .driver = {
> > > > + .name = "atari-falcon-ide",
> > > > + },
> > > > +};
> > >
> > > Missing .remove() callback.
> >
> > Can't easily test driver remove, but I can certainly add a callback for that.
> >
> > ide_unregister does the Right Thing (i.e. leaves the ST-DMA interrupt
> > registered) so no reason why it shouldn't work.
>
> gayle.c uses ide_host_remove().

I'm using that, too. But ide_host_remove() is not where free_irq() is called.

>
> > > > +
> > > > +module_platform_driver_probe(ide_falcon_driver, falconide_init);
> > > > +
> > > >
> > > > +MODULE_AUTHOR("Geert Uytterhoeven");
> > > > +MODULE_DESCRIPTION("low-level driver for Atari Falcon IDE");
> > > > MODULE_LICENSE("GPL");
> > > > +MODULE_ALIAS("platform:atari-falcon-ide");
> > > > +MODULE_VERSION(DRV_VERSION);
> > >
> > > I'd drop the MODULE_VERSION().
> >
> > Done.
> >
> > Shall I merge this one with part one of the old series so there's no
> > chance of a bisection going wrong?
>
> Yes please.
> Thanks!

Thanks, I'll send a new version shortly.

Cheers,

Michael