[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <47C86D7A.5030608@goop.org>
Date: Fri, 29 Feb 2008 12:39:22 -0800
From: Jeremy Fitzhardinge <jeremy@...p.org>
To: Mathieu Desnoyers <mathieu.desnoyers@...ymtl.ca>,
Ingo Molnar <mingo@...e.hu>
CC: Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
"H. Peter Anvin" <hpa@...or.com>, Andi Kleen <ak@...e.de>,
Zachary Amsden <zach@...are.com>
Subject: bad paravirt/Xen interaction in "x86 - Enhance DEBUG_RODATA support
- alternatives"
The patch "x86 - Enhance DEBUG_RODATA support - alternatives" enables
the kernel for writing by clearing X86_CR0_WP allow privileged writes.
This won't work in a paravirt environment for two reasons:
1. the kernel may not be running in ring 0, so writes will still be
prevented
2. the hypervisor prevents X86_CR0_WP from being cleared anyway (it
GPFs the cr0 update)
This crashes on Xen, and it would probably break VMI too.
The only safe way to allow writes is to change the page permissions
(either on the page itself, or create a temporary writable alias for
that page). Perhaps something you could do it with kmap_atomic.
J
--
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