Top |
bool | igt_kmod_is_loaded () |
void | igt_kmod_list_loaded () |
int | igt_kmod_load () |
int | igt_kmod_unload () |
int | igt_i915_driver_load () |
int | igt_i915_driver_unload () |
void | igt_kselftests () |
int | igt_kselftest_init () |
int | igt_kselftest_begin () |
void | igt_kselftest_get_tests () |
int | igt_kselftest_execute () |
void | igt_kselftest_end () |
void | igt_kselftest_fini () |
This library provides helpers to load/unload module driver.
Note on loading/reloading:
Loading/unload/reloading the driver requires that resources to /dev/dri to
be released (closed). A potential mistake would be to submit commands to the
GPU by having a fd returned by drm_open_driver
, which is closed by atexit
signal handler so reloading/unloading the driver will fail if performed
afterwards. One possible solution to this issue is to use
or use __drm_open_driver()
to set module parameters
dynamically.igt_set_module_param()
int igt_kmod_load (const char *mod_name
,const char *opts
);
mod_name |
The name of the module |
|
opts |
Parameters for the module. NULL in case no parameters are to be passed, or a '\0' terminated string otherwise. |
0 in case of success or -errno in case the module could not be loaded.
This function loads a kernel module using the name specified in mod_name
.
Note
: This functions doesn't automatically resolve other module
dependencies so make make sure you load the dependencies module(s) before
this one.
int igt_kmod_unload (const char *mod_name
,unsigned int flags
);
int
igt_i915_driver_load (const char *opts
);
Loads the i915 driver and its dependencies.
int
igt_i915_driver_unload (void
);
Unloads the i915 driver and its dependencies.
void igt_kselftests (const char *module_name
,const char *module_options
,const char *result_option
,const char *filter
);
void igt_kselftest_get_tests (struct kmod_module *kmod
,const char *filter
,struct igt_list *tests
);
int igt_kselftest_execute (struct igt_kselftest *tst
,struct igt_kselftest_list *tl
,const char *module_options
,const char *result
);