summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bsd_eth_drivers/libbsdport/alldrv.c27
1 files changed, 25 insertions, 2 deletions
diff --git a/bsd_eth_drivers/libbsdport/alldrv.c b/bsd_eth_drivers/libbsdport/alldrv.c
index 76aac41..cd199fd 100644
--- a/bsd_eth_drivers/libbsdport/alldrv.c
+++ b/bsd_eth_drivers/libbsdport/alldrv.c
@@ -1,16 +1,39 @@
#include <stdio.h>
#include "libbsdport_api.h"
+#include "devicet.h"
driver_t *libbsdport_netdriver_table_all[] = {
- &libbsdport_bge_driver,
&libbsdport_em_driver,
&libbsdport_pcn_driver,
&libbsdport_le_pci_driver,
+ &libbsdport_fxp_driver,
+ &libbsdport_bge_driver,
&libbsdport_re_driver,
0
};
-/* weak alias defaults to a table that includes all currently supported drivers */
+driver_t libbsdport_null_driver = {0};
+
+extern driver_t libbsdport_em_driver
+ __attribute__((weak,alias("libbsdport_null_driver")));
+extern driver_t libbsdport_pcn_driver
+ __attribute__((weak,alias("libbsdport_null_driver")));
+extern driver_t libbsdport_le_pci_driver
+ __attribute__((weak,alias("libbsdport_null_driver")));
+extern driver_t libbsdport_fxp_driver
+ __attribute__((weak,alias("libbsdport_null_driver")));
+extern driver_t libbsdport_bge_driver
+ __attribute__((weak,alias("libbsdport_null_driver")));
+extern driver_t libbsdport_re_driver
+ __attribute__((weak,alias("libbsdport_null_driver")));
+
+
+/* weak alias defaults to a table that includes
+ * all currently supported drivers.
+ *
+ * However, the individual entires are weak aliases
+ * themselves so that you don't have to link all drivers...
+ */
extern driver_t *libbsdport_netdriver_table
[
sizeof(libbsdport_netdriver_table_all)/sizeof(libbsdport_netdriver_table_all[0])