feature (test driver): configuring driver on init
This commit is contained in:
parent
1f85d26779
commit
b2948a49fd
|
@ -1 +1,3 @@
|
||||||
build
|
build
|
||||||
|
*/CMakeLists.txt
|
||||||
|
*/cmake-build-debug
|
|
@ -1,7 +1,20 @@
|
||||||
#include "libnxdrv.h"
|
#include "libnxdrv.h"
|
||||||
|
|
||||||
int _start() {
|
nx_drv_config_pci_T config_pci = {
|
||||||
nx_drv_init();
|
.enable_progif = true,
|
||||||
|
.class = 0x01,
|
||||||
|
.subclass = 0x06,
|
||||||
|
.progif = 0x01,
|
||||||
|
.num_device_ids = 1,
|
||||||
|
.device_ids = {
|
||||||
|
.vendor_id = 0x8086,
|
||||||
|
.device_id = 0x2922
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
int _init() {
|
||||||
|
nx_drv_pci_config(&config_pci);
|
||||||
|
|
||||||
|
nx_drv_log("test driver initialized");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
Loading…
Reference in New Issue