Skip to content

Commit 327ef4f

Browse files
committed
ALSA: hda - Decouple PCM and hwdep devices from codec object
This is a preliminary patch for the hda_bus implementation, removing the parent device setup to codec device. Since the bus and the class devices can't be crossed over, leave the sound devices to the default parent device as is. Signed-off-by: Takashi Iwai <tiwai@suse.de>
1 parent 72f770c commit 327ef4f

File tree

3 files changed

+0
-7
lines changed

3 files changed

+0
-7
lines changed

sound/pci/hda/hda_beep.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,6 @@ static int snd_hda_do_attach(struct hda_beep *beep)
168168
input_dev->evbit[0] = BIT_MASK(EV_SND);
169169
input_dev->sndbit[0] = BIT_MASK(SND_BELL) | BIT_MASK(SND_TONE);
170170
input_dev->event = snd_hda_beep_event;
171-
input_dev->dev.parent = &codec->dev;
172171
input_set_drvdata(input_dev, beep);
173172

174173
beep->dev = input_dev;

sound/pci/hda/hda_controller.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -958,9 +958,6 @@ static int azx_attach_pcm_stream(struct hda_bus *bus, struct hda_codec *codec,
958958
snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_DEV_SG,
959959
chip->card->dev,
960960
size, MAX_PREALLOC_SIZE);
961-
/* link to codec */
962-
for (s = 0; s < 2; s++)
963-
pcm->streams[s].dev.parent = &codec->dev;
964961
return 0;
965962
}
966963

sound/pci/hda/hda_hwdep.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -116,9 +116,6 @@ int snd_hda_create_hwdep(struct hda_codec *codec)
116116
hwdep->ops.ioctl_compat = hda_hwdep_ioctl_compat;
117117
#endif
118118

119-
/* link to codec */
120-
hwdep->dev.parent = &codec->dev;
121-
122119
/* for sysfs */
123120
hwdep->dev.groups = snd_hda_dev_attr_groups;
124121
dev_set_drvdata(&hwdep->dev, codec);

0 commit comments

Comments
 (0)