Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 477ea116 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'edac_fixes_for_3.20' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp

Pull two EDAC fixes from Borislav Petkov:

 - A fix to sb_edac for proper detection on SNB machines

 - A fix to amd64_edac to not explode on Numascale machines with more
   than 16 memory controllers, from Daniel J Blueman.

* tag 'edac_fixes_for_3.20' of git://git.kernel.org/pub/scm/linux/kernel/git/bp/bp:
  EDAC, amd64_edac: Prevent OOPS with >16 memory controllers
  sb_edac: Fix detection on SNB machines
parents 6ed3e57f 0c510cc8
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -2174,14 +2174,20 @@ static void __log_bus_error(struct mem_ctl_info *mci, struct err_info *err,

static inline void decode_bus_error(int node_id, struct mce *m)
{
	struct mem_ctl_info *mci = mcis[node_id];
	struct amd64_pvt *pvt = mci->pvt_info;
	struct mem_ctl_info *mci;
	struct amd64_pvt *pvt;
	u8 ecc_type = (m->status >> 45) & 0x3;
	u8 xec = XEC(m->status, 0x1f);
	u16 ec = EC(m->status);
	u64 sys_addr;
	struct err_info err;

	mci = edac_mc_find(node_id);
	if (!mci)
		return;

	pvt = mci->pvt_info;

	/* Bail out early if this was an 'observed' error */
	if (PP(ec) == NBSL_PP_OBS)
		return;
+6 −3
Original line number Diff line number Diff line
@@ -2447,7 +2447,7 @@ static int sbridge_probe(struct pci_dev *pdev, const struct pci_device_id *id)
		rc = sbridge_get_all_devices(&num_mc, pci_dev_descr_ibridge_table);
		type = IVY_BRIDGE;
		break;
	case PCI_DEVICE_ID_INTEL_SBRIDGE_IMC_TA:
	case PCI_DEVICE_ID_INTEL_SBRIDGE_IMC_HA0:
		rc = sbridge_get_all_devices(&num_mc, pci_dev_descr_sbridge_table);
		type = SANDY_BRIDGE;
		break;
@@ -2460,8 +2460,11 @@ static int sbridge_probe(struct pci_dev *pdev, const struct pci_device_id *id)
		type = BROADWELL;
		break;
	}
	if (unlikely(rc < 0))
	if (unlikely(rc < 0)) {
		edac_dbg(0, "couldn't get all devices for 0x%x\n", pdev->device);
		goto fail0;
	}

	mc = 0;

	list_for_each_entry(sbridge_dev, &sbridge_edac_list, list) {
@@ -2474,7 +2477,7 @@ static int sbridge_probe(struct pci_dev *pdev, const struct pci_device_id *id)
			goto fail1;
	}

	sbridge_printk(KERN_INFO, "Driver loaded.\n");
	sbridge_printk(KERN_INFO, "%s\n", SBRIDGE_REVISION);

	mutex_unlock(&sbridge_edac_lock);
	return 0;