[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZADE7kBB9HzTlpul@smile.fi.intel.com>
Date: Thu, 2 Mar 2023 17:46:54 +0200
From: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
To: Henning Schild <henning.schild@...mens.com>
Cc: Pavel Machek <pavel@....cz>, Lee Jones <lee@...nel.org>,
Hans de Goede <hdegoede@...hat.com>,
Mark Gross <markgross@...nel.org>,
linux-kernel@...r.kernel.org, linux-leds@...r.kernel.org,
platform-driver-x86@...r.kernel.org
Subject: Re: [PATCH v2 2/3] leds: simatic-ipc-leds-gpio: split up into
multiple drivers
On Thu, Mar 02, 2023 at 09:40:09AM +0100, Henning Schild wrote:
> Am Wed, 1 Mar 2023 19:28:12 +0200
> schrieb Andy Shevchenko <andriy.shevchenko@...ux.intel.com>:
> > On Wed, Mar 01, 2023 at 06:02:14PM +0100, Henning Schild wrote:
...
> > > + .driver = {
> > > + .name = KBUILD_MODNAME,
> >
> > Strictly speaking this is an ABI (as something may instantiate the
> > driver from the user space or elsewhere by this name. At the same
> > time this may change with the file name change.
> >
> > Personally I prefer explicit string literal here.
>
> Switching from one module to three the names have to change. People who
> explicitly loaded the old module which supported multiple machines,
> will now how to load either both oŕ know which one to load.
Wait, are you telling that now users load modules _manually_?!
> I personally think the ABI change is acceptable, the assumption would
> be that the drivers load automatically anyhow. And since there are no
> params i doubt users will have /etc/modprobe.d/ or /sys/module/ stuff
> around.
>
> And with the split i guess an ABI change can not be fully avoided.
> Whether the names is explicit or implicit is another discussion and
> just a matter of style. I prefer to stay with the currently used
> pattern, it is not un-common in the kernel.
The problem with that pattern is possible, while unlikely, renaming of the file
which triggers this to be updated.
Under sysfs the folder will change its name. If user has a script relying on
this, it will be broken. So, I prefer mine.
> > > + },
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists