regulator: Disable FDT parts for non-FDT targets

This commit is contained in:
Christian Mauderer 2020-04-17 09:08:18 +02:00
parent db78c8c52f
commit a6cf310fb2
2 changed files with 4 additions and 0 deletions

View File

@ -51,7 +51,9 @@ __FBSDID("$FreeBSD$");
#endif
#include <dev/extres/regulator/regulator.h>
#if !defined(__rtems__) || defined(FDT)
#include <rtems/bsd/local/regdev_if.h>
#endif /* !__rtems__ || FDT */
SYSCTL_NODE(_hw, OID_AUTO, regulator, CTLFLAG_RD, NULL, "Regulators");

View File

@ -43,6 +43,7 @@ __FBSDID("$FreeBSD$");
#include <sys/module.h>
#include <sys/gpio.h>
#if !defined(__rtems__) || defined(FDT)
#include <dev/ofw/ofw_bus.h>
#include <dev/ofw/ofw_bus_subr.h>
@ -348,3 +349,4 @@ static devclass_t gpioregulator_devclass;
EARLY_DRIVER_MODULE(gpioregulator, simplebus, gpioregulator_driver,
gpioregulator_devclass, 0, 0, BUS_PASS_INTERRUPT + BUS_PASS_ORDER_LAST);
MODULE_VERSION(gpioregulator, 1);
#endif /* !__rtems__ || FDT */