summaryrefslogtreecommitdiffstats
path: root/sound/firewire/fireface
diff options
context:
space:
mode:
authorTakashi Iwai2019-02-05 12:34:12 +0100
committerTakashi Iwai2019-02-06 18:11:38 +0100
commit0c298bdc38a00b8bbbd4df21c85c57d8a9dab625 (patch)
tree10c0edb946537b7972c142c2925c3a9bc1fcb49f /sound/firewire/fireface
parentALSA: info: Always register entries recursively (diff)
downloadkernel-qcow2-linux-0c298bdc38a00b8bbbd4df21c85c57d8a9dab625.tar.gz
kernel-qcow2-linux-0c298bdc38a00b8bbbd4df21c85c57d8a9dab625.tar.xz
kernel-qcow2-linux-0c298bdc38a00b8bbbd4df21c85c57d8a9dab625.zip
ALSA: firewire: Remove superfluous snd_info_register() calls
The calls of snd_info_register() are superfluous and should be avoided at the procfs creation time. They are called at the end of the whole initialization via snd_card_register(). This patch drops such superfluous calls. Reviewed-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Tested-by: Takashi Sakamoto <o-takashi@sakamocchi.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/firewire/fireface')
-rw-r--r--sound/firewire/fireface/ff-proc.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/sound/firewire/fireface/ff-proc.c b/sound/firewire/fireface/ff-proc.c
index a55e68ec1832..b886b541c94b 100644
--- a/sound/firewire/fireface/ff-proc.c
+++ b/sound/firewire/fireface/ff-proc.c
@@ -41,12 +41,8 @@ static void add_node(struct snd_ff *ff, struct snd_info_entry *root,
struct snd_info_entry *entry;
entry = snd_info_create_card_entry(ff->card, name, root);
- if (entry == NULL)
- return;
-
- snd_info_set_text_ops(entry, ff, op);
- if (snd_info_register(entry) < 0)
- snd_info_free_entry(entry);
+ if (entry)
+ snd_info_set_text_ops(entry, ff, op);
}
void snd_ff_proc_init(struct snd_ff *ff)
@@ -62,10 +58,6 @@ void snd_ff_proc_init(struct snd_ff *ff)
if (root == NULL)
return;
root->mode = S_IFDIR | 0555;
- if (snd_info_register(root) < 0) {
- snd_info_free_entry(root);
- return;
- }
add_node(ff, root, "status", proc_dump_status);
}