| 568 | return status, result |
| 569 | |
| 570 | class LoadableModules: |
| 571 | def __init__(self, kb): |
| 572 | self.__kb = kb |
| 573 | |
| 574 | def create_driver(self, driver_name, driver_entry): |
| 575 | return self.__kb.KbCreateDriver(c_wchar_p(driver_name), c_uint64(driver_entry)) |
| 576 | |
| 577 | def load_module(self, hmodule, module_name, on_load, on_unload, on_device_control): |
| 578 | return self.__kb.KbLoadModule( |
| 579 | c_uint64(hmodule), |
| 580 | c_wchar_p(module_name), |
| 581 | c_uint64(on_load), |
| 582 | c_uint64(on_unload), |
| 583 | c_uint64(on_device_control) |
| 584 | ) |
| 585 | |
| 586 | def unload_module(self, hmodule): |
| 587 | return self.__kb.KbUnloadModule(c_uint64(hmodule)) |
| 588 | |
| 589 | def get_module_handle(self, module_name): |
| 590 | hmodule = c_uint64() |
| 591 | status = self.__kb.KbGetModuleHandle(c_wchar_p(module_name), byref(hmodule)) |
| 592 | return status, hmodule |
| 593 | |
| 594 | def call_module(self, hmodule, ctl_code, arg): |
| 595 | return self.__kb.KbCallModule(c_uint64(hmodule), c_uint(ctl_code), c_uint64(arg)) |
| 596 | |
| 597 | class Pci: |
| 598 | def __init__(self, kb): |
nothing calls this directly
no outgoing calls
no test coverage detected