Lines Matching refs:mci
34 static void cell_edac_count_ce(struct mem_ctl_info *mci, int chan, u64 ar) in cell_edac_count_ce() argument
36 struct cell_edac_priv *priv = mci->pvt_info; in cell_edac_count_ce()
37 struct csrow_info *csrow = mci->csrows[0]; in cell_edac_count_ce()
40 dev_dbg(mci->pdev, "ECC CE err on node %d, channel %d, ar = 0x%016llx\n", in cell_edac_count_ce()
52 edac_mc_handle_error(HW_EVENT_ERR_CORRECTED, mci, 1, in cell_edac_count_ce()
57 static void cell_edac_count_ue(struct mem_ctl_info *mci, int chan, u64 ar) in cell_edac_count_ue() argument
59 struct cell_edac_priv *priv = mci->pvt_info; in cell_edac_count_ue()
60 struct csrow_info *csrow = mci->csrows[0]; in cell_edac_count_ue()
63 dev_dbg(mci->pdev, "ECC UE err on node %d, channel %d, ar = 0x%016llx\n", in cell_edac_count_ue()
74 edac_mc_handle_error(HW_EVENT_ERR_UNCORRECTED, mci, 1, in cell_edac_count_ue()
79 static void cell_edac_check(struct mem_ctl_info *mci) in cell_edac_check() argument
81 struct cell_edac_priv *priv = mci->pvt_info; in cell_edac_check()
87 dev_dbg(mci->pdev, "fir change : 0x%016lx\n", fir); in cell_edac_check()
94 cell_edac_count_ce(mci, 0, addreg); in cell_edac_check()
99 cell_edac_count_ce(mci, 1, addreg); in cell_edac_check()
104 cell_edac_count_ue(mci, 0, addreg); in cell_edac_check()
109 cell_edac_count_ue(mci, 1, addreg); in cell_edac_check()
123 dev_dbg(mci->pdev, "fir clear : 0x%016lx\n", fir); in cell_edac_check()
128 static void cell_edac_init_csrows(struct mem_ctl_info *mci) in cell_edac_init_csrows() argument
130 struct csrow_info *csrow = mci->csrows[0]; in cell_edac_init_csrows()
132 struct cell_edac_priv *priv = mci->pvt_info; in cell_edac_init_csrows()
158 dev_dbg(mci->pdev, in cell_edac_init_csrows()
171 struct mem_ctl_info *mci; in cell_edac_probe() local
208 mci = edac_mc_alloc(pdev->id, ARRAY_SIZE(layers), layers, in cell_edac_probe()
210 if (mci == NULL) in cell_edac_probe()
212 priv = mci->pvt_info; in cell_edac_probe()
216 mci->pdev = &pdev->dev; in cell_edac_probe()
217 mci->mtype_cap = MEM_FLAG_XDR; in cell_edac_probe()
218 mci->edac_ctl_cap = EDAC_FLAG_NONE | EDAC_FLAG_EC | EDAC_FLAG_SECDED; in cell_edac_probe()
219 mci->edac_cap = EDAC_FLAG_EC | EDAC_FLAG_SECDED; in cell_edac_probe()
220 mci->mod_name = "cell_edac"; in cell_edac_probe()
221 mci->ctl_name = "MIC"; in cell_edac_probe()
222 mci->dev_name = dev_name(&pdev->dev); in cell_edac_probe()
223 mci->edac_check = cell_edac_check; in cell_edac_probe()
224 cell_edac_init_csrows(mci); in cell_edac_probe()
227 rc = edac_mc_add_mc(mci); in cell_edac_probe()
230 edac_mc_free(mci); in cell_edac_probe()
239 struct mem_ctl_info *mci = edac_mc_del_mc(&pdev->dev); in cell_edac_remove() local
240 if (mci) in cell_edac_remove()
241 edac_mc_free(mci); in cell_edac_remove()