public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] x86: vm86 - hide X86_VM_MASK from userland programs
@ 2008-04-24  8:35 Cyrill Gorcunov
  2008-04-24  8:39 ` David Woodhouse
  0 siblings, 1 reply; 3+ messages in thread
From: Cyrill Gorcunov @ 2008-04-24  8:35 UTC (permalink / raw)
  To: Ingo Molnar, H. Peter Anvin, David Woodhouse; +Cc: LKML

X86_VM_MASK is a kernel specific flag so lets hide it from
userland programs

Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
---

Index: linux-2.6.git/include/asm-x86/vm86.h
===================================================================
--- linux-2.6.git.orig/include/asm-x86/vm86.h	2008-04-23 22:38:58.000000000 +0400
+++ linux-2.6.git/include/asm-x86/vm86.h	2008-04-24 12:31:53.000000000 +0400
@@ -14,12 +14,16 @@
 
 #include <asm/processor-flags.h>
 
+#ifdef __KERNEL__
+
 #ifdef CONFIG_VM86
 #define X86_VM_MASK	X86_EFLAGS_VM
 #else
 #define X86_VM_MASK	0 /* No VM86 support */
 #endif
 
+#endif /* __KERNEL__ */
+
 #define BIOSSEG		0x0f000
 
 #define CPU_086		0

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] x86: vm86 - hide X86_VM_MASK from userland programs
  2008-04-24  8:35 [PATCH] x86: vm86 - hide X86_VM_MASK from userland programs Cyrill Gorcunov
@ 2008-04-24  8:39 ` David Woodhouse
  2008-04-24  8:42   ` Cyrill Gorcunov
  0 siblings, 1 reply; 3+ messages in thread
From: David Woodhouse @ 2008-04-24  8:39 UTC (permalink / raw)
  To: Cyrill Gorcunov; +Cc: Ingo Molnar, H. Peter Anvin, LKML

On Thu, 2008-04-24 at 12:35 +0400, Cyrill Gorcunov wrote:
> X86_VM_MASK is a kernel specific flag so lets hide it from
> userland programs
> 
> Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>

Since and there's already an #ifdef __KERNEL__ section later on in the
file, and since X86_VM_MASK isn't used before that, I probably would
have been inclined to shift it down there instead of adding a new
#ifdef.

But maybe I should just stop heckling... :)

-- 
dwmw2


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] x86: vm86 - hide X86_VM_MASK from userland programs
  2008-04-24  8:39 ` David Woodhouse
@ 2008-04-24  8:42   ` Cyrill Gorcunov
  0 siblings, 0 replies; 3+ messages in thread
From: Cyrill Gorcunov @ 2008-04-24  8:42 UTC (permalink / raw)
  To: David Woodhouse; +Cc: Ingo Molnar, H. Peter Anvin, LKML

[David Woodhouse - Thu, Apr 24, 2008 at 09:39:24AM +0100]
| On Thu, 2008-04-24 at 12:35 +0400, Cyrill Gorcunov wrote:
| > X86_VM_MASK is a kernel specific flag so lets hide it from
| > userland programs
| > 
| > Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
| 
| Since and there's already an #ifdef __KERNEL__ section later on in the
| file, and since X86_VM_MASK isn't used before that, I probably would
| have been inclined to shift it down there instead of adding a new
| #ifdef.
| 
| But maybe I should just stop heckling... :)
| 
| -- 
| dwmw2
| 

I was thought about that too ;) David, I'll recheck this
all today evening (have to go to office now). And please
continue heckling - it allows to make this file in particular
*better*, so I think it's ok ;)

		- Cyrill -

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2008-04-24  8:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-04-24  8:35 [PATCH] x86: vm86 - hide X86_VM_MASK from userland programs Cyrill Gorcunov
2008-04-24  8:39 ` David Woodhouse
2008-04-24  8:42   ` Cyrill Gorcunov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox