lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1323304882-27953-10-git-send-email-andi@firstfloor.org>
Date:	Wed,  7 Dec 2011 16:41:22 -0800
From:	Andi Kleen <andi@...stfloor.org>
To:	linux-kernel@...r.kernel.org
Cc:	kay.sievers@...y.org, trenn@...e.de,
	Andi Kleen <ak@...ux.intel.com>
Subject: [PATCH 09/10] x86: Add a test module for cpu loading

From: Andi Kleen <ak@...ux.intel.com>

Not for merging, but useful for testing.

Not-Signed-off: Andi Kleen <ak@...ux.intel.com>
---
 arch/x86/kernel/cpu/Makefile        |    2 ++
 arch/x86/kernel/cpu/test-cpu-load.c |   19 +++++++++++++++++++
 2 files changed, 21 insertions(+), 0 deletions(-)
 create mode 100644 arch/x86/kernel/cpu/test-cpu-load.c

diff --git a/arch/x86/kernel/cpu/Makefile b/arch/x86/kernel/cpu/Makefile
index 6ab6aa2..1af7e7b 100644
--- a/arch/x86/kernel/cpu/Makefile
+++ b/arch/x86/kernel/cpu/Makefile
@@ -48,3 +48,5 @@ cpufeature = $(src)/../../include/asm/cpufeature.h
 targets += capflags.c
 $(obj)/capflags.c: $(cpufeature) $(src)/mkcapflags.pl FORCE
 	$(call if_changed,mkcapflags)
+
+obj-m					+= test-cpu-load.o
diff --git a/arch/x86/kernel/cpu/test-cpu-load.c b/arch/x86/kernel/cpu/test-cpu-load.c
new file mode 100644
index 0000000..497a764
--- /dev/null
+++ b/arch/x86/kernel/cpu/test-cpu-load.c
@@ -0,0 +1,19 @@
+#include <linux/module.h>
+#include <linux/kernel.h>
+#include <asm/cpu_device_id.h>
+
+static struct x86_cpu_id microcode_id[] = {
+        { X86_VENDOR_INTEL, X86_FAMILY_ANY, X86_MODEL_ANY, },
+	{}
+};
+MODULE_DEVICE_TABLE(x86cpu, microcode_id);
+
+static int start(void)
+{
+	printk("test-cpu-load loaded\n");
+	return 0;
+}
+
+module_init(start);
+
+
-- 
1.7.4.4

--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ