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>
This commit is contained in:
@@ -244,10 +244,7 @@ static void oxygen_proc_read(struct snd_info_entry *entry,
|
||||
|
||||
static void oxygen_proc_init(struct oxygen *chip)
|
||||
{
|
||||
struct snd_info_entry *entry;
|
||||
|
||||
if (!snd_card_proc_new(chip->card, "oxygen", &entry))
|
||||
snd_info_set_text_ops(entry, chip, oxygen_proc_read);
|
||||
snd_card_ro_proc_new(chip->card, "oxygen", chip, oxygen_proc_read);
|
||||
}
|
||||
|
||||
static const struct pci_device_id *
|
||||
|
Reference in New Issue
Block a user