aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGleb Smirnoff <glebius@FreeBSD.org>2012-07-02 07:39:55 +0000
committerGleb Smirnoff <glebius@FreeBSD.org>2012-07-02 07:39:55 +0000
commit35d393bf63d7e7df0ea13ebedf3158004434eaf7 (patch)
treee9d0449fed5d1356ac10c7cfe09237bcbe463c70
parenta6a8d8377f675844c7025381e2720855fe28afbe (diff)
downloadsrc-35d393bf63d7e7df0ea13ebedf3158004434eaf7.tar.gz
src-35d393bf63d7e7df0ea13ebedf3158004434eaf7.zip
- Call bus_generic_attach() at end of hdspe_attach().
- Use own devclass_t in DRIVER_MODULE(). This fixes operation of hdspe(4) when built as loadable module. Submitted by: Ruslan Bukin <br bsdpad.com>
Notes
Notes: svn path=/head/; revision=237975
-rw-r--r--sys/dev/sound/pci/hdspe.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/dev/sound/pci/hdspe.c b/sys/dev/sound/pci/hdspe.c
index 69c372d7b4e5..f3377fb49ea1 100644
--- a/sys/dev/sound/pci/hdspe.c
+++ b/sys/dev/sound/pci/hdspe.c
@@ -347,7 +347,7 @@ hdspe_attach(device_t dev)
hdspe_map_dmabuf(sc);
- return 0;
+ return (bus_generic_attach(dev));
}
static void
@@ -407,4 +407,6 @@ static driver_t hdspe_driver = {
PCM_SOFTC_SIZE,
};
-DRIVER_MODULE(snd_hdspe, pci, hdspe_driver, pcm_devclass, 0, 0);
+static devclass_t hdspe_devclass;
+
+DRIVER_MODULE(snd_hdspe, pci, hdspe_driver, hdspe_devclass, 0, 0);