diff --git a/sys/dev/sound/pcm/feeder.c b/sys/dev/sound/pcm/feeder.c --- a/sys/dev/sound/pcm/feeder.c +++ b/sys/dev/sound/pcm/feeder.c @@ -68,9 +68,6 @@ fte->idx = feedercnt; SLIST_INSERT_HEAD(&feedertab, fte, link); feedercnt++; - - /* we've got our root feeder so don't veto pcm loading anymore */ - pcm_veto_load = 0; } void @@ -465,6 +462,10 @@ .desc = NULL, .data = NULL, }; +/* + * Register the root feeder first so that pcm_addchan() and subsequent + * functions can use it. + */ SYSINIT(feeder_root, SI_SUB_DRIVERS, SI_ORDER_FIRST, feeder_register_root, &feeder_root_class); SYSUNINIT(feeder_root, SI_SUB_DRIVERS, SI_ORDER_FIRST, feeder_unregisterall, NULL); diff --git a/sys/dev/sound/pcm/sound.h b/sys/dev/sound/pcm/sound.h --- a/sys/dev/sound/pcm/sound.h +++ b/sys/dev/sound/pcm/sound.h @@ -229,7 +229,6 @@ #define DSP_DEFAULT_SPEED 8000 -extern int pcm_veto_load; extern int snd_unit; extern int snd_verbose; extern devclass_t pcm_devclass; diff --git a/sys/dev/sound/pcm/sound.c b/sys/dev/sound/pcm/sound.c --- a/sys/dev/sound/pcm/sound.c +++ b/sys/dev/sound/pcm/sound.c @@ -48,8 +48,6 @@ devclass_t pcm_devclass; -int pcm_veto_load = 1; - int snd_unit = -1; static int snd_unit_auto = -1; @@ -462,12 +460,6 @@ struct snddev_info *d; int i; - if (pcm_veto_load) { - device_printf(dev, "disabled due to an error while initialising: %d\n", pcm_veto_load); - - return EINVAL; - } - d = device_get_softc(dev); d->dev = dev; d->lock = snd_mtxcreate(device_get_nameunit(dev), "sound cdev");