Skip to contentSkip to conversation

Remove duplicate snd_card_set_dev().

PATCH Applied Joachim Foerster 2 participants 2 messages Mar 15, 2008 – Mar 17, 2008 Sound

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Remove duplicate snd_card_set_dev().

Hi Takashi,

I noticed, that there was a change in ml403-ac97cr.c, which introduces a second call of snd_card_set_dev() in the _probe()-function. The "original" one is in the snd_ml403_ac97cr_create()-function.

According the other changes, I guess, we want to have it in the _probe()-function, now (=> following patch)?

From: Joachim Foerster <[email protected]>

We want to have snd_card_set_dev() in _probe(), but not a second one in snd_ml403_ac97cr_create().

---
 sound/drivers/ml403-ac97cr.c |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)
sound/drivers/ml403-ac97cr.c +0 -2
index 05a871a..b654007 100644
@@ -1191,8 +1191,6 @@ snd_ml403_ac97cr_create(struct snd_card *card, struct platform_device *pfdev,
 		return err;
 	}
 
-	snd_card_set_dev(card, &pfdev->dev);
-
 	*rml403_ac97cr = ml403_ac97cr;
 	return 0;
 }
Signature · 1 line
1.5.4.3
Applied
#1 lore raw

At Sat, 15 Mar 2008 10:43:09 +0100,

Quoted 9 lines · Joachim Foerster

Hi Takashi,

I noticed, that there was a change in ml403-ac97cr.c, which introduces a second call of snd_card_set_dev() in the _probe()-function. The "original" one is in the snd_ml403_ac97cr_create()-function.

According the other changes, I guess, we want to have it in the _probe()-function, now (=> following patch)?

It's no big matter whether it's set. The only requirement is that it must be called before registering the device, typically via snd_card_register().

Quoted 6 lines

From: Joachim Foerster <[email protected]>

We want to have snd_card_set_dev() in _probe(), but not a second one in snd_ml403_ac97cr_create().

Applied to ALSA tree. Thanks.

Takashi