aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKay Sievers <kay.sievers@suse.de>2009-07-03 14:56:05 -0400
committerTakashi Iwai <tiwai@suse.de>2009-07-03 17:36:13 -0400
commit954a973cab37ad5df3f87f08964166abd956cc17 (patch)
tree87617bbaaf84bbb25f5c2ab331b7841fc65625d8
parent7a9d56f6a459472bc4383aeb85612d72e79d1818 (diff)
sound: do not set DEVNAME for OSS devices
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
-rw-r--r--sound/sound_core.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sound/sound_core.c b/sound/sound_core.c
index 12522e6913d9..a41f8b127f49 100644
--- a/sound/sound_core.c
+++ b/sound/sound_core.c
@@ -10,6 +10,8 @@
10#include <linux/module.h> 10#include <linux/module.h>
11#include <linux/device.h> 11#include <linux/device.h>
12#include <linux/err.h> 12#include <linux/err.h>
13#include <linux/kdev_t.h>
14#include <linux/major.h>
13#include <sound/core.h> 15#include <sound/core.h>
14 16
15#ifdef CONFIG_SOUND_OSS_CORE 17#ifdef CONFIG_SOUND_OSS_CORE
@@ -29,6 +31,8 @@ MODULE_LICENSE("GPL");
29 31
30static char *sound_nodename(struct device *dev) 32static char *sound_nodename(struct device *dev)
31{ 33{
34 if (MAJOR(dev->devt) == SOUND_MAJOR)
35 return NULL;
32 return kasprintf(GFP_KERNEL, "snd/%s", dev_name(dev)); 36 return kasprintf(GFP_KERNEL, "snd/%s", dev_name(dev));
33} 37}
34 38
@@ -104,7 +108,6 @@ module_exit(cleanup_soundcore);
104#include <linux/types.h> 108#include <linux/types.h>
105#include <linux/kernel.h> 109#include <linux/kernel.h>
106#include <linux/sound.h> 110#include <linux/sound.h>
107#include <linux/major.h>
108#include <linux/kmod.h> 111#include <linux/kmod.h>
109 112
110#define SOUND_STEP 16 113#define SOUND_STEP 16