Skip to content

Commit dc6e08b

Browse files
harshimogalapallitiwai
authored andcommitted
ALSA: hda: cs35l41: Fix missing error code in cs35l41_smart_amp()
When firmware status is invalid, assign -EINVAL to ret as ret is '0' at that point and returning success is incorrect when firmware status is invalid. Fixes: a51d8ba ("ALSA: hda: cs35l41: Check CSPL state after loading firmware") Signed-off-by: Harshit Mogalapalli <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Takashi Iwai <[email protected]>
1 parent 2dc15ff commit dc6e08b

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

sound/pci/hda/cs35l41_hda.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1042,6 +1042,7 @@ static int cs35l41_smart_amp(struct cs35l41_hda *cs35l41)
10421042
default:
10431043
dev_err(cs35l41->dev, "Firmware status is invalid: %u\n",
10441044
fw_status);
1045+
ret = -EINVAL;
10451046
goto clean_dsp;
10461047
}
10471048

0 commit comments

Comments
 (0)