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:	Wed, 13 Aug 2008 19:35:08 +0200
From:	Ingo Molnar <mingo@...e.hu>
To:	"H. Peter Anvin" <hpa@...or.com>
Cc:	Mark Langsdorf <mark.langsdorf@....com>,
	linux-kernel@...r.kernel.org,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Thomas Gleixner <tglx@...utronix.de>
Subject: Re: invalidate caches before going into suspend


* H. Peter Anvin <hpa@...or.com> wrote:

> Ingo Molnar wrote:
>>>>
>>> Spurious interrupt of what kind?  The only things that could come in  
>>> would not be non-INT type interrupts, and those aren't affected by  
>>> CLI.
>>
>> nothing should come in really at that point - but say IRQ#7 on older  
>> platforms used to trigger at various points in time, even unprompted. 
>> Or an APIC error interrupt in the last moment? All device irqs should  
>> indeed be turned off at this stage, but since it costs us nothing to 
>> add another cli, and because the failure mode is subtle memory 
>> corruption, does it hurt to have it?
>>
>
> Not significantly, but I cannot for my life figure out how it could 
> help.
>
> Either the interrupts will be blocked by the CLI already in effect, or 
> the additional CLI will not help, either (in fact, it will just 
> slightly increase the window for something like that to slip in.)

ah, the main point i tried to make was to have the CLI _before_ the 
WBINVD - which Mark's patch didnt do.

Note the original sequence:

        wbinvd();
        mb();
        /* Ack it */
        __get_cpu_var(cpu_state) = CPU_DEAD;

        /*
         * With physical CPU hotplug, we should halt the cpu
         */
        local_irq_disable();

and Mark's patched sequence:

        wbinvd();
        local_irq_disable();
        while (1)
                halt();
 
both had wbinvd before the cli.

in my suggestion the second cli doesnt matter indeed - a single one 
suffices.

	Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ