w*s 发帖数: 7227 | 1 hi again,
i have a brand new network driver, want to register,
this is what i did:
static struct platform_driver mydrv =
{
.probe = mydrv_probe,
......
}
1. static int __init mydrv_init()
{
platform_driver_register(&mydrv);
}
2. module_init(mydrv_init);
but when loading it, mydrv_probe() never gets called ?
so what's the correct way pls ?
Thanks again ! |
S*A 发帖数: 7142 | 2 What is the bus of your devcie? PCI, USB etc.
You need to fill out the proper identifier so let
the bus driver find the matching vendor id or device
id to call your probing function.
Go get a book some thing like linux device driver
version 3 |
w*s 发帖数: 7227 | 3 我这是embedded system,一个板子上有arm, fpga, mac etc.,
不是pci or usb, 请问这是什么?
【在 S*A 的大作中提到】 : What is the bus of your devcie? PCI, USB etc. : You need to fill out the proper identifier so let : the bus driver find the matching vendor id or device : id to call your probing function. : Go get a book some thing like linux device driver : version 3
|
a9 发帖数: 21638 | 4 lspci?
【在 w*s 的大作中提到】 : 我这是embedded system,一个板子上有arm, fpga, mac etc., : 不是pci or usb, 请问这是什么?
|
w*s 发帖数: 7227 | 5 brothers,
if i don't have the real HW, is this why probe() never gets called ?
【在 a9 的大作中提到】 : lspci?
|
w*s 发帖数: 7227 | 6 also do i need to add sth. for platform_device_register to make platform_
driver_register to work ? |
w*s 发帖数: 7227 | 7 also do i need to add sth. for platform_device_register to make platform_
driver_register to work ? |