Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 04 Jan 1999 00:12:14 -0700
From:      Tod Morrison <tmorrison@uswest.net>
To:        Luigi Rizzo <luigi@labinfo.iet.unipi.it>
Cc:        Tod Morrison <tod.morrison@usa.net>, freebsd-current@FreeBSD.ORG
Subject:   Re: SoundBlaster 128
Message-ID:  <369069CE.BF488BCC@uswest.net>
References:  <199901031207.NAA26575@labinfo.iet.unipi.it>

next in thread | previous in thread | raw e-mail | index | archive | help
Luigi Rizzo wrote:
> 
> > The pcm driver works nicely, except for that the module doesn't register
> > if there are not any isa devices (? - I don't really understand the
> > problem, I just found a patch in the mailing list archives to fix it ).
> 
> can you send me the patch (original one or your modified one).
> Unfortunately my test machine has an onboard ISA audio card so i cannot
> easily reproduce the problem.
> 
>         thanks
>         luigi
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-current" in the body of the message

Here's a copy of the original posting from the archive, it won't apply
as is but its only changing a few lines in one file so it shouldn't be
to hard to do by hand.

	Tod

------------

The following patch (to be added to my other patches) removes the bug
that the cdevsw entry was not added when there was no ISA card
attached:

--- sound.c.orig        Mon Nov 23 18:07:35 1998
+++ sound.c     Mon Nov 23 18:06:04 1998
@@ -239,7 +239,6 @@
     snddev_info *d = NULL ;
     struct isa_device *dvp;
     int stat = 0;
-    dev_t isadev;
 
     dev->id_ointr = pcmintr;
 
@@ -284,9 +283,6 @@
     if (FULL_DUPLEX(d))
        isa_dma_acquire(d->dbuf_in.chan);
 
-    isadev = makedev(CDEV_MAJOR, 0);
-    cdevsw_add(&isadev, &snd_cdevsw, NULL);
-
     /*
      * should try and find a suitable value for id_id, otherwise
      * the interrupt is not registered and dispatched properly.
@@ -331,6 +327,10 @@
 pcminit(snddev_info *d, int unit)
 {
     void *cookie;
+    dev_t dev;
+
+    dev = makedev(CDEV_MAJOR, 0);
+    cdevsw_add(&dev, &snd_cdevsw, NULL);
 
     /*
      * initialize standard parameters for the device. This can be

cu Jo

---------------------------------------------------------------------
Pray that there's intelligent life                    Joachim Kuebart
Somewhere up in space                              Stuttgart, Germany
'Cause there's bugger all down here on earth.
                              --- Monty Python

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?369069CE.BF488BCC>