From: Pierre-Louis Bossart Date: Wed, 30 Sep 2020 15:20:24 +0000 (+0300) Subject: ASoC: SOF: topology: remove const in sizeof() X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=3381a989a92f12f401332f1c506465fff1a8870d;p=linux.git ASoC: SOF: topology: remove const in sizeof() We should only use the type, the const attribute makes no sense in sizeof(). Reported-by: Guennadi Liakhovetski Signed-off-by: Pierre-Louis Bossart Reviewed-by: Ranjani Sridharan Reviewed-by: Guennadi Liakhovetski Signed-off-by: Kai Vehmanen Acked-by: Jaroslav Kysela Tested-by: Jaroslav Kysela Link: https://lore.kernel.org/r/20200930152026.3902186-3-kai.vehmanen@linux.intel.com Signed-off-by: Mark Brown --- diff --git a/sound/soc/sof/topology.c b/sound/soc/sof/topology.c index 69313fbdb636..523a386fce4b 100644 --- a/sound/soc/sof/topology.c +++ b/sound/soc/sof/topology.c @@ -1201,7 +1201,7 @@ static int sof_control_load_bytes(struct snd_soc_component *scomp, ret = -EINVAL; goto out_free; } - if (cdata->data->size + sizeof(const struct sof_abi_hdr) != + if (cdata->data->size + sizeof(struct sof_abi_hdr) != le32_to_cpu(control->priv.size)) { dev_err(scomp->dev, "error: Conflict in bytes vs. priv size.\n");