summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2018-02-06 09:29:49 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2018-02-06 09:56:35 +0100
commit2275776d21768c18570a2a4bf7d8b2fff8088dc5 (patch)
tree531d27beb45a8df1021c094845571993408a5320
parentb79c025a1232f93323670bf2f508d0f1d2c23609 (diff)
downloadrtems-libbsd-2275776d21768c18570a2a4bf7d8b2fff8088dc5.tar.bz2
dwc_otg: Default to USB host mode
In case no "dr_mode" property is present in the device tree, then default to USB host mode. This is necessary to support the Cyclone V SoC Development Kit.
-rw-r--r--freebsd/sys/dev/usb/controller/dwc_otg_fdt.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/freebsd/sys/dev/usb/controller/dwc_otg_fdt.c b/freebsd/sys/dev/usb/controller/dwc_otg_fdt.c
index 4acbfa4c..791d9890 100644
--- a/freebsd/sys/dev/usb/controller/dwc_otg_fdt.c
+++ b/freebsd/sys/dev/usb/controller/dwc_otg_fdt.c
@@ -110,6 +110,8 @@ dwc_otg_attach(device_t dev)
device_printf(dev, "Invalid FDT dr_mode: %s\n",
usb_mode);
}
+ } else {
+ sc->sc_otg.sc_mode = DWC_MODE_HOST;
}
/* get all DMA memory */