aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/pci/pcie/aer.c33
1 files changed, 16 insertions, 17 deletions
diff --git a/drivers/pci/pcie/aer.c b/drivers/pci/pcie/aer.c
index a41738ff33e1..85c713f6cfdb 100644
--- a/drivers/pci/pcie/aer.c
+++ b/drivers/pci/pcie/aer.c
@@ -44,7 +44,6 @@ struct aer_rpc {
44 struct pci_dev *rpd; /* Root Port device */ 44 struct pci_dev *rpd; /* Root Port device */
45 struct work_struct dpc_handler; 45 struct work_struct dpc_handler;
46 struct aer_err_source e_sources[AER_ERROR_SOURCES_MAX]; 46 struct aer_err_source e_sources[AER_ERROR_SOURCES_MAX];
47 struct aer_err_info e_info;
48 unsigned short prod_idx; /* Error Producer Index */ 47 unsigned short prod_idx; /* Error Producer Index */
49 unsigned short cons_idx; /* Error Consumer Index */ 48 unsigned short cons_idx; /* Error Consumer Index */
50 int isr; 49 int isr;
@@ -1176,7 +1175,7 @@ static void aer_isr_one_error(struct aer_rpc *rpc,
1176 struct aer_err_source *e_src) 1175 struct aer_err_source *e_src)
1177{ 1176{
1178 struct pci_dev *pdev = rpc->rpd; 1177 struct pci_dev *pdev = rpc->rpd;
1179 struct aer_err_info *e_info = &rpc->e_info; 1178 struct aer_err_info e_info;
1180 1179
1181 pci_rootport_aer_stats_incr(pdev, e_src); 1180 pci_rootport_aer_stats_incr(pdev, e_src);
1182 1181
@@ -1185,36 +1184,36 @@ static void aer_isr_one_error(struct aer_rpc *rpc,
1185 * uncorrectable error being logged. Report correctable error first. 1184 * uncorrectable error being logged. Report correctable error first.
1186 */ 1185 */
1187 if (e_src->status & PCI_ERR_ROOT_COR_RCV) { 1186 if (e_src->status & PCI_ERR_ROOT_COR_RCV) {
1188 e_info->id = ERR_COR_ID(e_src->id); 1187 e_info.id = ERR_COR_ID(e_src->id);
1189 e_info->severity = AER_CORRECTABLE; 1188 e_info.severity = AER_CORRECTABLE;
1190 1189
1191 if (e_src->status & PCI_ERR_ROOT_MULTI_COR_RCV) 1190 if (e_src->status & PCI_ERR_ROOT_MULTI_COR_RCV)
1192 e_info->multi_error_valid = 1; 1191 e_info.multi_error_valid = 1;
1193 else 1192 else
1194 e_info->multi_error_valid = 0; 1193 e_info.multi_error_valid = 0;
1195 aer_print_port_info(pdev, e_info); 1194 aer_print_port_info(pdev, &e_info);
1196 1195
1197 if (find_source_device(pdev, e_info)) 1196 if (find_source_device(pdev, &e_info))
1198 aer_process_err_devices(e_info); 1197 aer_process_err_devices(&e_info);
1199 } 1198 }
1200 1199
1201 if (e_src->status & PCI_ERR_ROOT_UNCOR_RCV) { 1200 if (e_src->status & PCI_ERR_ROOT_UNCOR_RCV) {
1202 e_info->id = ERR_UNCOR_ID(e_src->id); 1201 e_info.id = ERR_UNCOR_ID(e_src->id);
1203 1202
1204 if (e_src->status & PCI_ERR_ROOT_FATAL_RCV) 1203 if (e_src->status & PCI_ERR_ROOT_FATAL_RCV)
1205 e_info->severity = AER_FATAL; 1204 e_info.severity = AER_FATAL;
1206 else 1205 else
1207 e_info->severity = AER_NONFATAL; 1206 e_info.severity = AER_NONFATAL;
1208 1207
1209 if (e_src->status & PCI_ERR_ROOT_MULTI_UNCOR_RCV) 1208 if (e_src->status & PCI_ERR_ROOT_MULTI_UNCOR_RCV)
1210 e_info->multi_error_valid = 1; 1209 e_info.multi_error_valid = 1;
1211 else 1210 else
1212 e_info->multi_error_valid = 0; 1211 e_info.multi_error_valid = 0;
1213 1212
1214 aer_print_port_info(pdev, e_info); 1213 aer_print_port_info(pdev, &e_info);
1215 1214
1216 if (find_source_device(pdev, e_info)) 1215 if (find_source_device(pdev, &e_info))
1217 aer_process_err_devices(e_info); 1216 aer_process_err_devices(&e_info);
1218 } 1217 }
1219} 1218}
1220 1219