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
| ||
|
Date: Fri, 26 Apr 2013 19:15:26 +0200 From: Oleg Nesterov <oleg@...hat.com> To: "H. Peter Anvin" <hpa@...or.com> Cc: Ingo Molnar <mingo@...nel.org>, Linus Torvalds <torvalds@...ux-foundation.org>, Cyrill Gorcunov <gorcunov@...il.com>, Peter Zijlstra <a.p.zijlstra@...llo.nl>, Thomas Gleixner <tglx@...utronix.de>, David Miller <davem@...emloft.net>, "Theodore Ts'o" <tytso@....edu>, Linux Kernel Mailing List <linux-kernel@...r.kernel.org>, the arch/x86 maintainers <x86@...nel.org>, Network Development <netdev@...r.kernel.org>, "linux-ext4@...r.kernel.org" <linux-ext4@...r.kernel.org>, Fr??d??ric Weisbecker <fweisbec@...il.com> Subject: Re: [PATCH v2] x86: make DR*_RESERVED unsigned long On 04/26, H. Peter Anvin wrote: > > On 04/26/2013 09:38 AM, Oleg Nesterov wrote: > > > > - do_debug: > > > > dr6 &= ~DR6_RESERVED; > > > > this also wrongly clears 32-63 bits. Fortunately these > > bits are reserved and must be zero. > > I don't think this is wrongly at all. OK, I meant that it also clears the bits that are not specified in DR6_RESERVED mask. > The whole point is to mask out > the bits that the handler doesn't want to deal with, so masking out the > reserved bits [63:32] seems reasonable to me. Then we should do - #define DR6_RESERVED 0xFFFF0FF0 + #define DR6_RESERVED 0xFFFFFFFFFFFF0FF0 ? or what? (just in case, I will happily agree with "do nothing" ;) > The comment should probably be corrected, though. Which one? /* Define reserved bits in DR6 which are always set to 1 */ #define DR6_RESERVED (0xFFFF0FF0UL) /* Filter out all the reserved bits which are preset to 1 */ dr6 &= ~DR6_RESERVED; I guess both should be updated then. But if I read the doc correctly the lower reserved bits are set to 1. However do_debug() does set_debugreg(0, 6) and this looks correct, the doc says "debug handlers should clear the register before returning to the interrupted task". Oleg. -- To unsubscribe from this list: send the line "unsubscribe linux-ext4" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists