mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] missing bit of non-executable data patch
@ 2002-09-28  4:34 Bjorn Helgaas
  0 siblings, 0 replies; only message in thread
From: Bjorn Helgaas @ 2002-09-28  4:34 UTC (permalink / raw)
  To: marcelo; +Cc: linux-kernel

Most of David Mosberger's work to allow data to be non-executable
by default is already in, but this bit appears to have been lost.
Note that all architectures except ia64 currently set the default
so data is executable, so this doesn't change behavior for anybody.

# This is a BitKeeper generated patch for the following project:
# Project Name: Linux kernel tree
# This patch format is intended for GNU patch command version 2.5 or higher.
# This patch includes the following deltas:
#	           ChangeSet	1.683   -> 1.684  
#	  include/linux/mm.h	1.39    -> 1.40   
#	include/asm-arm/page.h	1.4     -> 1.5    
#
# The following is the BitKeeper ChangeSet Log
# --------------------------------------------
# 02/09/20	bjorn_helgaas@hp.com	1.684
# Last bit of VM_DATA_DEFAULT_FLAGS patch (makes rights on a data
# page architecture-dependent).
# --------------------------------------------
#
diff -Nru a/include/asm-arm/page.h b/include/asm-arm/page.h
--- a/include/asm-arm/page.h	Fri Sep 20 16:13:54 2002
+++ b/include/asm-arm/page.h	Fri Sep 20 16:13:54 2002
@@ -106,6 +106,9 @@
 #define VALID_PAGE(page)	((page - mem_map) < max_mapnr)
 #endif
 
+#define VM_DATA_DEFAULT_FLAGS	(VM_READ | VM_WRITE | VM_EXEC | \
+				 VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC)
+
 #endif
 
 #endif
diff -Nru a/include/linux/mm.h b/include/linux/mm.h
--- a/include/linux/mm.h	Fri Sep 20 16:13:54 2002
+++ b/include/linux/mm.h	Fri Sep 20 16:13:54 2002
@@ -104,7 +104,7 @@
 #define VM_DONTEXPAND	0x00040000	/* Cannot expand with mremap() */
 #define VM_RESERVED	0x00080000	/* Don't unmap it from swap_out */
 
-#define VM_STACK_FLAGS	0x00000177
+#define VM_STACK_FLAGS			(VM_DATA_DEFAULT_FLAGS | VM_GROWSDOWN)
 
 #define VM_READHINTMASK			(VM_SEQ_READ | VM_RAND_READ)
 #define VM_ClearReadHint(v)		(v)->vm_flags &= ~VM_READHINTMASK

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2002-09-28  4:31 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-09-28  4:34 [PATCH] missing bit of non-executable data patch Bjorn Helgaas

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

all inboxes | Powered by JetHome®