|
@@ -711,15 +711,8 @@ static inline void aer_process_err_devices(struct pcie_device *p_device,
|
|
static void aer_isr_one_error(struct pcie_device *p_device,
|
|
static void aer_isr_one_error(struct pcie_device *p_device,
|
|
struct aer_err_source *e_src)
|
|
struct aer_err_source *e_src)
|
|
{
|
|
{
|
|
- struct aer_err_info *e_info;
|
|
|
|
-
|
|
|
|
- /* struct aer_err_info might be big, so we allocate it with slab */
|
|
|
|
- e_info = kmalloc(sizeof(struct aer_err_info), GFP_KERNEL);
|
|
|
|
- if (!e_info) {
|
|
|
|
- dev_printk(KERN_DEBUG, &p_device->port->dev,
|
|
|
|
- "Can't allocate mem when processing AER errors\n");
|
|
|
|
- return;
|
|
|
|
- }
|
|
|
|
|
|
+ struct aer_rpc *rpc = get_service_data(p_device);
|
|
|
|
+ struct aer_err_info *e_info = &rpc->e_info;
|
|
|
|
|
|
/*
|
|
/*
|
|
* There is a possibility that both correctable error and
|
|
* There is a possibility that both correctable error and
|
|
@@ -758,8 +751,6 @@ static void aer_isr_one_error(struct pcie_device *p_device,
|
|
if (find_source_device(p_device->port, e_info))
|
|
if (find_source_device(p_device->port, e_info))
|
|
aer_process_err_devices(p_device, e_info);
|
|
aer_process_err_devices(p_device, e_info);
|
|
}
|
|
}
|
|
-
|
|
|
|
- kfree(e_info);
|
|
|
|
}
|
|
}
|
|
|
|
|
|
/**
|
|
/**
|