diff --git a/sys/sys/bus.h b/sys/sys/bus.h --- a/sys/sys/bus.h +++ b/sys/sys/bus.h @@ -851,24 +851,25 @@ int dmd_pass; }; -#define EARLY_DRIVER_MODULE_ORDERED(name, busname, driver, evh, arg, \ +#define EARLY_DRIVER_MODULE_ORDERED(_name, busname, driver, evh, arg, \ order, pass) \ \ -static struct driver_module_data name##_##busname##_driver_mod = { \ - evh, arg, \ - #busname, \ - (kobj_class_t) &driver, \ - NULL, \ - pass \ +static struct driver_module_data _name##_##busname##_driver_mod = { \ + .dmd_chainevh = evh, \ + .dmd_chainarg = arg, \ + .dmd_busname = #busname, \ + .dmd_driver = (kobj_class_t)&driver, \ + .dmd_devclass = NULL, \ + .dmd_pass = pass, \ }; \ \ -static moduledata_t name##_##busname##_mod = { \ - #busname "/" #name, \ - driver_module_handler, \ - &name##_##busname##_driver_mod \ +static moduledata_t _name##_##busname##_mod = { \ + .name = #busname "/" #_name , \ + .evhand = driver_module_handler, \ + .priv = &_name##_##busname##_driver_mod, \ }; \ -DECLARE_MODULE(name##_##busname, name##_##busname##_mod, \ - SI_SUB_DRIVERS, order) +DECLARE_MODULE(_name##_##busname, _name##_##busname##_mod, \ + SI_SUB_DRIVERS, order) #define EARLY_DRIVER_MODULE(name, busname, driver, evh, arg, pass) \ EARLY_DRIVER_MODULE_ORDERED(name, busname, driver, evh, arg, \