[alsa-devel] module dependency between i915 and snd-hda-intel

Wang, Xingchao xingchao.wang at intel.com
Fri May 17 12:14:19 CEST 2013


> -----Original Message-----
> From: Takashi Iwai [mailto:tiwai at suse.de]
> Sent: Friday, May 17, 2013 6:03 PM
> To: Wang, Xingchao
> Cc: Lin, Mengdong; david.henningsson at canonical.com; Li, Jocelyn; Girdwood,
> Liam R; alsa-devel at alsa-project.org
> Subject: Re: module dependency between i915 and snd-hda-intel
> 
> At Fri, 17 May 2013 09:55:13 +0000,
> Wang, Xingchao wrote:
> >
> > Hi Takashi,
> >
> > Seems kernel building will determine the module loading sequence, this would
> fix the dependency for i915 and snd-hda-intel.
> > If we call the i915 module API directly in snd-hda-intel side, kernel building will
> change the module.dep accordingly like:
> > "
> > kernel/sound/pci/hda/snd-hda-intel.ko: kernel/drivers/gpu/drm/i915/i915.ko
> kernel/drivers/gpu/dr     m/drm_kms_helper.ko
> kernel/drivers/gpu/drm/drm.ko kernel/drivers/i2c/algos/i2c-algo-bit.ko kerne
> l/drivers/acpi/video.ko kernel/sound/pci/hda/snd-hda-codec.ko
> kernel/sound/core/snd-hwdep.ko ker     nel/sound/core/snd-pcm.ko
> kernel/sound/core/snd-timer.ko kernel/sound/core/snd.ko kernel/sound/s
> oundcore.ko kernel/sound/core/snd-page-alloc.ko
> > "
> > So snd-hda-intel will wait for i915 loading. Even I added i915 into blacklist.conf,
> it will force load i915.ko.
> >
> > So I think the only bad case is no i915 module built-in, that would cause
> haswell hda initialize fail, and the patch would output error message.
> 
> Is it the result with your patch?  If so, something must be wrong.
> 

No. i'm testing the case to call the API directly.
The issue is with current patch to load i915.ko by request_module(), It would take ~50s
and symbol_get() would fail, but I can see i915 module already there by "lsmod".

So is there any difference between request_module() and auto-loading i915 module?

> We don't want to call i915 functions directly from snd-hda-intel.
> That's the exact reason symbol_get() is used.  Otherwise i915 module is
> always referred, thus always load when HD-audio is used, no matter which
> hardware is.

Okay, I see.

Thanks
--xingchao
> 
> 
> Takashi


More information about the Alsa-devel mailing list