From mboxrd@z Thu Jan 1 00:00:00 1970 From: Takashi Iwai Subject: Re: ATI IXP Modem driver Date: Wed, 28 Jul 2004 18:26:25 +0200 Sender: alsa-devel-admin@lists.sourceforge.net Message-ID: References: <1083465072.1639.8.camel@server.gowanlea.net> <20040503163657.668357a9@sashak.lan> <1087962001.4844.0.camel@server.gowanlea.net> <20040711191833.462a0b4b@sashak.lan> <20040712162839.2c58e1c3@sashak.lan> <20040712195450.04494434@sashak.lan> <20040725182154.3317e5d8@sashak.lan> Mime-Version: 1.0 (generated by SEMI 1.14.5 - "Awara-Onsen") Content-Type: text/plain; charset=US-ASCII Return-path: In-Reply-To: <20040725182154.3317e5d8@sashak.lan> Errors-To: alsa-devel-admin@lists.sourceforge.net List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , List-Archive: To: Sasha Khapyorsky Cc: unixtricks@btinternet.com, alsa-devel@lists.sourceforge.net, Antonis Tsolomitis , Jacques Goldberg List-Id: alsa-devel@alsa-project.org At Sun, 25 Jul 2004 18:21:54 +0300, Sasha Khapyorsky wrote: > > [1 ] > Hello Takashi, > > On Mon, 12 Jul 2004 18:57:30 +0200 > Takashi Iwai wrote: > > > > > The change is already on CVS. > > Additional 'atiixp_modem' patch (I cannot upload it to bug#0000259 - it > is fixed already) > > The problem was reported at discuss@linmodems.org (and looks like one > that was with intel8x0m in the past) - When modem driver probes codecs > for mixer it mutes all sound devices. > > Solution is same as with 'intel8x0m' - to allocate mixer only for modem > codec(MC). The approach is that MC is always last one. This will work > with one and two codecs configurations. Not sure about three codecs (are > there such in practice?), but if 'not' it would be simply fixed by valid > 'codec_num' setup. Well, this will be still a problem when the audio driver is loaded after the modem driver. We'll need a way to avoid the double reset on codecs. How about adding a new flag to ac97 struct to indicate the shared chip type? ac97_codec.c holds a static array, such as static ac97_t *ac97_shared_codec[AC97_NUM_SHARED_CHIPS][4]; and when ac97->shared is non-zero, check the existence of the already-initialized codec first, if (ac97->shared && ac97_shared_codec[ac97->shared][ac97->num]) { if (modem_only) ... if (audio_only) ... } and set it when ready if (ac97->shared) ac97_shared_codec[ac97->shared][ac97->num] = ac97; release it in snd_ac97_free(), if (ac97->shared) ac97_shared_codec[ac97->shared][ac97->num] = NULL; Most likely we'll need to protect the above with mutex. Takashi ------------------------------------------------------- This SF.Net email is sponsored by BEA Weblogic Workshop FREE Java Enterprise J2EE developer tools! Get your free copy of BEA WebLogic Workshop 8.1 today. http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click