ASoC driver names

Mark Brown broonie at kernel.org
Fri Apr 24 18:49:44 CEST 2020


On Fri, Apr 24, 2020 at 10:52:38AM +0200, Jaroslav Kysela wrote:
> Dne 23. 04. 20 v 20:40 Mark Brown napsal(a):

> > My instinct is that the machine driver name is being used as a
> > proxy for something else here and that if we need to change the ABI
> > perhaps we need to extend it rather than trying to shoehorn things into
> > what's there.

> My point is that this information is duplicated in the sense, that we have
> three fields with the similar contents passed from the audio driver by the
> ASoC drivers whose set only snd_soc_card->name from the device tree.

> For generic drivers: They can pass a generic driver name (like 'ASoC
> Simple') for the simple card driver (soc/generic/simple-card.c).

> So my proposal is to change the driver_name to the right contents (it was
> the initial intention for this field - changed somehow for ASoC). An
> information about the used driver which is independent on the real
> configuration (device tree, ACPI, component enumeration etc.). In other
> words, the name should be more close to the source (top-level driver) code
> name than the hardware configuration.

So if it's not really going to be used for anything particularly
concrete then I'm having a hard time summoning the enthusiasm for a
change.  It feels more like a neatness thing than anything else and the
postitive case just isn't jumping out at me, certainly not as a thing to
force for everything.  New stuff, sure.  I guess I'm not bothered enough
to block any platform that has a burning desire to convert either though
if users start coming and complaining about kernel upgrades breaking
things we'd have to revert.

> I would prefer to have the sound hardware description in the long name field
> than the whole hardware platform info here, too.

Does it also cope with the DT equivalents (and I guess there's nothing
we can do for board file based systems)?  This stuff does get used for
embedded systems where the plastics are often important for the
configuration.

BTW I think the reason why we're putting the board name in as the driver
name is that historically there used to be pretty much one machine
driver per board, I can't remember if they were just always taken from
the same place or if someone noticed duplicate strings all over the
place and removed the duplication.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20200424/cc4ac50d/attachment.sig>


More information about the Alsa-devel mailing list