-# $OpenBSD: GENERIC,v 1.70 2017/01/03 19:57:01 kettenis Exp $
+# $OpenBSD: GENERIC,v 1.82 2017/03/24 20:31:58 patrick Exp $
#
# For further information on compiling OpenBSD kernels, see the config(8)
# man page.
option CONF_HAVE_GPIO
option USBVERBOSE
+option DDB_STRUCT
+option DDB_SAFE_CONSOLE
+
config bsd swap generic
# The main bus device
# OMAP on-chip devices
intc* at fdt? # OMAP3 interrupt controller
omwugen* at fdt? # Wake-up generator
-#edma* at omap? # OMAP3 dma controller
+#edma* at fdt? # OMAP3 dma controller
prcm* at omap? # power/clock controller
ompinmux* at fdt? # pin muxing
omdog* at fdt? # watchdog timer
virtio* at fdt?
psci* at fdt?
+syscon* at fdt?
simplefb* at fdt?
wsdisplay* at simplefb?
# Exynos
-exynos0 at mainbus?
-exdisplay* at exynos?
-wsdisplay* at exdisplay? console ?
-exclock* at exynos?
-expower* at exynos?
-exsysreg* at exynos?
-exmct* at exynos?
-exdog* at exynos?
-exgpio* at exynos?
-exiic* at exynos?
+#exdisplay* at exynos?
+#wsdisplay* at exdisplay? console ?
+exclock* at fdt? early 1
+expower* at fdt? early 1
+exsysreg* at fdt? early 1
+exmct* at fdt? early 1
+exdog* at fdt?
+exgpio* at fdt? early 1
+exiic* at fdt?
iic* at exiic?
-exehci* at exynos?
-ehci* at exehci?
-exesdhc* at exynos?
+exehci* at fdt?
+usb* at exehci?
+exdwusb* at fdt?
+xhci* at fdt?
+usb* at xhci?
+exesdhc* at fdt?
sdmmc* at exesdhc?
+exrtc* at fdt?
exuart* at fdt?
# Raspberry Pi 2/3
bcmintc* at fdt?
+bcmdog* at fdt?
dwctwo* at fdt?
usb* at dwctwo?
mvagc* at fdt?
mvsysctrl* at fdt?
mvmbus* at fdt?
+mvxhci* at fdt?
+usb* at mvxhci?
+mvahci* at fdt?
crosec* at iic?
wskbd* at crosec? mux 1
struct fdt_attach_args *faa = args;
uint32_t rev, phy_reg[2];
- int phy_node;
-
- phy_node = -1;
+ int phy_node = -1, irq;
sc->sc_iot = faa->fa_iot;
&sc->sc_ioh_ctl))
panic("%s: bus_space_map failed!", __func__);
+ irq = faa->fa_intr[0];
+ sc->sc_ih = arm_intr_establish(irq, IPL_BIO, ammusb_intr, sc, DEVNAME(sc));
+
/* not the right revision number XXX */
rev = HREAD4(sc, sc->sc_ioh_ctl, 0x0);
printf(": rev %d.%d\n", rev >> 4 &0xf, rev & 0xf);
struct amusbss_softc {
struct device sc_dev;
+// struct simplebus_softc sc_sbus;
bus_space_tag_t sc_iot;
void *sc_ih;
bus_dma_tag_t sc_dmat;
bus_size_t sc_ios_queue;
};
+/* XXX figure out what to do instead of this XXX */
+extern void simplebus_attach_node(struct device *, int);
+
/* core decl */
int amusbss_match(struct device *, void *, void *);
void amusbss_attach(struct device *, struct device *, void *);
rev = HREAD4(sc, USBSS_REVREG);
printf(": rev %d.%d\n", rev >> 4 &0xf, rev & 0xf);
+ //faa->fa_node = node;
+ //simplebus_attach(parent, &sc->sc_sbus.sc_dev, faa);
+
/* Walk FDT child nodes to attach ammusb devices, map DMA controllers */
for (node = OF_child(faa->fa_node); node > 0; node = OF_peer(node)) {
if (OF_is_compatible(node, "ti,am3359-cppi41")) {