From 92b7952da8279189aad352efbf9f2e7001de9524 Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Thu, 29 Jan 2015 15:53:51 +0100 Subject: ALSA: Allow to pass the device object to snd_register_device*() This is a preliminary patch for the further work on embedding struct device into each sound device instance. It changes snd_register_device*() helpers to receive the device object directly for skipping creating a device there. Reviewed-by: Jaroslav Kysela Signed-off-by: Takashi Iwai --- sound/core/hwdep.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'sound/core/hwdep.c') diff --git a/sound/core/hwdep.c b/sound/core/hwdep.c index 69459e5f712e..85096a150eda 100644 --- a/sound/core/hwdep.c +++ b/sound/core/hwdep.c @@ -433,7 +433,8 @@ static int snd_hwdep_dev_register(struct snd_device *device) dev = snd_card_get_device_link(hwdep->card); err = snd_register_device_for_dev(SNDRV_DEVICE_TYPE_HWDEP, hwdep->card, hwdep->device, - &snd_hwdep_f_ops, hwdep, name, dev); + &snd_hwdep_f_ops, hwdep, + NULL, dev, name); if (err < 0) { dev_err(dev, "unable to register hardware dependent device %i:%i\n", -- cgit