[PATCH 00/14] ASoC: Constify local snd_sof_dsp_ops

Pierre-Louis Bossart pierre-louis.bossart at linux.intel.com
Mon Apr 15 07:19:21 PDT 2024


> The core code does not modify the 'struct snd_sof_dsp_ops' passed via
> pointer in various places, so this can be made pointer to const.

The structure itself is NOT always const - the initialization itself
does have platform-specific changes, so what do we really gain from all
this?

some commit messages say the code is "a bit safer", but I personally
find the 'const' more confusing since the information that the structure
can be modified during initialization is lost.




More information about the linux-arm-kernel mailing list