diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2018-04-02 15:22:42 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2018-04-02 15:22:42 +0000 |
commit | 27c07c2068c4005e75fc92c5e472881148141397 (patch) | |
tree | e6070f4b57288564e3cba1a8685670ccfa7f7bdb /sys/arch | |
parent | 864c2350746e190381efa317d1e81dbb2cb41276 (diff) |
Do not add 32 to the "base" SPI number. Apparently the offset of the first
SPI is already included and adding 32 means we skip the first 32 available
MSI vectors, which is quite disastous if we only have 32 vectors like on
the Marvell Armada 8040.
ok patrick@
Diffstat (limited to 'sys/arch')
-rw-r--r-- | sys/arch/arm64/dev/ampintc.c | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/sys/arch/arm64/dev/ampintc.c b/sys/arch/arm64/dev/ampintc.c index 2091031902c..2c4ce63a150 100644 --- a/sys/arch/arm64/dev/ampintc.c +++ b/sys/arch/arm64/dev/ampintc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ampintc.c,v 1.13 2018/02/02 09:32:11 kettenis Exp $ */ +/* $OpenBSD: ampintc.c,v 1.14 2018/04/02 15:22:41 kettenis Exp $ */ /* * Copyright (c) 2007,2009,2011 Dale Rahn <drahn@openbsd.org> * @@ -176,8 +176,6 @@ void ampintc_setipl(int); void ampintc_calc_mask(void); void *ampintc_intr_establish(int, int, int, int (*)(void *), void *, char *); -void *ampintc_intr_establish_ext(int, int, int, int (*)(void *), - void *, char *); void *ampintc_intr_establish_fdt(void *, int *, int, int (*)(void *), void *, char *); void ampintc_intr_disestablish(void *); @@ -685,13 +683,6 @@ ampintc_irq_handler(void *frame) } void * -ampintc_intr_establish_ext(int irqno, int type, int level, int (*func)(void *), - void *arg, char *name) -{ - return ampintc_intr_establish(irqno+32, type, level, func, arg, name); -} - -void * ampintc_intr_establish_fdt(void *cookie, int *cell, int level, int (*func)(void *), void *arg, char *name) { @@ -892,13 +883,13 @@ ampintc_intr_establish_msi(void *self, uint64_t *addr, uint64_t *data, if (sc->sc_spi[i] != NULL) continue; - cookie = ampintc_intr_establish_ext(sc->sc_bspi + i, + cookie = ampintc_intr_establish(sc->sc_bspi + i, IST_EDGE_RISING, level, func, arg, name); if (cookie == NULL) return NULL; *addr = sc->sc_addr + GICV2M_SETSPI_NS; - *data = sc->sc_bspi + i + 32; + *data = sc->sc_bspi + i; sc->sc_spi[i] = cookie; return &sc->sc_spi[i]; } |