Skip to content

Commit 3ec7129

Browse files
ujfalusibroonie
authored andcommitted
ASoC: Intel: bxt_rt298: Fix kernel ops due to COMP_DUMMY change
The change to avoid dummy components will leave the component name and dai_name NULL which will cause NULL dereference when trying to access to it in the machine driver when applying fixups. Link: thesofproject/linux#4759 (comment) Fixes: 13f5826 ("ASoC: soc.h: don't create dummy Component via COMP_DUMMY()") Signed-off-by: Peter Ujfalusi <[email protected]> Reviewed-by: Bard Liao <[email protected]> Reviewed-by: Pierre-Louis Bossart <[email protected]> Link: https://msgid.link/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
1 parent 59b946e commit 3ec7129

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

sound/soc/intel/boards/bxt_rt298.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -604,7 +604,8 @@ static int broxton_audio_probe(struct platform_device *pdev)
604604
int i;
605605

606606
for (i = 0; i < ARRAY_SIZE(broxton_rt298_dais); i++) {
607-
if (!strncmp(card->dai_link[i].codecs->name, "i2c-INT343A:00",
607+
if (card->dai_link[i].codecs->name &&
608+
!strncmp(card->dai_link[i].codecs->name, "i2c-INT343A:00",
608609
I2C_NAME_SIZE)) {
609610
if (!strncmp(card->name, "broxton-rt298",
610611
PLATFORM_NAME_SIZE)) {

0 commit comments

Comments
 (0)