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]
Date:	Wed, 01 Jun 2016 17:12:14 -0700
From:	Dave Hansen <dave@...1.net>
To:	linux-kernel@...r.kernel.org
Cc:	x86@...nel.org, Dave Hansen <dave@...1.net>,
	dave.hansen@...ux.intel.com, mchehab@....samsung.com,
	dougthompson@...ssion.com, bp@...en8.de, tony.luck@...el.com,
	linux-edac@...r.kernel.org
Subject: [PATCH 12/20] x86, edac: use Intel family name macros for edac driver


From: Dave Hansen <dave.hansen@...ux.intel.com>

Another straightforward replacement of magic numbers.

Signed-off-by: Dave Hansen <dave.hansen@...ux.intel.com>
Cc: Mauro Carvalho Chehab <mchehab@....samsung.com>
Cc: Doug Thompson <dougthompson@...ssion.com>
Cc: Borislav Petkov <bp@...en8.de>
Cc: Tony Luck <tony.luck@...el.com>
Cc: linux-edac@...r.kernel.org
---

 b/drivers/edac/sb_edac.c |   11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff -puN drivers/edac/sb_edac.c~x86-intel-familites-edac drivers/edac/sb_edac.c
--- a/drivers/edac/sb_edac.c~x86-intel-familites-edac	2016-06-01 15:45:07.657102586 -0700
+++ b/drivers/edac/sb_edac.c	2016-06-01 15:45:07.661102769 -0700
@@ -23,6 +23,7 @@
 #include <linux/math64.h>
 #include <linux/mod_devicetable.h>
 #include <asm/cpu_device_id.h>
+#include <asm/intel-family.h>
 #include <asm/processor.h>
 #include <asm/mce.h>
 
@@ -3359,11 +3360,11 @@ fail0:
 
 /* Order here must match "enum type" */
 static const struct x86_cpu_id sbridge_cpuids[] = {
-	ICPU(0x2d, pci_dev_descr_sbridge_table),	/* SANDY_BRIDGE */
-	ICPU(0x3e, pci_dev_descr_ibridge_table),	/* IVY_BRIDGE */
-	ICPU(0x3f, pci_dev_descr_haswell_table),	/* HASWELL */
-	ICPU(0x4f, pci_dev_descr_broadwell_table),	/* BROADWELL */
-	ICPU(0x57, pci_dev_descr_knl_table),		/* KNIGHTS_LANDING */
+	ICPU(INTEL_FAM6_MODEL_SANDYBRIDGE_X,	pci_dev_descr_sbridge_table),
+	ICPU(INTEL_FAM6_MODEL_IVYBRIDGE_X,	pci_dev_descr_ibridge_table),
+	ICPU(INTEL_FAM6_MODEL_HASWELL_X,	pci_dev_descr_haswell_table),
+	ICPU(INTEL_FAM6_MODEL_BROADWELL_X,	pci_dev_descr_broadwell_table),
+	ICPU(INTEL_FAM6_MODEL_XEON_PHI_KNL,	pci_dev_descr_knl_table),
 	{ }
 };
 MODULE_DEVICE_TABLE(x86cpu, sbridge_cpuids);
_

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ