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]
Message-ID: <20101003201139.GA16532@liondog.tnic>
Date:	Sun, 3 Oct 2010 22:11:39 +0200
From:	Borislav Petkov <bp@...en8.de>
To:	"H. Peter Anvin" <hpa@...or.com>
Cc:	Ingo Molnar <mingo@...e.hu>, Thomas Gleixner <tglx@...utronix.de>,
	lkml <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] x86, cpu: X86_FEATURE_NOPL should be disabled on
 32-bit only

From: "H. Peter Anvin" <hpa@...or.com>
Date: Sun, Oct 03, 2010 at 11:19:18AM -0700

> I think we actually need to set it on 64 bits.

Ok, correct me if I'm wrong but I think it is already "indirectly" set
on 64-bits through REQUIRED_MASK3:

#define REQUIRED_MASK3  (NEED_NOPL)

which is defined as

#define NEED_NOPL      (1<<(X86_FEATURE_NOPL & 31))

when either CONFIG_X86_P6_NOP or CONFIG_X86_64 are selected.

and cpu_has() does

#define cpu_has(c, bit)                                                 \
        (__builtin_constant_p(bit) &&                                   \
	...
           (((bit)>>5)==3 && (1UL<<((bit)&31) & REQUIRED_MASK3)) ||     \
	...
	? 1 : test_cpu_cap(c, bit))

which returns 1 when testing for X86_FEATURE_NOPL, no?

-- 
Regards/Gruss,
    Boris.
--
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