[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <d7d5035ad3b10befcd45476a4677f16fde5d1744.1391209433.git.luto@amacapital.net>
Date: Fri, 31 Jan 2014 15:04:18 -0800
From: Andy Lutomirski <luto@...capital.net>
To: x86@...nel.org, linux-kernel@...r.kernel.org
Cc: Andy Lutomirski <luto@...capital.net>
Subject: [PATCH] x86: Zero-pad the VVAR page with zeros
This has probably been broken since the VVAR page was introduced.
The symptom is that BIOS crud can be left behind where userspace can
see it. (I saw this with QEMU.)
Signed-off-by: Andy Lutomirski <luto@...capital.net>
---
arch/x86/kernel/vmlinux.lds.S | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/arch/x86/kernel/vmlinux.lds.S b/arch/x86/kernel/vmlinux.lds.S
index da6b35a..331a66f 100644
--- a/arch/x86/kernel/vmlinux.lds.S
+++ b/arch/x86/kernel/vmlinux.lds.S
@@ -165,6 +165,11 @@ SECTIONS
#undef __VVAR_KERNEL_LDS
#undef EMIT_VVAR
+ /*
+ * Pad the rest of the page with zeros. Otherwise the loader
+ * can leave garbage here.
+ */
+ . = __vvar_beginning_hack + PAGE_SIZE;
} :data
. = ALIGN(__vvar_page + PAGE_SIZE, PAGE_SIZE);
--
1.8.5.3
--
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