From: Takashi Iwai Subject: Re: snd-opti92x-{ad1848,cs4231} won't compile without CONFIG_PNP Date: Tue, 28 Feb 2006 11:23:43 +0100 Message-ID: References: <440377F0.6040201@keyaccess.nl> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Return-path: Received: from mx1.suse.de (ns1.suse.de [195.135.220.2]) by alsa.jcu.cz (ALSA's E-mail Delivery System) with ESMTP id 1F5C31AE for ; Tue, 28 Feb 2006 11:23:58 +0100 (MET) In-Reply-To: <440377F0.6040201@keyaccess.nl> 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: Rene Herman Cc: alsa-devel@alsa-project.org List-Id: alsa-devel@alsa-project.org At Mon, 27 Feb 2006 23:06:40 +0100, Rene Herman wrote: > > Hi Takashi. > > Noticed the snd-opti92x driver wouldn't compile without ISA-PnP support. > I see the driver only supports one card meaning it wants a bit more than > this to bring it inline, but a minimal fix is attached. > > I do actually have a pnp opti92x / cs4231 card lying around somewhere > although not available right now. I'll dig it up and do some cleanup / > testing in the not too distant future, if you'd like me to. Thanks, a similar fix was already on ALSA CVS tree yesterday (although yours looks nicer :) Maybe better to wait until the clean up patch? Takashi > > Rene. > > [2 opti92x_pnpc_driver.diff ] > Index: local/sound/isa/opti9xx/opti92x-ad1848.c > =================================================================== > --- local.orig/sound/isa/opti9xx/opti92x-ad1848.c 2006-02-27 19:22:35.000000000 +0100 > +++ local/sound/isa/opti9xx/opti92x-ad1848.c 2006-02-27 22:26:52.000000000 +0100 > @@ -2088,9 +2088,12 @@ static int __init alsa_card_opti9xx_init > int error; > struct platform_device *device; > > +#ifdef CONFIG_PNP > pnp_register_card_driver(&opti9xx_pnpc_driver); > if (snd_opti9xx_pnp_is_probed) > return 0; > + pnp_unregister_card_driver(&opti9xx_pnpc_driver); > +#endif > if (! is_isapnp_selected()) { > error = platform_driver_register(&snd_opti9xx_driver); > if (error < 0) > @@ -2102,7 +2105,6 @@ static int __init alsa_card_opti9xx_init > } > platform_driver_unregister(&snd_opti9xx_driver); > } > - pnp_unregister_card_driver(&opti9xx_pnpc_driver); > #ifdef MODULE > printk(KERN_ERR "no OPTi " CHIP_NAME " soundcard found\n"); > #endif > @@ -2115,7 +2117,10 @@ static void __exit alsa_card_opti9xx_exi > platform_device_unregister(snd_opti9xx_platform_device); > platform_driver_unregister(&snd_opti9xx_driver); > } > - pnp_unregister_card_driver(&opti9xx_pnpc_driver); > +#ifdef CONFIG_PNP > + else > + pnp_unregister_card_driver(&opti9xx_pnpc_driver); > +#endif > } > > module_init(alsa_card_opti9xx_init) ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642