misc questions about the device&driver arch

william wallace avalonwallace at gmail.com
Fri May 19 20:15:17 PDT 2006

about  devclass_find_internal
devclass_find_internal will  be called to create a new devclass in
such 2 conditions :
one is creating a new device , as : if (name) {  dc =
devclass_find_internal(name, 0, TRUE);
another is  in the function:devclass_add_driver. but ,if a driver 's
name is different from the name of any deviceclass  in the system ,it
just create a new devclass ,and link it self into the parent
busdevice's driver link  and do nothing .what is the use of the driver
at this situation?

On 11/4/05, kylin <fierykylin at gmail.com> wrote:
> hello every one :) good day!
> i have list the 3 puzzle coming to me in my recent coding reading of freebsd
> 0
> ///////////////
> pci bridge dynamic resize
> /////////////
> it seems that the device arch of freebsd is similar to what is revealed in
> window OS. i have read the pcie hotplug tps of windows longhorn ,it is said
> that with some hardware mechanisms the pci bridge driver can do global pci
> resource window reconfiguration.so good to the hotplugin pci device for it
> avoid prelocating resource for the device .
> i wonder ,if the mem /io/irq reconfiguration possible under freebsd .:)
> 1
> //////////////
>   is bus_data_generation
> /////////
> what idoes bus_data_generation for, is it the generation count for the
> device manager tree?
> void
> bus_data_generation_update(void)
> {
>  bus_data_generation++;
> }
> 2
> //////////////
> pci_write_config vs  pci_write_config_method
> //////////////
> under the source code /dev/pci .there are functions name pci_write_config
> (pcivar.h)  and pci_write_config_method(pci.c)
> they both call the parent method ,though the content is different ,but does
> that a liitle overlap whit each other?
> --
> we who r about to die,salute u!

we who r about to die,salute u!

More information about the freebsd-hackers mailing list