Buses, devices and modules



Hi all, I have a question regarding probe and attach routines.

I've got 2 modules: for bus (mybus.ko) and for device (mydev.ko) on that bus.

mydev.ko has
MODULE_DEPEND(mydev, mybus, 1, 1, 1);

When kldloading mydev.ko, mybus.ko is loading automatically, then it founds its device, attaches properly, and mydev.ko after that founds its own device, and attaches to the bus, and all works fine.

When I do 'echo mydev_load="YES" >>/boot/loader.conf', loader loads both mydev.ko and mybus.ko, and mybus.ko attaches properly, but mydev.ko don't attach to anything.

I suppose this happens because mydev happens to probe for devices before mybus creates them, and fails to find anything to attach to.

I'm looking for way to trigger the mydev driver to re-probe after the mybus driver actually creates the devices, or may be I'm missing something simple (like priority of module probing)?
_______________________________________________
freebsd-hackers@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Re: Multiple module instatiations on a bus
    ... instance ports, it will attach one bit of the bus to each instance (or ... If I wanted to add a parameter instantiation with the array index, ...
    (comp.lang.verilog)
  • [PATCH] Add pca9532 platform data for Thecus N2100
    ... Attach the driver to the i2c bus and define ... the pca9532 pin coniguration for this platform in n2100_leds. ...
    (Linux-Kernel)
  • USBD.sys... where are you?
    ... Does anyone know where in Win2K registry you can get a filter driver to ... attach to USBD.sys (the bus driver for USB)? ... I have a lower USB class filter that I want to be able to use on all devices ...
    (microsoft.public.development.device.drivers)
  • RE: USBD.sys... where are you?
    ... > attach to USBD.sys (the bus driver for USB)? ...
    (microsoft.public.development.device.drivers)
  • Re: What brake pads should I buy for the ZX10R?
    ... >In article, Wicked Uncle Nigel ... >You attach the probe ... ... My position was (and, to be honest, largely remains) one of complete ambiguity. ...
    (uk.rec.motorcycles)