From mboxrd@z Thu Jan 1 00:00:00 1970 From: Takashi Iwai Subject: Re: [patch] for 9880 spdif out Date: Thu, 17 Mar 2005 12:41:24 +0100 Message-ID: References: <92C0412E07F63549B2A2F2345D3DB515F7D69F@cm-msg-02.cmedia.com.tw> Mime-Version: 1.0 (generated by SEMI 1.14.5 - "Awara-Onsen") Content-Type: text/plain; charset=US-ASCII Received: from Cantor.suse.de (mail.suse.de [195.135.220.2]) by alsa.alsa-project.org (ALSA's E-mail Delivery System) with ESMTP id 32660239 for ; Thu, 17 Mar 2005 12:41:30 +0100 (MET) In-Reply-To: <92C0412E07F63549B2A2F2345D3DB515F7D69F@cm-msg-02.cmedia.com.tw> Sender: alsa-devel-admin@lists.sourceforge.net Errors-To: alsa-devel-admin@lists.sourceforge.net List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , List-Archive: To: "Tien, C.L." Cc: alsa-devel@alsa-project.org List-Id: alsa-devel@alsa-project.org At Thu, 17 Mar 2005 12:48:16 +0800, Tien, C.L. wrote: > > Hi, > > There is mute control on 9880's spdif (IEC958) out, so it needs to > be turned on/off in mixer. > The patch is for CVS version and I think it can be patched to azx > too. Hope this also fix the 9880 SPDIF-out bug. Thanks for the patch. This explains why this bug occured only on CMI9880. > --- alsa-kernel/pci/hda/hda_codec.c 16 Mar 2005 13:37:09 -0000 1.7 > +++ alsa-kernel/pci/hda/hda_codec.c 17 Mar 2005 04:40:12 -0000 > @@ -955,6 +955,8 @@ > if (change || codec->in_resume) { > codec->spdif_ctls = val; > snd_hda_codec_write(codec, nid, 0, AC_VERB_SET_DIGI_CONVERT_1, val & 0xff); > + put_vol_mute(codec, nid, 0, HDA_OUTPUT, 0, val ? 0 : 0x80); > + put_vol_mute(codec, nid, 1, HDA_OUTPUT, 0, val ? 0 : 0x80); It should check only the enable bit (bit0) of val. Also, these two calls can be a single verb, e.g. snd_hda_codec_write(codec, nid, 0, AC_VERB_SET_AMP_GAIN_MUTE, AC_AMP_SET_LEFT|AC_AMP_SET_RIGHT|AC_AMP_SET_OUTPUT| ((val & 1) ? 0 : 0x80)); Could you check whether this works? Takashi ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click