x86: fold _PAGE_GLOBAL into __PAGE_KERNEL
PATCH 1/1 x86: fold _PAGE_GLOBAL into __PAGE_KERNEL
With the iounmap problem resolved, it should be OK to always set _PAGE_GLOBAL in __PAGE_KERNEL*.
[ Did this patch cause problems before? ]
---arch/x86/mm/ioremap_64.c | 2 +-include/asm-x86/pgtable.h | 27 ++++++++++-----------------
2 files changed, 11 insertions(+), 18 deletions(-)
arch/x86/mm/ioremap_64.c +0 -0
@@ -79,7 +79,7 @@ void __iomem * __ioremap(unsigned long p
if (!size || last_addr < phys_addr) return NULL;
- pgprot = __pgprot(__PAGE_KERNEL_EXEC | _PAGE_GLOBAL | flags);
+ pgprot = __pgprot(__PAGE_KERNEL_EXEC | flags); /* * Mappings have to be page-aligned */
include/asm-x86/pgtable.h +0 -0
@@ -78,7 +78,7 @@ extern unsigned long long __PAGE_KERNEL,
#endif /* __ASSEMBLY__ */
#else
#define __PAGE_KERNEL_EXEC \
- (_PAGE_PRESENT | _PAGE_RW | _PAGE_DIRTY | _PAGE_ACCESSED) + (_PAGE_PRESENT | _PAGE_RW | _PAGE_DIRTY | _PAGE_ACCESSED | _PAGE_GLOBAL)
#define __PAGE_KERNEL (__PAGE_KERNEL_EXEC | _PAGE_NX)
#endif
@@ -90,21 +90,15 @@ extern unsigned long long __PAGE_KERNEL,
#define __PAGE_KERNEL_LARGE (__PAGE_KERNEL | _PAGE_PSE)
#define __PAGE_KERNEL_LARGE_EXEC (__PAGE_KERNEL_EXEC | _PAGE_PSE)
-#ifdef CONFIG_X86_32
-# define MAKE_GLOBAL(x) __pgprot((x))
-#else
-# define MAKE_GLOBAL(x) __pgprot((x) | _PAGE_GLOBAL)
-#endif
-
-#define PAGE_KERNEL MAKE_GLOBAL(__PAGE_KERNEL)
-#define PAGE_KERNEL_RO MAKE_GLOBAL(__PAGE_KERNEL_RO)
-#define PAGE_KERNEL_EXEC MAKE_GLOBAL(__PAGE_KERNEL_EXEC)
-#define PAGE_KERNEL_RX MAKE_GLOBAL(__PAGE_KERNEL_RX)
-#define PAGE_KERNEL_NOCACHE MAKE_GLOBAL(__PAGE_KERNEL_NOCACHE)
-#define PAGE_KERNEL_LARGE MAKE_GLOBAL(__PAGE_KERNEL_LARGE)
-#define PAGE_KERNEL_LARGE_EXEC MAKE_GLOBAL(__PAGE_KERNEL_LARGE_EXEC)
-#define PAGE_KERNEL_VSYSCALL MAKE_GLOBAL(__PAGE_KERNEL_VSYSCALL)
-#define PAGE_KERNEL_VSYSCALL_NOCACHE MAKE_GLOBAL(__PAGE_KERNEL_VSYSCALL_NOCACHE)
+#define PAGE_KERNEL __pgprot(__PAGE_KERNEL)
+#define PAGE_KERNEL_RO __pgprot(__PAGE_KERNEL_RO)
+#define PAGE_KERNEL_EXEC __pgprot(__PAGE_KERNEL_EXEC)
+#define PAGE_KERNEL_RX __pgprot(__PAGE_KERNEL_RX)
+#define PAGE_KERNEL_NOCACHE __pgprot(__PAGE_KERNEL_NOCACHE)
+#define PAGE_KERNEL_LARGE __pgprot(__PAGE_KERNEL_LARGE)
+#define PAGE_KERNEL_LARGE_EXEC __pgprot(__PAGE_KERNEL_LARGE_EXEC)
+#define PAGE_KERNEL_VSYSCALL __pgprot(__PAGE_KERNEL_VSYSCALL)
+#define PAGE_KERNEL_VSYSCALL_NOCACHE __pgprot(__PAGE_KERNEL_VSYSCALL_NOCACHE)
/* xwr */
#define __P000 PAGE_NONE
Quoted 2 lines · Jeremy Fitzhardinge
With the iounmap problem resolved, it should be OK to always set
_PAGE_GLOBALin __PAGE_KERNEL*.
thanks Jeremy, applied.
Quoted 1 line
[ Did this patch cause problems before? ]
not that i remember.
Ingo
kernel: EDAC e752x: Non-Fatal Error PCI Express B
I am using this kernel and this OS on PC Dell SMT670 with processor Intel Corporation E7525
Linux l2.6.22-3-686 #1 SMP Mon Oct 22 22:11:56 UTC 2007 i686 GNU/Linux Debian GNU/Linux lenny/sid
When i am using the printer with the application acroread and evince , sometimes i have no response and I have this error
root@lyonesse:~# cat /var/log/syslog | grep EDAC Jan 17 11:04:08 lyonesse kernel: EDAC e752x: Non-Fatal Error PCI Express B Jan 17 11:04:09 lyonesse kernel: EDAC e752x: Non-Fatal Error PCI Express B
and the other one
root@troie:~# cat /var/log/syslog | grep EDAC Jan 17 15:08:18 troie kernel: EDAC MC: Ver: 2.0.1 Oct 22 2007 Jan 17 15:08:18 troie kernel: EDAC e752x: tolm = 40000, remapbase = ffc000, remaplimit = 0 Jan 17 15:08:18 troie kernel: EDAC MC0: Giving out device to e752x_edac E7525: DEV 0000:00:00.0
Antares
_________________________________________________________________
Microsoft vous offre un logiciel pour classer, retoucher et partager vos photos !
http://www.windowslive.fr/galerie/