Page MenuHomeFreeBSD

D23973.diff
No OneTemporary

D23973.diff

Index: sys/dev/mlx4/mlx4_core/mlx4_main.c
===================================================================
--- sys/dev/mlx4/mlx4_core/mlx4_main.c
+++ sys/dev/mlx4/mlx4_core/mlx4_main.c
@@ -4218,8 +4218,8 @@
destroy_workqueue(mlx4_wq);
}
-module_init(mlx4_init);
-module_exit(mlx4_cleanup);
+module_init_order(mlx4_init, SI_ORDER_FIRST);
+module_exit_order(mlx4_cleanup, SI_ORDER_FIRST);
static int
mlx4_evhand(module_t mod, int event, void *arg)
Index: sys/dev/mlx4/mlx4_en/mlx4_en_main.c
===================================================================
--- sys/dev/mlx4/mlx4_en/mlx4_en_main.c
+++ sys/dev/mlx4/mlx4_en/mlx4_en_main.c
@@ -304,8 +304,8 @@
mlx4_unregister_interface(&mlx4_en_interface);
}
-module_init(mlx4_en_init);
-module_exit(mlx4_en_cleanup);
+module_init_order(mlx4_en_init, SI_ORDER_SIXTH);
+module_exit_order(mlx4_en_cleanup, SI_ORDER_SIXTH);
static int
mlx4en_evhand(module_t mod, int event, void *arg)
Index: sys/dev/mlx4/mlx4_ib/mlx4_ib_main.c
===================================================================
--- sys/dev/mlx4/mlx4_ib/mlx4_ib_main.c
+++ sys/dev/mlx4/mlx4_ib/mlx4_ib_main.c
@@ -3319,8 +3319,8 @@
destroy_workqueue(wq);
}
-module_init_order(mlx4_ib_init, SI_ORDER_THIRD);
-module_exit(mlx4_ib_cleanup);
+module_init_order(mlx4_ib_init, SI_ORDER_SEVENTH);
+module_exit_order(mlx4_ib_cleanup, SI_ORDER_SEVENTH);
static int
mlx4ib_evhand(module_t mod, int event, void *arg)
Index: sys/dev/mlx5/mlx5_core/mlx5_main.c
===================================================================
--- sys/dev/mlx5/mlx5_core/mlx5_main.c
+++ sys/dev/mlx5/mlx5_core/mlx5_main.c
@@ -2026,5 +2026,5 @@
pci_unregister_driver(&mlx5_core_driver);
}
-module_init(init);
-module_exit(cleanup);
+module_init_order(init, SI_ORDER_FIRST);
+module_exit_order(cleanup, SI_ORDER_FIRST);
Index: sys/dev/mlx5/mlx5_en/mlx5_en_main.c
===================================================================
--- sys/dev/mlx5/mlx5_en/mlx5_en_main.c
+++ sys/dev/mlx5/mlx5_en/mlx5_en_main.c
@@ -4723,8 +4723,8 @@
}
SYSINIT(mlx5e_show_version, SI_SUB_DRIVERS, SI_ORDER_ANY, mlx5e_show_version, NULL);
-module_init_order(mlx5e_init, SI_ORDER_THIRD);
-module_exit_order(mlx5e_cleanup, SI_ORDER_THIRD);
+module_init_order(mlx5e_init, SI_ORDER_SIXTH);
+module_exit_order(mlx5e_cleanup, SI_ORDER_SIXTH);
#if (__FreeBSD_version >= 1100000)
MODULE_DEPEND(mlx5en, linuxkpi, 1, 1, 1);
Index: sys/dev/mlx5/mlx5_fpga_tools/mlx5fpga_tools_main.c
===================================================================
--- sys/dev/mlx5/mlx5_fpga_tools/mlx5fpga_tools_main.c
+++ sys/dev/mlx5/mlx5_fpga_tools/mlx5fpga_tools_main.c
@@ -139,5 +139,5 @@
mlx5_fpga_tools_char_deinit();
}
-module_init(mlx5_fpga_tools_init);
-module_exit(mlx5_fpga_tools_exit);
+module_init_order(mlx5_fpga_tools_init, SI_ORDER_SECOND);
+module_exit_order(mlx5_fpga_tools_exit, SI_ORDER_SECOND);
Index: sys/dev/mlx5/mlx5_ib/mlx5_ib_main.c
===================================================================
--- sys/dev/mlx5/mlx5_ib/mlx5_ib_main.c
+++ sys/dev/mlx5/mlx5_ib/mlx5_ib_main.c
@@ -3399,5 +3399,5 @@
}
SYSINIT(mlx5_ib_show_version, SI_SUB_DRIVERS, SI_ORDER_ANY, mlx5_ib_show_version, NULL);
-module_init_order(mlx5_ib_init, SI_ORDER_THIRD);
-module_exit_order(mlx5_ib_cleanup, SI_ORDER_THIRD);
+module_init_order(mlx5_ib_init, SI_ORDER_SEVENTH);
+module_exit_order(mlx5_ib_cleanup, SI_ORDER_SEVENTH);
Index: sys/dev/mthca/mthca_main.c
===================================================================
--- sys/dev/mthca/mthca_main.c
+++ sys/dev/mthca/mthca_main.c
@@ -1271,8 +1271,8 @@
mthca_catas_cleanup();
}
-module_init_order(mthca_init, SI_ORDER_THIRD);
-module_exit(mthca_cleanup);
+module_init_order(mthca_init, SI_ORDER_SEVENTH);
+module_exit_order(mthca_cleanup, SI_ORDER_SEVENTH);
MODULE_VERSION(mthca, 1);
MODULE_DEPEND(mthca, ibcore, 1, 1, 1);
Index: sys/ofed/drivers/infiniband/core/ib_cm.c
===================================================================
--- sys/ofed/drivers/infiniband/core/ib_cm.c
+++ sys/ofed/drivers/infiniband/core/ib_cm.c
@@ -4180,5 +4180,5 @@
}
module_init_order(ib_cm_init, SI_ORDER_SECOND);
-module_exit_order(ib_cm_cleanup, SI_ORDER_FIRST);
+module_exit_order(ib_cm_cleanup, SI_ORDER_SECOND);
Index: sys/ofed/drivers/infiniband/core/ib_cma.c
===================================================================
--- sys/ofed/drivers/infiniband/core/ib_cma.c
+++ sys/ofed/drivers/infiniband/core/ib_cma.c
@@ -4619,5 +4619,5 @@
destroy_workqueue(cma_wq);
}
-module_init(cma_init);
-module_exit(cma_cleanup);
+module_init_order(cma_init, SI_ORDER_FOURTH);
+module_exit_order(cma_cleanup, SI_ORDER_FOURTH);
Index: sys/ofed/drivers/infiniband/core/ib_device.c
===================================================================
--- sys/ofed/drivers/infiniband/core/ib_device.c
+++ sys/ofed/drivers/infiniband/core/ib_device.c
@@ -1060,8 +1060,25 @@
destroy_workqueue(ib_wq);
}
-module_init(ib_core_init);
-module_exit(ib_core_cleanup);
+/*
+ * Typical loading and unloading order values and their use:
+ *
+ * SI_ORDER_FIRST (default for module_init):
+ * Core modules (PCI, infiniband)
+ * SI_ORDER_SECOND (default for module_exit):
+ * Infiniband core modules (CM)
+ * SI_ORDER_THIRD:
+ * SI_ORDER_FOURTH:
+ * Infiniband core modules (CMA)
+ * SI_ORDER_FIFTH:
+ * Infiniband user-space modules (UCM,UCMA,UMAD,UVERBS,IPOIB)
+ * SI_ORDER_SIXTH:
+ * Network HW driver modules
+ * SI_ORDER_SEVENTH:
+ * Infiniband HW driver modules
+ */
+module_init_order(ib_core_init, SI_ORDER_FIRST);
+module_exit_order(ib_core_cleanup, SI_ORDER_FIRST);
MODULE_VERSION(ibcore, 1);
MODULE_DEPEND(ibcore, linuxkpi, 1, 1, 1);
Index: sys/ofed/drivers/infiniband/core/ib_iwcm.c
===================================================================
--- sys/ofed/drivers/infiniband/core/ib_iwcm.c
+++ sys/ofed/drivers/infiniband/core/ib_iwcm.c
@@ -1052,5 +1052,5 @@
destroy_workqueue(iwcm_wq);
}
-module_init(iw_cm_init);
-module_exit(iw_cm_cleanup);
+module_init_order(iw_cm_init, SI_ORDER_FIRST);
+module_exit_order(iw_cm_cleanup, SI_ORDER_FIRST);
Index: sys/ofed/drivers/infiniband/core/ib_ucm.c
===================================================================
--- sys/ofed/drivers/infiniband/core/ib_ucm.c
+++ sys/ofed/drivers/infiniband/core/ib_ucm.c
@@ -1371,5 +1371,5 @@
idr_destroy(&ctx_id_table);
}
-module_init_order(ib_ucm_init, SI_ORDER_THIRD);
-module_exit(ib_ucm_cleanup);
+module_init_order(ib_ucm_init, SI_ORDER_FIFTH);
+module_exit_order(ib_ucm_cleanup, SI_ORDER_FIFTH);
Index: sys/ofed/drivers/infiniband/core/ib_ucma.c
===================================================================
--- sys/ofed/drivers/infiniband/core/ib_ucma.c
+++ sys/ofed/drivers/infiniband/core/ib_ucma.c
@@ -1782,5 +1782,5 @@
idr_destroy(&multicast_idr);
}
-module_init(ucma_init);
-module_exit(ucma_cleanup);
+module_init_order(ucma_init, SI_ORDER_FIFTH);
+module_exit_order(ucma_cleanup, SI_ORDER_FIFTH);
Index: sys/ofed/drivers/infiniband/core/ib_user_mad.c
===================================================================
--- sys/ofed/drivers/infiniband/core/ib_user_mad.c
+++ sys/ofed/drivers/infiniband/core/ib_user_mad.c
@@ -1405,5 +1405,5 @@
unregister_chrdev_region(overflow_maj, IB_UMAD_MAX_PORTS * 2);
}
-module_init_order(ib_umad_init, SI_ORDER_THIRD);
-module_exit(ib_umad_cleanup);
+module_init_order(ib_umad_init, SI_ORDER_FIFTH);
+module_exit_order(ib_umad_cleanup, SI_ORDER_FIFTH);
Index: sys/ofed/drivers/infiniband/core/ib_uverbs_main.c
===================================================================
--- sys/ofed/drivers/infiniband/core/ib_uverbs_main.c
+++ sys/ofed/drivers/infiniband/core/ib_uverbs_main.c
@@ -1431,5 +1431,5 @@
idr_destroy(&ib_uverbs_srq_idr);
}
-module_init_order(ib_uverbs_init, SI_ORDER_THIRD);
-module_exit(ib_uverbs_cleanup);
+module_init_order(ib_uverbs_init, SI_ORDER_FIFTH);
+module_exit_order(ib_uverbs_cleanup, SI_ORDER_FIFTH);
Index: sys/ofed/drivers/infiniband/ulp/ipoib/ipoib_main.c
===================================================================
--- sys/ofed/drivers/infiniband/ulp/ipoib/ipoib_main.c
+++ sys/ofed/drivers/infiniband/ulp/ipoib/ipoib_main.c
@@ -1753,8 +1753,8 @@
}
}
-module_init(ipoib_init_module);
-module_exit(ipoib_cleanup_module);
+module_init_order(ipoib_init_module, SI_ORDER_FIFTH);
+module_exit_order(ipoib_cleanup_module, SI_ORDER_FIFTH);
static int
ipoib_evhand(module_t mod, int event, void *arg)
Index: sys/ofed/drivers/infiniband/util/madeye.c
===================================================================
--- sys/ofed/drivers/infiniband/util/madeye.c
+++ sys/ofed/drivers/infiniband/util/madeye.c
@@ -594,5 +594,5 @@
ib_unregister_client(&madeye_client);
}
-module_init(ib_madeye_init);
-module_exit(ib_madeye_cleanup);
+module_init_order(ib_madeye_init, SI_ORDER_THIRD);
+module_exit_order(ib_madeye_cleanup, SI_ORDER_THIRD);

File Metadata

Mime Type
text/plain
Expires
Thu, Jan 16, 5:40 PM (20 h, 26 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15827127
Default Alt Text
D23973.diff (8 KB)

Event Timeline