Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: Robin Gareus <robin@gareus.org>
Cc: Adam Goode <adam@spicenitz.org>,
	alsa-devel@alsa-project.org,
	Chris J Arges <chris.j.arges@canonical.com>
Subject: Re: Scarlett 18i8 hardware out of sync with AlsaMixer
Date: Fri, 19 Jun 2015 13:34:50 +0200	[thread overview]
Message-ID: <s5hlhfg9bj9.wl-tiwai@suse.de> (raw)
In-Reply-To: <557CB6CE.4090702@gareus.org>

At Sun, 14 Jun 2015 01:03:42 +0200,
Robin Gareus wrote:
> 
> On 06/10/2015 06:24 AM, Adam Goode wrote:
> [..]
> > My guess is that the ALSA mixer settings are cached too soon, before
> > the device itself internally overwrites the settings from NVRAM. We
> > are either missing some invalidation event from the device itself, or
> > we don't do the right thing during initialization.
> 
> I didn't follow the whole discussion, so please excuse me if this was
> mentioned before:
> 
> I'm pretty sure that the NVRAM is restored on the Scarlet before the
> device shows up on USB: Save a config with Hi-Z on but configuring it as
> off in software. When connecting & re-powering the device, the indicator
> LED will blink on and then go off.
> 
> 
> It is not possible to read the full state from the device itself.
> Trying to read the value from the device results in garbage for the most
> part. The values must be set by ALSA and ALSA must remember the state.
> That worked in the original alsa mixer even across suspend/resume for
> the 18i6. Either something was changed or has been lost since.
> 
> This is also how the OSX and Windows drivers work for the Scarlett
> series. As soon as the device is [re]connected, software pushes the last
> known state (on that given machine) to the device. (At least it was that
> way ~2 years ago when I reverse engineered it).

OK, then the initial values seem missing.  The driver has already
cache in it, so the suspend/resume should work as is now.  The only
the initial values have to be set up explicitly.

> BTW the prop. driver saves state to the NVRAM quite often. I don't know
> if this is a marketing trick (intentionally wear it out quickly) or if
> it's OK to do that.

We have a control already in user-space (simple "alsactl restore"
should do), so there is no big merit to do it in the driver level,
IMO.


thanks,

Takashi

      reply	other threads:[~2015-06-19 11:34 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-27  1:39 Scarlett 18i8 hardware out of sync with AlsaMixer Adam Goode
2015-05-27  6:43 ` Takashi Iwai
2015-05-27 12:55   ` Adam Goode
2015-05-27 13:24     ` Takashi Iwai
2015-05-27 13:37       ` Adam Goode
2015-05-27 13:53       ` Chris J Arges
2015-06-09 21:44         ` Adam Goode
2015-06-10  4:24         ` Adam Goode
2015-06-13 23:03           ` Robin Gareus
2015-06-19 11:34             ` Takashi Iwai [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=s5hlhfg9bj9.wl-tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=adam@spicenitz.org \
    --cc=alsa-devel@alsa-project.org \
    --cc=chris.j.arges@canonical.com \
    --cc=robin@gareus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox