DF-5558 / iicbb_reg.c
/* * iicbb_reg.c -- DF-5539 harness part 1: register the REAL in-tree * iicbb_driver/iicbb_devclass (exported by iicbb.ko via iiconf.h) on a * fake bus named "fakebb", mirroring the in-tree * DRIVER_MODULE(iicbb, lpbb/viapm/cxm_iic/...) declarations at * sys/bus/iicbus/iicbb.c:441-445. * * Load order (run.sh): iicbus.ko, iicbb.ko, iicbb_reg.ko, THEN the * harness. With the (fakebb,iicbb) driver pair registered up front, the * whole attach cascade (fakebb0 -> iicbb0 -> iicbus0 -> print_child LEAK) * runs synchronously inside iicbb_harness.ko's MOD_LOAD. */ #include <sys/param.h> #include <sys/kernel.h> #include <sys/module.h> #include <sys/bus.h> #include <bus/iicbus/iiconf.h> #include <bus/iicbus/iicbus.h> DRIVER_MODULE(iicbb, fakebb, iicbb_driver, iicbb_devclass, NULL, NULL); |