lkml.org 
[lkml]   [2003]   [Jan]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [2.5.58][PnP] Some small points.
On Sun, 19 Jan 2003, Ruslan U. Zakirov wrote:

> On Sat, 18 Jan 2003, Jaroslav Kysela wrote:
>
> > On Fri, 17 Jan 2003, Adam Belay wrote:
> >
> > > > 4) Have we got ALSA driver that work absolutly and use PnP layer in
> > > > right ways?
> > >
> > > I believe Jaroslav is working on that now. Jaroslav, if you would like me to
> > > convert ALSA drivers please let me know.
> >
> > I'm working on it. Your converted drivers still misses one feature: force
> > resources via module options. Two complete drivers using configuration
> > templates follow.
> >
> [snip]
> > -static void snd_opl3sa2_isapnp_remove(struct pnp_card * card)
> > +static void __devexit snd_opl3sa2_isapnp_remove(struct pnp_card * pcard)
> > {
> > -/* FIXME */
> > + snd_card_t * card = (snd_card_t *) pnpc_get_drvdata(pcard);
> > +
> > + snd_card_disconnect(card);
> > + snd_card_free_in_thread(card);
> > }
> [snip]
> > static void __exit alsa_card_opl3sa2_exit(void)
> > {
> > - int idx;
> > + int dev;
> >
> > - for (idx = 0; idx < SNDRV_CARDS; idx++)
> > - snd_card_free(snd_opl3sa2_cards[idx]);
> > + pnpc_unregister_driver(&opl3sa2_pnpc_driver);
> > + for (dev = 0; dev < SNDRV_CARDS; dev++)
> > + snd_card_free(snd_opl3sa2_cards[dev]);
> > }
> Hello Jaroslav and other.
> I could be wrong.
> 1) It's cause an compilation error without CONFIG_PNP.

Yes, the opl3sa2_pnpc_driver structure is not defined. Corrected.

> 2) We can delete call of snd_card_free in module exit function, it'll be
> freed within driver->remove call. It's realy needed only without
> CONFIG_PNP_CARD.

No, we can mix pnp and non-pnp cards. The non-pnp cards have to be
removed manually.

Jaroslav

-----
Jaroslav Kysela <perex@suse.cz>
Linux Kernel Sound Maintainer
ALSA Project, SuSE Labs

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:32    [W:0.038 / U:2.400 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site