linux驱动中probe函数如何调用

ath6kl_sdio_init  -> 

ret = sdio_register_driver(&ath6kl_sdio_driver);

driver_register(&drv->drv);

ret = bus_add_driver(drv);

error = driver_attach(drv);

 bus_for_each_dev(drv->bus, NULL, drv, __driver_attach);

error = fn(dev, data);     --> 这里的fn即函数参数带进来的__driver_attach

__driver_attach即可找到driver_probe_device(drv, dev);的调用.


  

你可能感兴趣的:(linux,-,driver)