#include <linux/acpi.h>
#include <acpi/ghes.h>
#include <linux/bitops.h>
#include <linux/delay.h>
#include <linux/pci.h>
#include <linux/platform_device.h>
#include <linux/kfifo.h>
#include <linux/spinlock.h>
#define HISI_PCIE_ERR_MISC_REGS …
#define HISI_PCIE_LOCAL_VALID_VERSION …
#define HISI_PCIE_LOCAL_VALID_SOC_ID …
#define HISI_PCIE_LOCAL_VALID_SOCKET_ID …
#define HISI_PCIE_LOCAL_VALID_NIMBUS_ID …
#define HISI_PCIE_LOCAL_VALID_SUB_MODULE_ID …
#define HISI_PCIE_LOCAL_VALID_CORE_ID …
#define HISI_PCIE_LOCAL_VALID_PORT_ID …
#define HISI_PCIE_LOCAL_VALID_ERR_TYPE …
#define HISI_PCIE_LOCAL_VALID_ERR_SEVERITY …
#define HISI_PCIE_LOCAL_VALID_ERR_MISC …
static guid_t hisi_pcie_sec_guid = …;
#define HISI_PCIE_PORT_ID(core, v) …
#define HISI_PCIE_CORE_ID(v) …
#define HISI_PCIE_CORE_PORT_ID(v) …
struct hisi_pcie_error_data { … };
struct hisi_pcie_error_private { … };
enum hisi_pcie_submodule_id { … };
static const char * const hisi_pcie_sub_module[] = …;
enum hisi_pcie_err_severity { … };
static const char * const hisi_pcie_error_sev[] = …;
static const char *hisi_pcie_get_string(const char * const *array,
size_t n, u32 id)
{ … }
static int hisi_pcie_port_reset(struct platform_device *pdev,
u32 chip_id, u32 port_id)
{ … }
static int hisi_pcie_port_do_recovery(struct platform_device *dev,
u32 chip_id, u32 port_id)
{ … }
static void hisi_pcie_handle_error(struct platform_device *pdev,
const struct hisi_pcie_error_data *edata)
{ … }
static int hisi_pcie_notify_error(struct notifier_block *nb,
unsigned long event, void *data)
{ … }
static int hisi_pcie_error_handler_probe(struct platform_device *pdev)
{ … }
static void hisi_pcie_error_handler_remove(struct platform_device *pdev)
{ … }
static const struct acpi_device_id hisi_pcie_acpi_match[] = …;
static struct platform_driver hisi_pcie_error_handler_driver = …;
module_platform_driver(…) …;
MODULE_DESCRIPTION(…) …;