Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/arm fdtbus_intr_establish -> fdtbus_intr_establish_...
details: https://anonhg.NetBSD.org/src/rev/ea02651b79a0
branches: trunk
changeset: 959022:ea02651b79a0
user: skrll <skrll%NetBSD.org@localhost>
date: Fri Jan 29 14:11:14 2021 +0000
description:
fdtbus_intr_establish -> fdtbus_intr_establish_xname
diffstat:
sys/arch/arm/altera/cycv_dwcmmc.c | 8 ++++----
sys/arch/arm/altera/cycv_gmac.c | 8 ++++----
sys/arch/arm/broadcom/bcm2835_bsc_fdt.c | 8 ++++----
sys/arch/arm/broadcom/bcm2835_com.c | 8 ++++----
sys/arch/arm/broadcom/bcm2835_dmac.c | 11 +++++++----
sys/arch/arm/broadcom/bcm2835_dwctwo.c | 8 ++++----
sys/arch/arm/broadcom/bcm2835_emmc.c | 8 ++++----
sys/arch/arm/broadcom/bcm2835_gpio.c | 14 ++++++++------
sys/arch/arm/broadcom/bcm2835_mbox_fdt.c | 8 ++++----
sys/arch/arm/broadcom/bcm2835_sdhost.c | 8 ++++----
sys/arch/arm/broadcom/bcm2835_spi.c | 8 ++++----
sys/arch/arm/broadcom/bcm2835_tmr.c | 8 ++++----
12 files changed, 55 insertions(+), 50 deletions(-)
diffs (truncated from 359 to 300 lines):
diff -r 5d325385b969 -r ea02651b79a0 sys/arch/arm/altera/cycv_dwcmmc.c
--- a/sys/arch/arm/altera/cycv_dwcmmc.c Fri Jan 29 13:10:07 2021 +0000
+++ b/sys/arch/arm/altera/cycv_dwcmmc.c Fri Jan 29 14:11:14 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cycv_dwcmmc.c,v 1.6 2021/01/27 03:10:18 thorpej Exp $ */
+/* $NetBSD: cycv_dwcmmc.c,v 1.7 2021/01/29 14:12:01 skrll Exp $ */
/*-
* Copyright (c) 2015 Jared D. McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cycv_dwcmmc.c,v 1.6 2021/01/27 03:10:18 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cycv_dwcmmc.c,v 1.7 2021/01/29 14:12:01 skrll Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -157,8 +157,8 @@
if (dwc_mmc_init(sc) != 0)
return;
- sc->sc_ih = fdtbus_intr_establish(phandle, 0, IPL_BIO, 0,
- dwc_mmc_intr, sc);
+ sc->sc_ih = fdtbus_intr_establish_xname(phandle, 0, IPL_BIO, 0,
+ dwc_mmc_intr, sc, device_xname(sc->sc_dev));
if (sc->sc_ih == NULL) {
aprint_error_dev(self, "couldn't establish interrupt on %s\n",
intrstr);
diff -r 5d325385b969 -r ea02651b79a0 sys/arch/arm/altera/cycv_gmac.c
--- a/sys/arch/arm/altera/cycv_gmac.c Fri Jan 29 13:10:07 2021 +0000
+++ b/sys/arch/arm/altera/cycv_gmac.c Fri Jan 29 14:11:14 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cycv_gmac.c,v 1.5 2021/01/27 03:10:18 thorpej Exp $ */
+/* $NetBSD: cycv_gmac.c,v 1.6 2021/01/29 14:12:01 skrll Exp $ */
/*-
* Copyright (c) 2017 Jared McNeill <jmcneill%invisible.ca@localhost>
@@ -30,7 +30,7 @@
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cycv_gmac.c,v 1.5 2021/01/27 03:10:18 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cycv_gmac.c,v 1.6 2021/01/29 14:12:01 skrll Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -132,8 +132,8 @@
aprint_naive("\n");
aprint_normal(": GMAC\n");
- if (fdtbus_intr_establish(phandle, 0, IPL_NET, DWCGMAC_FDT_INTR_MPSAFE,
- cycv_gmac_intr, sc) == NULL) {
+ if (fdtbus_intr_establish_xname(phandle, 0, IPL_NET, DWCGMAC_FDT_INTR_MPSAFE,
+ cycv_gmac_intr, sc, device_xname(sc->sc_dev)) == NULL) {
aprint_error_dev(self, "failed to establish interrupt on %s\n",
intrstr);
return;
diff -r 5d325385b969 -r ea02651b79a0 sys/arch/arm/broadcom/bcm2835_bsc_fdt.c
--- a/sys/arch/arm/broadcom/bcm2835_bsc_fdt.c Fri Jan 29 13:10:07 2021 +0000
+++ b/sys/arch/arm/broadcom/bcm2835_bsc_fdt.c Fri Jan 29 14:11:14 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm2835_bsc_fdt.c,v 1.5 2021/01/27 03:10:19 thorpej Exp $ */
+/* $NetBSD: bcm2835_bsc_fdt.c,v 1.6 2021/01/29 14:11:14 skrll Exp $ */
/*
* Copyright (c) 2019 Jason R. Thorpe
@@ -28,7 +28,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_bsc_fdt.c,v 1.5 2021/01/27 03:10:19 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_bsc_fdt.c,v 1.6 2021/01/29 14:11:14 skrll Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -118,8 +118,8 @@
aprint_error_dev(sc->sc_dev, "failed to decode interrupt\n");
return;
}
- sc->sc_inth = fdtbus_intr_establish(phandle, 0, IPL_VM,
- FDT_INTR_MPSAFE, bsciic_intr, sc);
+ sc->sc_inth = fdtbus_intr_establish_xname(phandle, 0, IPL_VM,
+ FDT_INTR_MPSAFE, bsciic_intr, sc, device_xname(sc->sc_dev));
if (sc->sc_inth == NULL) {
aprint_error_dev(sc->sc_dev,
"failed to establish interrupt %s\n", intrstr);
diff -r 5d325385b969 -r ea02651b79a0 sys/arch/arm/broadcom/bcm2835_com.c
--- a/sys/arch/arm/broadcom/bcm2835_com.c Fri Jan 29 13:10:07 2021 +0000
+++ b/sys/arch/arm/broadcom/bcm2835_com.c Fri Jan 29 14:11:14 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm2835_com.c,v 1.7 2021/01/27 03:10:19 thorpej Exp $ */
+/* $NetBSD: bcm2835_com.c,v 1.8 2021/01/29 14:11:14 skrll Exp $ */
/*-
* Copyright (c) 2017 Jared McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_com.c,v 1.7 2021/01/27 03:10:19 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_com.c,v 1.8 2021/01/29 14:11:14 skrll Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -116,8 +116,8 @@
return;
}
- ih = fdtbus_intr_establish(phandle, 0, IPL_SERIAL, FDT_INTR_MPSAFE,
- comintr, sc);
+ ih = fdtbus_intr_establish_xname(phandle, 0, IPL_SERIAL, FDT_INTR_MPSAFE,
+ comintr, sc, device_xname(sc->sc_dev));
if (ih == NULL) {
aprint_error_dev(self, "failed to establish interrupt %s\n",
intrstr);
diff -r 5d325385b969 -r ea02651b79a0 sys/arch/arm/broadcom/bcm2835_dmac.c
--- a/sys/arch/arm/broadcom/bcm2835_dmac.c Fri Jan 29 13:10:07 2021 +0000
+++ b/sys/arch/arm/broadcom/bcm2835_dmac.c Fri Jan 29 14:11:14 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm2835_dmac.c,v 1.18 2021/01/27 03:10:19 thorpej Exp $ */
+/* $NetBSD: bcm2835_dmac.c,v 1.19 2021/01/29 14:11:14 skrll Exp $ */
/*-
* Copyright (c) 2014 Jared D. McNeill <jmcneill%invisible.ca@localhost>
@@ -29,7 +29,7 @@
#include "opt_ddb.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_dmac.c,v 1.18 2021/01/27 03:10:19 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_dmac.c,v 1.19 2021/01/29 14:11:14 skrll Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -235,8 +235,11 @@
return NULL;
}
- ch->ch_ih = fdtbus_intr_establish(phandle, ch->ch_index, ipl, 0,
- bcm_dmac_intr, ch);
+ char xname[16];
+ snprintf(xname, sizeof(xname), "%s #%u", device_xname(sc->sc_dev),
+ ch->ch_index);
+ ch->ch_ih = fdtbus_intr_establish_xname(phandle, ch->ch_index, ipl, 0,
+ bcm_dmac_intr, ch, xname);
if (ch->ch_ih == NULL) {
aprint_error_dev(sc->sc_dev,
"failed to establish interrupt for DMA%d and %s\n", ch->ch_index,
diff -r 5d325385b969 -r ea02651b79a0 sys/arch/arm/broadcom/bcm2835_dwctwo.c
--- a/sys/arch/arm/broadcom/bcm2835_dwctwo.c Fri Jan 29 13:10:07 2021 +0000
+++ b/sys/arch/arm/broadcom/bcm2835_dwctwo.c Fri Jan 29 14:11:14 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm2835_dwctwo.c,v 1.9 2021/01/27 03:10:19 thorpej Exp $ */
+/* $NetBSD: bcm2835_dwctwo.c,v 1.10 2021/01/29 14:11:14 skrll Exp $ */
/*-
* Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_dwctwo.c,v 1.9 2021/01/27 03:10:19 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_dwctwo.c,v 1.10 2021/01/29 14:11:14 skrll Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -149,8 +149,8 @@
return;
}
- sc->sc_ih = fdtbus_intr_establish(phandle, 0, IPL_VM, FDT_INTR_MPSAFE,
- dwc2_intr, &sc->sc_dwc2);
+ sc->sc_ih = fdtbus_intr_establish_xname(phandle, 0, IPL_VM, FDT_INTR_MPSAFE,
+ dwc2_intr, &sc->sc_dwc2, device_xname(self));
if (sc->sc_ih == NULL) {
aprint_error_dev(self, "failed to establish interrupt %s\n",
diff -r 5d325385b969 -r ea02651b79a0 sys/arch/arm/broadcom/bcm2835_emmc.c
--- a/sys/arch/arm/broadcom/bcm2835_emmc.c Fri Jan 29 13:10:07 2021 +0000
+++ b/sys/arch/arm/broadcom/bcm2835_emmc.c Fri Jan 29 14:11:14 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm2835_emmc.c,v 1.42 2021/01/27 03:10:19 thorpej Exp $ */
+/* $NetBSD: bcm2835_emmc.c,v 1.43 2021/01/29 14:11:14 skrll Exp $ */
/*-
* Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_emmc.c,v 1.42 2021/01/27 03:10:19 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_emmc.c,v 1.43 2021/01/29 14:11:14 skrll Exp $");
#include "bcmdmac.h"
@@ -172,8 +172,8 @@
return;
}
- sc->sc_ih = fdtbus_intr_establish(phandle, 0, IPL_SDMMC, 0,
- sdhc_intr, &sc->sc);
+ sc->sc_ih = fdtbus_intr_establish_xname(phandle, 0, IPL_SDMMC, 0,
+ sdhc_intr, &sc->sc, device_xname(self));
if (sc->sc_ih == NULL) {
aprint_error_dev(self, "failed to establish interrupt %s\n",
diff -r 5d325385b969 -r ea02651b79a0 sys/arch/arm/broadcom/bcm2835_gpio.c
--- a/sys/arch/arm/broadcom/bcm2835_gpio.c Fri Jan 29 13:10:07 2021 +0000
+++ b/sys/arch/arm/broadcom/bcm2835_gpio.c Fri Jan 29 14:11:14 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm2835_gpio.c,v 1.18 2021/01/27 03:10:19 thorpej Exp $ */
+/* $NetBSD: bcm2835_gpio.c,v 1.19 2021/01/29 14:11:14 skrll Exp $ */
/*-
* Copyright (c) 2013, 2014, 2017 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_gpio.c,v 1.18 2021/01/27 03:10:19 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_gpio.c,v 1.19 2021/01/29 14:11:14 skrll Exp $");
/*
* Driver for BCM2835 GPIO
@@ -337,12 +337,14 @@
continue;
}
+ char xname[16];
+ snprintf(xname, sizeof(xname), "%s #%u", device_xname(self),
+ bank);
sc->sc_banks[bank].sc_bankno = bank;
sc->sc_banks[bank].sc_bcm = sc;
- sc->sc_banks[bank].sc_ih =
- fdtbus_intr_establish(phandle, bank, IPL_VM,
- FDT_INTR_MPSAFE,
- bcmgpio_intr, &sc->sc_banks[bank]);
+ sc->sc_banks[bank].sc_ih = fdtbus_intr_establish_xname(phandle,
+ bank, IPL_VM, FDT_INTR_MPSAFE, bcmgpio_intr,
+ &sc->sc_banks[bank], xname);
if (sc->sc_banks[bank].sc_ih) {
aprint_normal_dev(self,
"pins %d..%d interrupting on %s\n",
diff -r 5d325385b969 -r ea02651b79a0 sys/arch/arm/broadcom/bcm2835_mbox_fdt.c
--- a/sys/arch/arm/broadcom/bcm2835_mbox_fdt.c Fri Jan 29 13:10:07 2021 +0000
+++ b/sys/arch/arm/broadcom/bcm2835_mbox_fdt.c Fri Jan 29 14:11:14 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm2835_mbox_fdt.c,v 1.2 2021/01/27 03:10:19 thorpej Exp $ */
+/* $NetBSD: bcm2835_mbox_fdt.c,v 1.3 2021/01/29 14:11:14 skrll Exp $ */
/*-
* Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_mbox_fdt.c,v 1.2 2021/01/27 03:10:19 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_mbox_fdt.c,v 1.3 2021/01/29 14:11:14 skrll Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -99,8 +99,8 @@
aprint_naive("\n");
aprint_normal(": VC mailbox\n");
- sc->sc_intrh = fdtbus_intr_establish(phandle, 0, IPL_VM, 0,
- bcmmbox_intr, sc);
+ sc->sc_intrh = fdtbus_intr_establish_xname(phandle, 0, IPL_VM, 0,
+ bcmmbox_intr, sc, device_xname(self));
if (sc->sc_intrh == NULL) {
aprint_error_dev(self, "failed to establish interrupt %s\n",
intrstr);
diff -r 5d325385b969 -r ea02651b79a0 sys/arch/arm/broadcom/bcm2835_sdhost.c
--- a/sys/arch/arm/broadcom/bcm2835_sdhost.c Fri Jan 29 13:10:07 2021 +0000
+++ b/sys/arch/arm/broadcom/bcm2835_sdhost.c Fri Jan 29 14:11:14 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm2835_sdhost.c,v 1.7 2021/01/27 03:10:19 thorpej Exp $ */
+/* $NetBSD: bcm2835_sdhost.c,v 1.8 2021/01/29 14:11:14 skrll Exp $ */
/*-
* Copyright (c) 2017 Jared McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_sdhost.c,v 1.7 2021/01/27 03:10:19 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_sdhost.c,v 1.8 2021/01/29 14:11:14 skrll Exp $");
#include "bcmdmac.h"
@@ -243,8 +243,8 @@
return;
}
- sc->sc_ih = fdtbus_intr_establish(phandle, 0, IPL_SDMMC,
- FDT_INTR_MPSAFE, sdhost_intr, sc);
+ sc->sc_ih = fdtbus_intr_establish_xname(phandle, 0, IPL_SDMMC,
+ FDT_INTR_MPSAFE, sdhost_intr, sc, device_xname(self));
if (sc->sc_ih == NULL) {
aprint_error_dev(self, "failed to establish interrupt %s\n",
Home |
Main Index |
Thread Index |
Old Index