* [PATCH 1/1] ALSA: isa: Fix error return code in snd_cmi8330_probe()
@ 2021-07-07 7:40 Zhen Lei
2021-07-07 11:26 ` Takashi Iwai
0 siblings, 1 reply; 2+ messages in thread
From: Zhen Lei @ 2021-07-07 7:40 UTC (permalink / raw)
To: Jaroslav Kysela, Takashi Iwai, alsa-devel, linux-kernel; +Cc: Zhen Lei
When 'SB_HW_16' check fails, the error code -ENODEV instead of 0 should be
returned, which is the same as that returned when 'WSS_HW_CMI8330' check
fails.
Fixes: 43bcd973d6d0 ("[ALSA] Add snd_card_set_generic_dev() call to ISA drivers")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>
---
sound/isa/cmi8330.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/isa/cmi8330.c b/sound/isa/cmi8330.c
index 6c59a3eec59b..ef6d0a20efd8 100644
--- a/sound/isa/cmi8330.c
+++ b/sound/isa/cmi8330.c
@@ -551,7 +551,7 @@ static int snd_cmi8330_probe(struct snd_card *card, int dev)
}
if (acard->sb->hardware != SB_HW_16) {
snd_printk(KERN_ERR PFX "SB16 not found during probe\n");
- return err;
+ return -ENODEV;
}
snd_wss_out(acard->wss, CS4231_MISC_INFO, 0x40); /* switch on MODE2 */
--
2.25.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH 1/1] ALSA: isa: Fix error return code in snd_cmi8330_probe()
2021-07-07 7:40 [PATCH 1/1] ALSA: isa: Fix error return code in snd_cmi8330_probe() Zhen Lei
@ 2021-07-07 11:26 ` Takashi Iwai
0 siblings, 0 replies; 2+ messages in thread
From: Takashi Iwai @ 2021-07-07 11:26 UTC (permalink / raw)
To: Zhen Lei; +Cc: Jaroslav Kysela, Takashi Iwai, alsa-devel, linux-kernel
On Wed, 07 Jul 2021 09:40:51 +0200,
Zhen Lei wrote:
>
> When 'SB_HW_16' check fails, the error code -ENODEV instead of 0 should be
> returned, which is the same as that returned when 'WSS_HW_CMI8330' check
> fails.
>
> Fixes: 43bcd973d6d0 ("[ALSA] Add snd_card_set_generic_dev() call to ISA drivers")
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: Zhen Lei <thunder.leizhen@huawei.com>
Thanks, applied.
Takashi
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-07-07 11:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-07 7:40 [PATCH 1/1] ALSA: isa: Fix error return code in snd_cmi8330_probe() Zhen Lei
2021-07-07 11:26 ` Takashi Iwai
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®