From: "Enrico Weigelt, metux IT consult" <info@metux.net>
To: linux-kernel@vger.kernel.org
Cc: mark.rutland@arm.com, dalias@libc.org,
linux-ia64@vger.kernel.org, linux-sh@vger.kernel.org,
alexander.shishkin@linux.intel.com, linus.walleij@linaro.org,
James.Bottomley@HansenPartnership.com, paulus@samba.org,
hpa@zytor.com, sparclinux@vger.kernel.org, will@kernel.org,
gerg@linux-m68k.org, linux-arch@vger.kernel.org,
linux-s390@vger.kernel.org, linux-c6x-dev@linux-c6x.org,
ysato@users.sourceforge.jp, jolsa@redhat.com, deller@gmx.de,
x86@kernel.org, bgolaszewski@baylibre.com, tony@atomide.com,
geert@linux-m68k.org, catalin.marinas@arm.com,
linux-alpha@vger.kernel.org, arnd@arndb.de, msalter@redhat.com,
jacquiot.aurelien@gmail.com, linux-gpio@vger.kernel.org,
linux-m68k@lists.linux-m68k.org, bp@alien8.de,
namhyung@kernel.org, tglx@linutronix.de,
linux-omap@vger.kernel.org, tsbogend@alpha.franken.de,
linux-parisc@vger.kernel.org, linux-mips@vger.kernel.org,
maz@kernel.org, linuxppc-dev@lists.ozlabs.org,
davem@davemloft.net
Subject: (repost) cleaning up handling of bad IRQs
Date: Fri, 18 Dec 2020 15:57:23 +0100 [thread overview]
Message-ID: <20201218145746.24205-1-info@metux.net> (raw)
Hello friends,
<< reposting, since first queue didn't go through completely, due to mailer problem >>
here's a patch queue for cleaning up the IRQ handling. Inspired by a
discussion we had on a previous patch of mine:
"arch: fix 'unexpected IRQ trap at vector' warnings"
https://www.spinics.net/lists/kernel/msg3763137.html
Turned out that the whole message, as it is right now, doesn't make much
sense at at all - not just incorrect wording, but also not quite useful
information. And the whole ack_bad_irq() thing deserves a cleanup anyways.
So, I've had a closer look and came to these conclusions:
1. The warning message doesn't need to be duplicated in the per architecture
ack_bad_irq() functions. All, but one callers already do their own warning.
Thus just adding a pr_warn() call there, printing out more useful data
like the hardware IRQ number, and dropping all warnings from all the
ack_bad_irq() functions.
2. Many of the ack_bad_irq()'s count up the spurious interrupts - lots of
duplications over the various archs. Some of them using atomic_t, some
just plain ints. Consolidating this by introducing a global counter
with inline'd accessors and doing the upcounting in the (currently 3)
call sites of ack_bad_irq(). After that, step by step changing all
archs to use the new counter.
3. For all but one arch (x86), ack_bad_irq() became a no-op.
On x86, it's just a call to ack_APIC_irq(), in order to prevent lockups
when IRQs missed to be ack'ed on the APIC. Could we perhaps do this in
some better place ? In that case, ack_bad_irq() could easily be removed
entirely.
have fun,
--mtx
next reply other threads:[~2020-12-18 15:17 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-18 14:57 Enrico Weigelt, metux IT consult [this message]
2020-12-18 14:57 ` [PATCH 01/23] kernel: irq: irqdescs: warn on spurious IRQ Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 02/23] arch: alpha: drop misleading warning " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 03/23] arch: arm: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 04/23] arch: c6x: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 05/23] arch: ia64: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 06/23] arch: mips: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 07/23] arch: parisc: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 08/23] arch: powerpc: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 09/23] arch: s390: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 10/23] arch: sh: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 11/23] arch: sparc: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 12/23] arch: x86: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 13/23] arch: generic: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 14/23] kernel: generic counter for interrupt errors Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 15/23] arch: mips: use generic irq error counter Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 16/23] arch: alpha: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 17/23] arch: arm: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 18/23] arch: arm64: " Enrico Weigelt, metux IT consult
2020-12-18 14:57 ` [PATCH 19/23] arch: c6x: " Enrico Weigelt, metux IT consult
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201218145746.24205-1-info@metux.net \
--to=info@metux.net \
--cc=James.Bottomley@HansenPartnership.com \
--cc=alexander.shishkin@linux.intel.com \
--cc=arnd@arndb.de \
--cc=bgolaszewski@baylibre.com \
--cc=bp@alien8.de \
--cc=catalin.marinas@arm.com \
--cc=dalias@libc.org \
--cc=davem@davemloft.net \
--cc=deller@gmx.de \
--cc=geert@linux-m68k.org \
--cc=gerg@linux-m68k.org \
--cc=hpa@zytor.com \
--cc=jacquiot.aurelien@gmail.com \
--cc=jolsa@redhat.com \
--cc=linus.walleij@linaro.org \
--cc=linux-alpha@vger.kernel.org \
--cc=linux-arch@vger.kernel.org \
--cc=linux-c6x-dev@linux-c6x.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-ia64@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-m68k@lists.linux-m68k.org \
--cc=linux-mips@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=linux-parisc@vger.kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=linux-sh@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=mark.rutland@arm.com \
--cc=maz@kernel.org \
--cc=msalter@redhat.com \
--cc=namhyung@kernel.org \
--cc=paulus@samba.org \
--cc=sparclinux@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=tony@atomide.com \
--cc=tsbogend@alpha.franken.de \
--cc=will@kernel.org \
--cc=x86@kernel.org \
--cc=ysato@users.sourceforge.jp \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).