From: Pingfan Liu <kernelfans@gmail.com> To: linux-kernel@vger.kernel.org Cc: Pingfan Liu <kernelfans@gmail.com>, Thomas Gleixner <tglx@linutronix.de>, Jisheng Zhang <Jisheng.Zhang@synaptics.com>, "Peter Zijlstra (Intel)" <peterz@infradead.org>, Vlastimil Babka <vbabka@suse.cz>, Andrew Morton <akpm@linux-foundation.org>, "Guilherme G. Piccoli" <gpiccoli@canonical.com>, Petr Mladek <pmladek@suse.com>, kexec@lists.infradead.org Subject: [PATCH 1/3] x86/irq: account the unused irq Date: Wed, 18 Nov 2020 11:36:16 +0800 [thread overview] Message-ID: <1605670578-23681-2-git-send-email-kernelfans@gmail.com> (raw) In-Reply-To: <1605670578-23681-1-git-send-email-kernelfans@gmail.com> Accounting the unused irq in order to count it if irq flood. Signed-off-by: Pingfan Liu <kernelfans@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Jisheng Zhang <Jisheng.Zhang@synaptics.com> Cc: "Peter Zijlstra (Intel)" <peterz@infradead.org> Cc: Vlastimil Babka <vbabka@suse.cz> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: "Guilherme G. Piccoli" <gpiccoli@canonical.com> Cc: Petr Mladek <pmladek@suse.com> Cc: kexec@lists.infradead.org To: linux-kernel@vger.kernel.org --- arch/x86/kernel/irq.c | 1 + include/linux/kernel_stat.h | 1 + 2 files changed, 2 insertions(+) diff --git a/arch/x86/kernel/irq.c b/arch/x86/kernel/irq.c index c5dd503..6f583a7 100644 --- a/arch/x86/kernel/irq.c +++ b/arch/x86/kernel/irq.c @@ -254,6 +254,7 @@ DEFINE_IDTENTRY_IRQ(common_interrupt) pr_emerg_ratelimited("%s: %d.%u No irq handler for vector\n", __func__, smp_processor_id(), vector); + __this_cpu_inc(kstat.unused_irqs_sum); } else { __this_cpu_write(vector_irq[vector], VECTOR_UNUSED); } diff --git a/include/linux/kernel_stat.h b/include/linux/kernel_stat.h index 89f0745..c8d5cb8 100644 --- a/include/linux/kernel_stat.h +++ b/include/linux/kernel_stat.h @@ -37,6 +37,7 @@ struct kernel_cpustat { struct kernel_stat { unsigned long irqs_sum; + unsigned long unused_irqs_sum; unsigned int softirqs[NR_SOFTIRQS]; }; -- 2.7.5
WARNING: multiple messages have this Message-ID (diff)
From: Pingfan Liu <kernelfans@gmail.com> To: linux-kernel@vger.kernel.org Cc: Petr Mladek <pmladek@suse.com>, "Peter Zijlstra (Intel)" <peterz@infradead.org>, "Guilherme G. Piccoli" <gpiccoli@canonical.com>, kexec@lists.infradead.org, Pingfan Liu <kernelfans@gmail.com>, Jisheng Zhang <Jisheng.Zhang@synaptics.com>, Thomas Gleixner <tglx@linutronix.de>, Andrew Morton <akpm@linux-foundation.org>, Vlastimil Babka <vbabka@suse.cz> Subject: [PATCH 1/3] x86/irq: account the unused irq Date: Wed, 18 Nov 2020 11:36:16 +0800 [thread overview] Message-ID: <1605670578-23681-2-git-send-email-kernelfans@gmail.com> (raw) In-Reply-To: <1605670578-23681-1-git-send-email-kernelfans@gmail.com> Accounting the unused irq in order to count it if irq flood. Signed-off-by: Pingfan Liu <kernelfans@gmail.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Jisheng Zhang <Jisheng.Zhang@synaptics.com> Cc: "Peter Zijlstra (Intel)" <peterz@infradead.org> Cc: Vlastimil Babka <vbabka@suse.cz> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: "Guilherme G. Piccoli" <gpiccoli@canonical.com> Cc: Petr Mladek <pmladek@suse.com> Cc: kexec@lists.infradead.org To: linux-kernel@vger.kernel.org --- arch/x86/kernel/irq.c | 1 + include/linux/kernel_stat.h | 1 + 2 files changed, 2 insertions(+) diff --git a/arch/x86/kernel/irq.c b/arch/x86/kernel/irq.c index c5dd503..6f583a7 100644 --- a/arch/x86/kernel/irq.c +++ b/arch/x86/kernel/irq.c @@ -254,6 +254,7 @@ DEFINE_IDTENTRY_IRQ(common_interrupt) pr_emerg_ratelimited("%s: %d.%u No irq handler for vector\n", __func__, smp_processor_id(), vector); + __this_cpu_inc(kstat.unused_irqs_sum); } else { __this_cpu_write(vector_irq[vector], VECTOR_UNUSED); } diff --git a/include/linux/kernel_stat.h b/include/linux/kernel_stat.h index 89f0745..c8d5cb8 100644 --- a/include/linux/kernel_stat.h +++ b/include/linux/kernel_stat.h @@ -37,6 +37,7 @@ struct kernel_cpustat { struct kernel_stat { unsigned long irqs_sum; + unsigned long unused_irqs_sum; unsigned int softirqs[NR_SOFTIRQS]; }; -- 2.7.5 _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec
next prev parent reply other threads:[~2020-11-18 3:37 UTC|newest] Thread overview: 49+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-10-22 5:56 [PATCH 0/3] warn and suppress irqflood Pingfan Liu 2020-10-22 5:56 ` Pingfan Liu 2020-10-22 5:56 ` [PATCH 1/3] kernel/watchdog: show irq percentage if irq floods Pingfan Liu 2020-10-22 5:56 ` Pingfan Liu 2020-10-22 5:56 ` [PATCH 2/3] kernel/watchdog: suppress max irq when " Pingfan Liu 2020-10-22 5:56 ` Pingfan Liu 2020-10-22 5:56 ` [PATCH 3/3] Documentation: introduce a param "irqflood_suppress" Pingfan Liu 2020-10-22 5:56 ` Pingfan Liu 2020-10-22 8:37 ` [PATCH 0/3] warn and suppress irqflood Thomas Gleixner 2020-10-22 8:37 ` Thomas Gleixner 2020-10-25 11:12 ` Pingfan Liu 2020-10-25 11:12 ` Pingfan Liu 2020-10-25 11:12 ` Pingfan Liu 2020-10-25 12:21 ` [Skiboot] " Oliver O'Halloran 2020-10-25 12:21 ` Oliver O'Halloran 2020-10-25 13:11 ` Pingfan Liu 2020-10-25 13:11 ` Pingfan Liu 2020-10-25 13:51 ` Oliver O'Halloran 2020-10-25 13:51 ` Oliver O'Halloran 2020-10-26 15:06 ` Guilherme Piccoli 2020-10-26 15:06 ` Guilherme Piccoli 2020-10-26 19:59 ` Thomas Gleixner 2020-10-26 19:59 ` Thomas Gleixner 2020-10-26 20:28 ` Guilherme Piccoli 2020-10-26 20:28 ` Guilherme Piccoli 2020-10-26 21:21 ` Thomas Gleixner 2020-10-26 21:21 ` Thomas Gleixner 2020-10-27 12:28 ` Guilherme Piccoli 2020-10-27 12:28 ` Guilherme Piccoli 2020-10-28 6:02 ` Pingfan Liu 2020-10-28 6:02 ` Pingfan Liu 2020-10-28 11:58 ` Thomas Gleixner 2020-10-28 11:58 ` Thomas Gleixner 2020-10-29 6:26 ` Pingfan Liu 2020-10-29 6:26 ` Pingfan Liu 2020-11-06 5:53 ` Pingfan Liu 2020-11-06 5:53 ` Pingfan Liu 2020-11-18 3:36 ` [PATCH 0/3] use soft lockup to detect irq flood Pingfan Liu 2020-11-18 3:36 ` Pingfan Liu 2020-11-18 3:36 ` Pingfan Liu [this message] 2020-11-18 3:36 ` [PATCH 1/3] x86/irq: account the unused irq Pingfan Liu 2020-11-18 3:36 ` [PATCH 2/3] kernel/watchdog: make watchdog_touch_ts more accurate by using nanosecond Pingfan Liu 2020-11-18 3:36 ` Pingfan Liu 2020-11-18 3:36 ` [PATCH 3/3] kernel/watchdog: use soft lockup to detect irq flood Pingfan Liu 2020-11-18 3:36 ` Pingfan Liu 2021-03-02 7:45 ` [PATCH 0/3] warn and suppress irqflood Sai Prakash Ranjan 2021-03-02 7:45 ` Sai Prakash Ranjan 2021-06-05 2:32 ` Sai Prakash Ranjan 2021-06-05 2:32 ` Sai Prakash Ranjan
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=1605670578-23681-2-git-send-email-kernelfans@gmail.com \ --to=kernelfans@gmail.com \ --cc=Jisheng.Zhang@synaptics.com \ --cc=akpm@linux-foundation.org \ --cc=gpiccoli@canonical.com \ --cc=kexec@lists.infradead.org \ --cc=linux-kernel@vger.kernel.org \ --cc=peterz@infradead.org \ --cc=pmladek@suse.com \ --cc=tglx@linutronix.de \ --cc=vbabka@suse.cz \ /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: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.