diff options
author | Takashi Iwai <tiwai@suse.de> | 2019-02-04 16:01:39 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2019-02-06 18:11:56 +0100 |
commit | 47f2769b4b2e267cba135fc19c89c32d202b1415 (patch) | |
tree | 58078c2d663d901622b6015bbfde465e2dda7e8f /sound/pci/mixart | |
parent | ALSA: i2c: Clean up with new procfs helpers (diff) | |
download | linux-47f2769b4b2e267cba135fc19c89c32d202b1415.tar.xz linux-47f2769b4b2e267cba135fc19c89c32d202b1415.zip |
ALSA: pci: Clean up with new procfs helpers
Simplify the proc fs creation code with new helper functions,
snd_card_ro_proc_new() and snd_card_rw_proc_new().
Just a code refactoring and no functional changes.
Reviewed-by: Jaroslav Kysela <perex@perex.cz>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/mixart')
-rw-r--r-- | sound/pci/mixart/mixart.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sound/pci/mixart/mixart.c b/sound/pci/mixart/mixart.c index 9cd297a42f24..92f616df3863 100644 --- a/sound/pci/mixart/mixart.c +++ b/sound/pci/mixart/mixart.c @@ -1220,10 +1220,8 @@ static void snd_mixart_proc_init(struct snd_mixart *chip) struct snd_info_entry *entry; /* text interface to read perf and temp meters */ - if (! snd_card_proc_new(chip->card, "board_info", &entry)) { - entry->private_data = chip; - entry->c.text.read = snd_mixart_proc_read; - } + snd_card_ro_proc_new(chip->card, "board_info", chip, + snd_mixart_proc_read); if (! snd_card_proc_new(chip->card, "mixart_BA0", &entry)) { entry->content = SNDRV_INFO_CONTENT_DATA; |