summaryrefslogtreecommitdiffstats
path: root/sys/arm
diff options
context:
space:
mode:
authorcognet <cognet@FreeBSD.org>2006-12-07 00:24:15 +0000
committercognet <cognet@FreeBSD.org>2006-12-07 00:24:15 +0000
commitae543684d058c95020933a38e6f021d595c6421a (patch)
tree3fbd608b37a514b9d67fb7d14048775f693aa70a /sys/arm
parentf5e17537588ec7e08c8f2f6d597c72e094eb5d14 (diff)
downloadFreeBSD-src-ae543684d058c95020933a38e6f021d595c6421a.zip
FreeBSD-src-ae543684d058c95020933a38e6f021d595c6421a.tar.gz
Unbreak build for Skyeye: do not attempt to do any DMA, as Skyeye doesn't
emulate it. Reported by: ru
Diffstat (limited to 'sys/arm')
-rw-r--r--sys/arm/at91/uart_dev_at91usart.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/sys/arm/at91/uart_dev_at91usart.c b/sys/arm/at91/uart_dev_at91usart.c
index eedcaaa..6f1199c 100644
--- a/sys/arm/at91/uart_dev_at91usart.c
+++ b/sys/arm/at91/uart_dev_at91usart.c
@@ -323,7 +323,10 @@ at91_getaddr(void *arg, bus_dma_segment_t *segs, int nsegs, int error)
static int
at91_usart_bus_attach(struct uart_softc *sc)
{
- int err, i;
+#ifndef SKYEYE_WORKAROUNDS
+ int err;
+ int i;
+#endif
uint32_t cr;
struct at91_usart_softc *atsc;
@@ -345,6 +348,7 @@ at91_usart_bus_attach(struct uart_softc *sc)
sc->sc_rxfifosz = USART_BUFFER_SIZE;
sc->sc_hwiflow = 0;
+#ifndef SKYEYE_WORKAROUNDS
/*
* Allocate DMA tags and maps
*/
@@ -374,6 +378,7 @@ at91_usart_bus_attach(struct uart_softc *sc)
atsc->ping = &atsc->ping_pong[0];
atsc->pong = &atsc->ping_pong[1];
}
+#endif
/*
* Prime the pump with the RX buffer. We use two 64 byte bounce
@@ -407,9 +412,13 @@ at91_usart_bus_attach(struct uart_softc *sc)
WR4(&sc->sc_bas, USART_IER, USART_CSR_RXRDY);
}
WR4(&sc->sc_bas, USART_IER, USART_CSR_RXBRK);
+#ifndef SKYEYE_WORKAROUNDS
errout:;
// XXX bad
return (err);
+#else
+ return (0);
+#endif
}
static int
OpenPOWER on IntegriCloud