4 Feb
2019
4 Feb
'19
9:31 p.m.
On Mon, 04 Feb 2019 21:27:10 +0100, Pierre-Louis Bossart wrote:
static void dapm_assert_locked(struct snd_soc_dapm_context *dapm) @@ -1425,11 +1425,22 @@ static int dapm_seq_compare(struct snd_soc_dapm_widget *a, { int *sort;
- WARN_ONCE(ARRAY_SIZE(dapm_up_seq) != SND_SOC_DAPM_TYPE_LAST,
"bad size for dapm_up_seq, expected %d\n",
SND_SOC_DAPM_TYPE_LAST);
- WARN_ONCE(ARRAY_SIZE(dapm_down_seq) != SND_SOC_DAPM_TYPE_LAST,
"bad size for dapm_down_seq, expected %d\n",
SND_SOC_DAPM_TYPE_LAST);
Would BUILD_BUG_ON() work for these instead? It's not available, but if it works, better than the runtime check.
thanks,
Takashi