aboutsummaryrefslogtreecommitdiffstats
path: root/sound/core/hwdep.c
diff options
context:
space:
mode:
authorClemens Ladisch <clemens@ladisch.de>2005-10-24 11:05:03 -0400
committerJaroslav Kysela <perex@suse.cz>2005-11-04 07:20:08 -0500
commitf1902860161ff212c515e7ea629e880fec856a37 (patch)
treec3dc4d5ca38c05f15f06a6583594f7b54dad4c66 /sound/core/hwdep.c
parentc8a7e5c40ddcf98f1026581e411b05ff86491907 (diff)
[ALSA] fix improper CONFIG_SND_MAJOR usage
Modules: HWDEP Midlevel,PCM Midlevel,RawMidi Midlevel,ALSA Core Replace usage of CONFIG_SND_MAJOR with snd_major, where appropriate. Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Diffstat (limited to 'sound/core/hwdep.c')
-rw-r--r--sound/core/hwdep.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/sound/core/hwdep.c b/sound/core/hwdep.c
index 9383f1294fb5..e91cee35a4b9 100644
--- a/sound/core/hwdep.c
+++ b/sound/core/hwdep.c
@@ -81,20 +81,16 @@ static int snd_hwdep_open(struct inode *inode, struct file * file)
81 int err; 81 int err;
82 wait_queue_t wait; 82 wait_queue_t wait;
83 83
84 switch (major) { 84 if (major == snd_major) {
85 case CONFIG_SND_MAJOR:
86 cardnum = SNDRV_MINOR_CARD(iminor(inode)); 85 cardnum = SNDRV_MINOR_CARD(iminor(inode));
87 device = SNDRV_MINOR_DEVICE(iminor(inode)) - SNDRV_MINOR_HWDEP; 86 device = SNDRV_MINOR_DEVICE(iminor(inode)) - SNDRV_MINOR_HWDEP;
88 break;
89#ifdef CONFIG_SND_OSSEMUL 87#ifdef CONFIG_SND_OSSEMUL
90 case SOUND_MAJOR: 88 } else if (major == SOUND_MAJOR) {
91 cardnum = SNDRV_MINOR_OSS_CARD(iminor(inode)); 89 cardnum = SNDRV_MINOR_OSS_CARD(iminor(inode));
92 device = 0; 90 device = 0;
93 break;
94#endif 91#endif
95 default: 92 } else
96 return -ENXIO; 93 return -ENXIO;
97 }
98 cardnum %= SNDRV_CARDS; 94 cardnum %= SNDRV_CARDS;
99 device %= SNDRV_MINOR_HWDEPS; 95 device %= SNDRV_MINOR_HWDEPS;
100 hw = snd_hwdep_devices[(cardnum * SNDRV_MINOR_HWDEPS) + device]; 96 hw = snd_hwdep_devices[(cardnum * SNDRV_MINOR_HWDEPS) + device];