drivers/edac: Lindent e752x
Run e752x_edac.c file through Lindent for cleanup Signed-off-by: Dave Jiang <djiang@mvista.com> Signed-off-by: Douglas Thompson <dougthompson@xmission.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
466b71d584
commit
203333cbba
|
@ -206,18 +206,15 @@ static const struct e752x_dev_info e752x_devs[] = {
|
|||
[E7520] = {
|
||||
.err_dev = PCI_DEVICE_ID_INTEL_7520_1_ERR,
|
||||
.ctl_dev = PCI_DEVICE_ID_INTEL_7520_0,
|
||||
.ctl_name = "E7520"
|
||||
},
|
||||
.ctl_name = "E7520"},
|
||||
[E7525] = {
|
||||
.err_dev = PCI_DEVICE_ID_INTEL_7525_1_ERR,
|
||||
.ctl_dev = PCI_DEVICE_ID_INTEL_7525_0,
|
||||
.ctl_name = "E7525"
|
||||
},
|
||||
.ctl_name = "E7525"},
|
||||
[E7320] = {
|
||||
.err_dev = PCI_DEVICE_ID_INTEL_7320_1_ERR,
|
||||
.ctl_dev = PCI_DEVICE_ID_INTEL_7320_0,
|
||||
.ctl_name = "E7320"
|
||||
},
|
||||
.ctl_name = "E7320"},
|
||||
};
|
||||
|
||||
static unsigned long ctl_page_to_phys(struct mem_ctl_info *mci,
|
||||
|
@ -264,7 +261,8 @@ static void do_process_ce(struct mem_ctl_info *mci, u16 error_one,
|
|||
e752x_printk(KERN_WARNING,
|
||||
"Test row %d Table %d %d %d %d %d %d %d %d\n", row,
|
||||
pvt->map[0], pvt->map[1], pvt->map[2], pvt->map[3],
|
||||
pvt->map[4], pvt->map[5], pvt->map[6], pvt->map[7]);
|
||||
pvt->map[4], pvt->map[5], pvt->map[6],
|
||||
pvt->map[7]);
|
||||
|
||||
/* test for channel remapping */
|
||||
for (i = 0; i < 8; i++) {
|
||||
|
@ -278,7 +276,8 @@ static void do_process_ce(struct mem_ctl_info *mci, u16 error_one,
|
|||
row = i;
|
||||
else
|
||||
e752x_mc_printk(mci, KERN_WARNING,
|
||||
"row %d not found in remap table\n", row);
|
||||
"row %d not found in remap table\n",
|
||||
row);
|
||||
} else
|
||||
row = edac_mc_find_csrow_by_page(mci, page);
|
||||
|
||||
|
@ -347,7 +346,8 @@ static void do_process_ue(struct mem_ctl_info *mci, u16 error_one,
|
|||
}
|
||||
|
||||
static inline void process_ue(struct mem_ctl_info *mci, u16 error_one,
|
||||
u32 ded_add, u32 scrb_add, int *error_found, int handle_error)
|
||||
u32 ded_add, u32 scrb_add, int *error_found,
|
||||
int handle_error)
|
||||
{
|
||||
*error_found = 1;
|
||||
|
||||
|
@ -376,8 +376,7 @@ static void do_process_ded_retry(struct mem_ctl_info *mci, u16 error,
|
|||
|
||||
error_1b = retry_add;
|
||||
page = error_1b >> (PAGE_SHIFT - 4); /* convert the addr to 4k page */
|
||||
row = pvt->mc_symmetric ?
|
||||
((page >> 1) & 3) : /* chip select are bits 14 & 13 */
|
||||
row = pvt->mc_symmetric ? ((page >> 1) & 3) : /* chip select are bits 14 & 13 */
|
||||
edac_mc_find_csrow_by_page(mci, page);
|
||||
e752x_mc_printk(mci, KERN_WARNING,
|
||||
"CE page 0x%lx, row %d : Memory read retry\n",
|
||||
|
@ -385,7 +384,8 @@ static void do_process_ded_retry(struct mem_ctl_info *mci, u16 error,
|
|||
}
|
||||
|
||||
static inline void process_ded_retry(struct mem_ctl_info *mci, u16 error,
|
||||
u32 retry_add, int *error_found, int handle_error)
|
||||
u32 retry_add, int *error_found,
|
||||
int handle_error)
|
||||
{
|
||||
*error_found = 1;
|
||||
|
||||
|
@ -534,7 +534,6 @@ static void e752x_check_hub_interface(struct e752x_error_info *info,
|
|||
if (stat8 & 0x54)
|
||||
hub_error(0, stat8 & 0x54, error_found, handle_error);
|
||||
}
|
||||
|
||||
//pci_read_config_byte(dev,E752X_HI_NERR,&stat8);
|
||||
|
||||
stat8 = info->hi_nerr;
|
||||
|
@ -609,13 +608,11 @@ static void e752x_check_dram (struct mem_ctl_info *mci,
|
|||
/* decode and report errors */
|
||||
if (error_one & 0x0101) /* check first error correctable */
|
||||
process_ce(mci, error_one, info->dram_sec1_add,
|
||||
info->dram_sec1_syndrome, error_found,
|
||||
handle_error);
|
||||
info->dram_sec1_syndrome, error_found, handle_error);
|
||||
|
||||
if (error_next & 0x0101) /* check next error correctable */
|
||||
process_ce(mci, error_next, info->dram_sec2_add,
|
||||
info->dram_sec2_syndrome, error_found,
|
||||
handle_error);
|
||||
info->dram_sec2_syndrome, error_found, handle_error);
|
||||
|
||||
if (error_one & 0x4040)
|
||||
process_ue_no_info_wr(mci, error_found, handle_error);
|
||||
|
@ -632,8 +629,7 @@ static void e752x_check_dram (struct mem_ctl_info *mci,
|
|||
error_found, handle_error);
|
||||
|
||||
if (error_one & 0x0808)
|
||||
process_threshold_ce(mci, error_one, error_found,
|
||||
handle_error);
|
||||
process_threshold_ce(mci, error_one, error_found, handle_error);
|
||||
|
||||
if (error_next & 0x0808)
|
||||
process_threshold_ce(mci, error_next, error_found,
|
||||
|
@ -664,8 +660,7 @@ static void e752x_get_error_info (struct mem_ctl_info *mci,
|
|||
pci_read_config_word(dev, E752X_SYSBUS_FERR,
|
||||
&info->sysbus_ferr);
|
||||
pci_read_config_byte(dev, E752X_BUF_FERR, &info->buf_ferr);
|
||||
pci_read_config_word(dev, E752X_DRAM_FERR,
|
||||
&info->dram_ferr);
|
||||
pci_read_config_word(dev, E752X_DRAM_FERR, &info->dram_ferr);
|
||||
pci_read_config_dword(dev, E752X_DRAM_SEC1_ADD,
|
||||
&info->dram_sec1_add);
|
||||
pci_read_config_word(dev, E752X_DRAM_SEC1_SYNDROME,
|
||||
|
@ -704,8 +699,7 @@ static void e752x_get_error_info (struct mem_ctl_info *mci,
|
|||
pci_read_config_word(dev, E752X_SYSBUS_NERR,
|
||||
&info->sysbus_nerr);
|
||||
pci_read_config_byte(dev, E752X_BUF_NERR, &info->buf_nerr);
|
||||
pci_read_config_word(dev, E752X_DRAM_NERR,
|
||||
&info->dram_nerr);
|
||||
pci_read_config_word(dev, E752X_DRAM_NERR, &info->dram_nerr);
|
||||
pci_read_config_dword(dev, E752X_DRAM_SEC2_ADD,
|
||||
&info->dram_sec2_add);
|
||||
pci_read_config_word(dev, E752X_DRAM_SEC2_SYNDROME,
|
||||
|
@ -733,7 +727,8 @@ static void e752x_get_error_info (struct mem_ctl_info *mci,
|
|||
}
|
||||
|
||||
static int e752x_process_error_info(struct mem_ctl_info *mci,
|
||||
struct e752x_error_info *info, int handle_errors)
|
||||
struct e752x_error_info *info,
|
||||
int handle_errors)
|
||||
{
|
||||
u32 error32, stat32;
|
||||
int error_found;
|
||||
|
@ -870,8 +865,7 @@ static void e752x_init_mem_map_table(struct pci_dev *pdev,
|
|||
*/
|
||||
pci_read_config_byte(pdev, E752X_DRB + index + 1,
|
||||
&value);
|
||||
pvt->map[index + 1] = (value == last) ?
|
||||
0xff : /* the dimm is single sided,
|
||||
pvt->map[index + 1] = (value == last) ? 0xff : /* the dimm is single sided,
|
||||
so flag as empty */
|
||||
row; /* this is a double sided dimm
|
||||
to save the next row # */
|
||||
|
@ -892,8 +886,7 @@ static int e752x_get_devs(struct pci_dev *pdev, int dev_idx,
|
|||
struct pci_dev *dev;
|
||||
|
||||
pvt->bridge_ck = pci_get_device(PCI_VENDOR_ID_INTEL,
|
||||
pvt->dev_info->err_dev,
|
||||
pvt->bridge_ck);
|
||||
pvt->dev_info->err_dev, pvt->bridge_ck);
|
||||
|
||||
if (pvt->bridge_ck == NULL)
|
||||
pvt->bridge_ck = pci_scan_single_device(pdev->bus,
|
||||
|
@ -1046,11 +1039,9 @@ static int e752x_probe1(struct pci_dev *pdev, int dev_idx)
|
|||
e752x_pci = edac_pci_create_generic_ctl(&pdev->dev, EDAC_MOD_STR);
|
||||
if (!e752x_pci) {
|
||||
printk(KERN_WARNING
|
||||
"%s(): Unable to create PCI control\n",
|
||||
__func__);
|
||||
"%s(): Unable to create PCI control\n", __func__);
|
||||
printk(KERN_WARNING
|
||||
"%s(): PCI error report via EDAC not setup\n",
|
||||
__func__);
|
||||
"%s(): PCI error report via EDAC not setup\n", __func__);
|
||||
}
|
||||
|
||||
/* get this far and it's successful */
|
||||
|
@ -1102,16 +1093,13 @@ static void __devexit e752x_remove_one(struct pci_dev *pdev)
|
|||
static const struct pci_device_id e752x_pci_tbl[] __devinitdata = {
|
||||
{
|
||||
PCI_VEND_DEV(INTEL, 7520_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0,
|
||||
E7520
|
||||
},
|
||||
E7520},
|
||||
{
|
||||
PCI_VEND_DEV(INTEL, 7525_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0,
|
||||
E7525
|
||||
},
|
||||
E7525},
|
||||
{
|
||||
PCI_VEND_DEV(INTEL, 7320_0), PCI_ANY_ID, PCI_ANY_ID, 0, 0,
|
||||
E7320
|
||||
},
|
||||
E7320},
|
||||
{
|
||||
0,
|
||||
} /* 0 terminated list. */
|
||||
|
|
Loading…
Reference in New Issue