From b3b7ccfe38b22691e7b8d08c7320106a07575953 Mon Sep 17 00:00:00 2001 From: John Baldwin Date: Wed, 3 Jan 2001 01:25:26 +0000 Subject: [PATCH] Create a new sysctl node 'hw.snd' and move 'hw.sndunit' to 'hw.snd.unit'. Reviewed by: cg --- sys/dev/sound/pcm/sound.c | 4 +++- sys/dev/sound/pcm/sound.h | 3 +++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/sys/dev/sound/pcm/sound.c b/sys/dev/sound/pcm/sound.c index 0aecfb047be4..45f53d6edb39 100644 --- a/sys/dev/sound/pcm/sound.c +++ b/sys/dev/sound/pcm/sound.c @@ -132,6 +132,8 @@ pcm_makelinks(void *dummy) mixer = make_dev_alias(pdev, "mixer"); } +SYSCTL_NODE(_hw, OID_AUTO, snd, CTLFLAG_RD, 0, "Sound driver"); + static int sysctl_hw_sndunit(SYSCTL_HANDLER_ARGS) { @@ -145,7 +147,7 @@ sysctl_hw_sndunit(SYSCTL_HANDLER_ARGS) } return (error); } -SYSCTL_PROC(_hw, OID_AUTO, sndunit, CTLTYPE_INT | CTLFLAG_RW, +SYSCTL_PROC(_hw_snd, OID_AUTO, unit, CTLTYPE_INT | CTLFLAG_RW, 0, sizeof(int), sysctl_hw_sndunit, "I", ""); int diff --git a/sys/dev/sound/pcm/sound.h b/sys/dev/sound/pcm/sound.h index c3e77de57243..48ed90b68c2e 100644 --- a/sys/dev/sound/pcm/sound.h +++ b/sys/dev/sound/pcm/sound.h @@ -63,6 +63,7 @@ #include #include #include +#include #include #include #include @@ -163,6 +164,8 @@ int fkchan_kill(pcm_channel *c); #define DEB(x) #endif +SYSCTL_DECL(_hw_snd); + int pcm_addchan(device_t dev, int dir, kobj_class_t cls, void *devinfo); int pcm_register(device_t dev, void *devinfo, int numplay, int numrec); int pcm_unregister(device_t dev);