linux/drivers/firmware/efi/cper.c

// SPDX-License-Identifier: GPL-2.0
/*
 * UEFI Common Platform Error Record (CPER) support
 *
 * Copyright (C) 2010, Intel Corp.
 *	Author: Huang Ying <[email protected]>
 *
 * CPER is the format used to describe platform hardware error by
 * various tables, such as ERST, BERT and HEST etc.
 *
 * For more information about CPER, please refer to Appendix N of UEFI
 * Specification version 2.4.
 */

#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/time.h>
#include <linux/cper.h>
#include <linux/dmi.h>
#include <linux/acpi.h>
#include <linux/pci.h>
#include <linux/aer.h>
#include <linux/printk.h>
#include <linux/bcd.h>
#include <acpi/ghes.h>
#include <ras/ras_event.h>
#include "cper_cxl.h"

/*
 * CPER record ID need to be unique even after reboot, because record
 * ID is used as index for ERST storage, while CPER records from
 * multiple boot may co-exist in ERST.
 */
u64 cper_next_record_id(void)
{}
EXPORT_SYMBOL_GPL();

static const char * const severity_strs[] =;

const char *cper_severity_str(unsigned int severity)
{}
EXPORT_SYMBOL_GPL();

/*
 * cper_print_bits - print strings for set bits
 * @pfx: prefix for each line, including log level and prefix string
 * @bits: bit mask
 * @strs: string array, indexed by bit position
 * @strs_size: size of the string array: @strs
 *
 * For each set bit in @bits, print the corresponding string in @strs.
 * If the output length is longer than 80, multiple line will be
 * printed, with @pfx is printed at the beginning of each line.
 */
void cper_print_bits(const char *pfx, unsigned int bits,
		     const char * const strs[], unsigned int strs_size)
{}

static const char * const proc_type_strs[] =;

static const char * const proc_isa_strs[] =;

const char * const cper_proc_error_type_strs[] =;

static const char * const proc_op_strs[] =;

static const char * const proc_flag_strs[] =;

static void cper_print_proc_generic(const char *pfx,
				    const struct cper_sec_proc_generic *proc)
{}

static const char * const mem_err_type_strs[] =;

const char *cper_mem_err_type_str(unsigned int etype)
{}
EXPORT_SYMBOL_GPL();

const char *cper_mem_err_status_str(u64 status)
{}
EXPORT_SYMBOL_GPL();

int cper_mem_err_location(struct cper_mem_err_compact *mem, char *msg)
{}
EXPORT_SYMBOL_GPL();

int cper_dimm_err_location(struct cper_mem_err_compact *mem, char *msg)
{}
EXPORT_SYMBOL_GPL();

void cper_mem_err_pack(const struct cper_sec_mem_err *mem,
		       struct cper_mem_err_compact *cmem)
{}
EXPORT_SYMBOL_GPL();

const char *cper_mem_err_unpack(struct trace_seq *p,
				struct cper_mem_err_compact *cmem)
{}

static void cper_print_mem(const char *pfx, const struct cper_sec_mem_err *mem,
	int len)
{}

static const char * const pcie_port_type_strs[] =;

static void cper_print_pcie(const char *pfx, const struct cper_sec_pcie *pcie,
			    const struct acpi_hest_generic_data *gdata)
{}

static const char * const fw_err_rec_type_strs[] =;

static void cper_print_fw_err(const char *pfx,
			      struct acpi_hest_generic_data *gdata,
			      const struct cper_sec_fw_err_rec_ref *fw_err)
{}

static void cper_print_tstamp(const char *pfx,
				   struct acpi_hest_generic_data_v300 *gdata)
{}

struct ignore_section {};

static const struct ignore_section ignore_sections[] =;

static void
cper_estatus_print_section(const char *pfx, struct acpi_hest_generic_data *gdata,
			   int sec_no)
{}

void cper_estatus_print(const char *pfx,
			const struct acpi_hest_generic_status *estatus)
{}
EXPORT_SYMBOL_GPL();

int cper_estatus_check_header(const struct acpi_hest_generic_status *estatus)
{}
EXPORT_SYMBOL_GPL();

int cper_estatus_check(const struct acpi_hest_generic_status *estatus)
{}
EXPORT_SYMBOL_GPL();