Skip to contentSkip to conversation

question on snd_power_change_state()

DISCUSSION Oliver Neukum 3 participants 8 messages Mar 11, 2011

lore
Share & tools
lore
#0 lore raw

Hi,

will calling snd_power_change_state() reset all mixer settings?

Regards
Oliver

#1 lore raw

At Fri, 11 Mar 2011 13:12:17 +0100,

Quoted 4 lines · Oliver Neukum

Hi,

will calling snd_power_change_state() reset all mixer settings?

No, it's a simple inline function defined in include/sound/core.h.

static inline void snd_power_change_state(struct snd_card *card, unsigned int state)

{
	card->power_state = state;
	wake_up(&card->power_sleep);
}

It's present mostly for historical reasons.

Takashi

#2 lore raw

Am Freitag, 11. März 2011, 13:15:28 schrieb Takashi Iwai:

Quoted 9 lines

At Fri, 11 Mar 2011 13:12:17 +0100,

Quoted 4 lines · Oliver Neukum

Hi,

will calling snd_power_change_state() reset all mixer settings?

No, it's a simple inline function defined in include/sound/core.h.

Quoted 7 lines

static inline void snd_power_change_state(struct snd_card *card, unsigned int state)

{
	card->power_state = state;
	wake_up(&card->power_sleep);
}

It's present mostly for historical reasons.

Is there a helper that will do that?

Regards
Oliver

#3 lore raw

At Fri, 11 Mar 2011 13:20:46 +0100,

Quoted 17 lines · Oliver Neukum

Am Freitag, 11. März 2011, 13:15:28 schrieb Takashi Iwai:

Quoted 15 lines

At Fri, 11 Mar 2011 13:12:17 +0100,

Quoted 4 lines · Oliver Neukum

Hi,

will calling snd_power_change_state() reset all mixer settings?

No, it's a simple inline function defined in include/sound/core.h.

static inline void snd_power_change_state(struct snd_card *card, unsigned int state)

{
	card->power_state = state;
	wake_up(&card->power_sleep);
}
Quoted 3 lines
Quoted 1 line

It's present mostly for historical reasons.

Is there a helper that will do that?

A helper for what?

Takashi
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

#4 lore raw

Am Freitag, 11. März 2011, 13:34:17 schrieb Takashi Iwai:

Quoted 19 lines

At Fri, 11 Mar 2011 13:20:46 +0100,

Quoted 17 lines · Oliver Neukum

Am Freitag, 11. März 2011, 13:15:28 schrieb Takashi Iwai:

Quoted 15 lines

At Fri, 11 Mar 2011 13:12:17 +0100,

Quoted 4 lines · Oliver Neukum

Hi,

will calling snd_power_change_state() reset all mixer settings?

No, it's a simple inline function defined in include/sound/core.h.

static inline void snd_power_change_state(struct snd_card *card, unsigned int state)

{
	card->power_state = state;
	wake_up(&card->power_sleep);
}
Quoted 5 lines
Quoted 3 lines
Quoted 1 line

It's present mostly for historical reasons.

Is there a helper that will do that?

A helper for what?

A helper for restoring all mixer settings that a device has lost due to a loss of power.

Regards
Oliver
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

#5 lore raw

At Fri, 11 Mar 2011 13:42:44 +0100,

Quoted 21 lines · Oliver Neukum

Am Freitag, 11. März 2011, 13:34:17 schrieb Takashi Iwai:

Quoted 19 lines

At Fri, 11 Mar 2011 13:20:46 +0100,

Quoted 17 lines · Oliver Neukum

Am Freitag, 11. März 2011, 13:15:28 schrieb Takashi Iwai:

Quoted 15 lines

At Fri, 11 Mar 2011 13:12:17 +0100,

Quoted 4 lines · Oliver Neukum

Hi,

will calling snd_power_change_state() reset all mixer settings?

No, it's a simple inline function defined in include/sound/core.h.

static inline void snd_power_change_state(struct snd_card *card, unsigned int state)

{
	card->power_state = state;
	wake_up(&card->power_sleep);
}
Quoted 8 lines
Quoted 5 lines
Quoted 3 lines
Quoted 1 line

It's present mostly for historical reasons.

Is there a helper that will do that?

A helper for what?

A helper for restoring all mixer settings that a device has lost due to a loss of power.

No. It's driver-specific.

Takashi
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

#6 lore raw
Quoted 6 lines · Takashi Iwai
Quoted 2 lines · Oliver Neukum

A helper for restoring all mixer settings that a device has lost due to a loss of power.

No. It's driver-specific.

If you're working within ASoC the register cache code has support for syncing back to hardware.

#7 lore raw

At Fri, 11 Mar 2011 13:53:13 +0000,

Quoted 11 lines · Mark Brown
Quoted 6 lines · Takashi Iwai
Quoted 2 lines · Oliver Neukum

A helper for restoring all mixer settings that a device has lost due to a loss of power.

No. It's driver-specific.

If you're working within ASoC the register cache code has support for syncing back to hardware.

Right.

But usb-audio has no register (not only it doesn't using ASoC :)

Takashi