lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 2 Nov 2008 22:23:13 +0000
From:	"Matt Fleming" <mjf@...too.org>
To:	"Will Newton" <will.newton@...il.com>
Cc:	linux-kernel@...r.kernel.org, tglx@...utronix.de, mingo@...e.hu,
	venkatesh.pallipadi@...el.com
Subject: Re: [PATCH 2/3] HPET: Enter hpet_interrupt_handler with interrupts disabled

2008/11/2 Will Newton <will.newton@...il.com>:
>
> Combining IRQF_DISABLED and IRQF_SHARED does not reliably disable
> interrupts in the handler. Perhaps IRQF_SHARED should be removed at
> the same time?
>

I didn't know that. Under what conditions is it unreliable?

I've attached a second attempt at this patch. It seems that the IRQ is
never shared anyway, so I followed your suggestion and removed
IRQF_SHARED. My machine seems to be running fine.

>From c445728f36de599770088e345fc03ef9fafd8470 Mon Sep 17 00:00:00 2001
From: Matt Fleming <mjf@...too.org>
Date: Sun, 2 Nov 2008 14:00:23 +0000
Subject: [PATCH 2/3] HPET: Enter hpet_interrupt_handler with interrupts disabled

Some functions that may be called from this handler require that
interrupts are disabled. Also, combining IRQF_DISABLED and
IRQF_SHARED does not reliably disable interrupts in a handler, so
remove IRQF_SHARED from the irq flags (this irq is not shared anyway).

Signed-off-by: Matt Fleming <mjf@...too.org>
---
 arch/x86/kernel/hpet.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/x86/kernel/hpet.c b/arch/x86/kernel/hpet.c
index f10f946..bfb17f4 100644
--- a/arch/x86/kernel/hpet.c
+++ b/arch/x86/kernel/hpet.c
@@ -445,7 +445,7 @@ static int hpet_setup_irq(struct hpet_dev *dev)
 {

        if (request_irq(dev->irq, hpet_interrupt_handler,
-                       IRQF_SHARED|IRQF_NOBALANCING, dev->name, dev))
+                       IRQF_DISABLED|IRQF_NOBALANCING, dev->name, dev))
                return -1;

        disable_irq(dev->irq);
--
1.5.6.4

Download attachment "0002-HPET-Enter-hpet_interrupt_handler-with-interrupts-d.patch" of type "application/octet-stream" (1054 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ