Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F102099267
D44991.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
902 B
Referenced Files
None
Subscribers
None
D44991.diff
View Options
diff --git a/sys/dev/sound/pcm/dsp.c b/sys/dev/sound/pcm/dsp.c
--- a/sys/dev/sound/pcm/dsp.c
+++ b/sys/dev/sound/pcm/dsp.c
@@ -2085,6 +2085,7 @@
}
return;
found:
+ bus_topo_lock();
d = devclass_get_softc(pcm_devclass, snd_unit);
/*
* If we only have a single soundcard attached and we detach it right
@@ -2096,6 +2097,7 @@
*dev = d->dsp_dev;
dev_ref(*dev);
}
+ bus_topo_unlock();
}
static void
diff --git a/sys/dev/sound/pcm/mixer.c b/sys/dev/sound/pcm/mixer.c
--- a/sys/dev/sound/pcm/mixer.c
+++ b/sys/dev/sound/pcm/mixer.c
@@ -1377,12 +1377,14 @@
if (*dev != NULL)
return;
if (strcmp(name, "mixer") == 0) {
+ bus_topo_lock();
d = devclass_get_softc(pcm_devclass, snd_unit);
/* See related comment in dsp_clone(). */
if (d != NULL && PCM_REGISTERED(d) && d->mixer_dev != NULL) {
*dev = d->mixer_dev;
dev_ref(*dev);
}
+ bus_topo_unlock();
}
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Nov 8, 2:42 PM (22 h, 6 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14536836
Default Alt Text
D44991.diff (902 B)
Attached To
Mode
D44991: sound: Wrap dsp_clone() and mixer_clone() with bus_topo_lock()
Attached
Detach File
Event Timeline
Log In to Comment