Commit 562b590d authored by Clemens Ladisch's avatar Clemens Ladisch Committed by Jaroslav Kysela

[ALSA] remove unused snd_minor.name field

Drop the snd_minor structure's name field that was just a helper for
devfs device deregistration.
Signed-off-by: default avatarClemens Ladisch <clemens@ladisch.de>
Signed-off-by: default avatarJaroslav Kysela <perex@suse.cz>
parent b130807d
...@@ -188,8 +188,6 @@ struct snd_minor { ...@@ -188,8 +188,6 @@ struct snd_minor {
int device; /* device number */ int device; /* device number */
const struct file_operations *f_ops; /* file operations */ const struct file_operations *f_ops; /* file operations */
void *private_data; /* private data for f_ops->open */ void *private_data; /* private data for f_ops->open */
char name[0]; /* device name (keep at the end of
structure) */
}; };
/* sound.c */ /* sound.c */
......
...@@ -244,7 +244,7 @@ int snd_register_device(int type, struct snd_card *card, int dev, ...@@ -244,7 +244,7 @@ int snd_register_device(int type, struct snd_card *card, int dev,
struct device *device = NULL; struct device *device = NULL;
snd_assert(name, return -EINVAL); snd_assert(name, return -EINVAL);
preg = kmalloc(sizeof(struct snd_minor) + strlen(name) + 1, GFP_KERNEL); preg = kmalloc(sizeof *preg, GFP_KERNEL);
if (preg == NULL) if (preg == NULL)
return -ENOMEM; return -ENOMEM;
preg->type = type; preg->type = type;
...@@ -252,7 +252,6 @@ int snd_register_device(int type, struct snd_card *card, int dev, ...@@ -252,7 +252,6 @@ int snd_register_device(int type, struct snd_card *card, int dev,
preg->device = dev; preg->device = dev;
preg->f_ops = f_ops; preg->f_ops = f_ops;
preg->private_data = private_data; preg->private_data = private_data;
strcpy(preg->name, name);
mutex_lock(&sound_mutex); mutex_lock(&sound_mutex);
#ifdef CONFIG_SND_DYNAMIC_MINORS #ifdef CONFIG_SND_DYNAMIC_MINORS
minor = snd_find_free_minor(); minor = snd_find_free_minor();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment