tech-kern archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
hdaudio driver
I'm trying to clean up the hdaudio and hdaudio_pci drivers so they can
actually be loaded as modules. (The problem currently is a circular
module dependency, as described in PR/49836).
I have resolved the issue regarding the definition of hdaudio_cd symbol,
but there's still some unresolved symbols!
The configuration "tree" looks something like this:
pci at mainbus
hdaudio_pci at pci (provides hdaudiobus attribute)
hdaudio at hdaudio_pci (vie hdaudiobus)
hdafg at hdaudio
audio at hdafg
For some reason, the interface-attribute driver hdaudio_pci.c calls the
various 'struct cfattach' functions for the hdaudio driver. For
example, hdaudio_pci_rescan() calls hdaudio_rescan(),
hdaudio_pci_childdet() calls hdaudio_childdet(), etc. In effect, the
parent device is calling the child device, which requires the child
device's module to be loaded first.
It seems to me that this is somewhat backwards; it makes more sense to
me that the child device should be calling the parent's routines.
Am I misuderstanding something?
+------------------+--------------------------+----------------------------+
| Paul Goyette | PGP Key fingerprint: | E-mail addresses: |
| (Retired) | FA29 0E3B 35AF E8AE 6651 | paul at whooppee dot com |
| Kernel Developer | 0786 F758 55DE 53BA 7731 | pgoyette at netbsd dot org |
+------------------+--------------------------+----------------------------+
Home |
Main Index |
Thread Index |
Old Index