svn commit: r330440 - head/sys/arm/freescale/imx

Ian Lepore ian at FreeBSD.org
Mon Mar 5 02:32:24 UTC 2018


Author: ian
Date: Mon Mar  5 02:32:23 2018
New Revision: 330440
URL: https://svnweb.freebsd.org/changeset/base/330440

Log:
  Switch imx_gpio to attach at BUS_PASS_INTERRUPT + BUS_PASS_ORDER_LATE.
  Pretty much any other device might need to manipulate a gpio pin during its
  probe or attach routines, so these devices must be available as early as
  possible.
  
  The gpio device is an interrupt controller, but I didn't choose the
  INTERRUPT pass for that reason (it works fine as an interrupt controller as
  long as it attaches any time before interrupts are enabled).  That just
  looked like the right place in the passes to ensure that it attaches before
  any type of device that might need gpio pin manipulations.

Modified:
  head/sys/arm/freescale/imx/imx_gpio.c

Modified: head/sys/arm/freescale/imx/imx_gpio.c
==============================================================================
--- head/sys/arm/freescale/imx/imx_gpio.c	Mon Mar  5 02:28:25 2018	(r330439)
+++ head/sys/arm/freescale/imx/imx_gpio.c	Mon Mar  5 02:32:23 2018	(r330440)
@@ -868,5 +868,5 @@ static driver_t imx51_gpio_driver = {
 };
 static devclass_t imx51_gpio_devclass;
 
-DRIVER_MODULE(imx51_gpio, simplebus, imx51_gpio_driver, imx51_gpio_devclass,
-    0, 0);
+EARLY_DRIVER_MODULE(imx51_gpio, simplebus, imx51_gpio_driver,
+    imx51_gpio_devclass, 0, 0, BUS_PASS_INTERRUPT + BUS_PASS_ORDER_LATE);


More information about the svn-src-head mailing list