svn commit: r338025 - head/sys/dev/bge

Dimitry Andric dim at FreeBSD.org
Sat Aug 18 20:41:45 UTC 2018


Author: dim
Date: Sat Aug 18 20:41:43 2018
New Revision: 338025
URL: https://svnweb.freebsd.org/changeset/base/338025

Log:
  Use the size of one bge_devs element for the MODULE_PNP_INFO macro,
  instead of the size of the whole bge_devs array.
  
  This should stop kldxref searching beyond the end of .rodata when it
  processes relocations, and emitting "unhandled relocation type" errors,
  at least on i386.

Modified:
  head/sys/dev/bge/if_bge.c

Modified: head/sys/dev/bge/if_bge.c
==============================================================================
--- head/sys/dev/bge/if_bge.c	Sat Aug 18 20:35:19 2018	(r338024)
+++ head/sys/dev/bge/if_bge.c	Sat Aug 18 20:41:43 2018	(r338025)
@@ -548,7 +548,7 @@ static devclass_t bge_devclass;
 
 DRIVER_MODULE(bge, pci, bge_driver, bge_devclass, 0, 0);
 MODULE_PNP_INFO("U16:vendor;U16:device", pci, bge, bge_devs,
-    sizeof(bge_devs), nitems(bge_devs) - 1);
+    sizeof(bge_devs[0]), nitems(bge_devs) - 1);
 DRIVER_MODULE(miibus, bge, miibus_driver, miibus_devclass, 0, 0);
 
 static int bge_allow_asf = 1;


More information about the svn-src-all mailing list