Lines Matching refs:hest_hdr
52 static inline bool is_generic_error(struct acpi_hest_header *hest_hdr) in is_generic_error() argument
54 return hest_hdr->type == ACPI_HEST_TYPE_GENERIC_ERROR || in is_generic_error()
55 hest_hdr->type == ACPI_HEST_TYPE_GENERIC_ERROR_V2; in is_generic_error()
58 static int hest_esrc_len(struct acpi_hest_header *hest_hdr) in hest_esrc_len() argument
60 u16 hest_type = hest_hdr->type; in hest_esrc_len()
70 cmc = (struct acpi_hest_ia_corrected *)hest_hdr; in hest_esrc_len()
75 mc = (struct acpi_hest_ia_machine_check *)hest_hdr; in hest_esrc_len()
80 mc = (struct acpi_hest_ia_deferred_check *)hest_hdr; in hest_esrc_len()
91 struct acpi_hest_header *hest_hdr; in apei_hest_parse() local
97 hest_hdr = (struct acpi_hest_header *)(hest_tab + 1); in apei_hest_parse()
99 len = hest_esrc_len(hest_hdr); in apei_hest_parse()
104 hest_hdr->type, hest_hdr->source_id); in apei_hest_parse()
107 if ((void *)hest_hdr + len > in apei_hest_parse()
111 hest_hdr->source_id); in apei_hest_parse()
115 rc = func(hest_hdr, data); in apei_hest_parse()
119 hest_hdr = (void *)hest_hdr + len; in apei_hest_parse()
130 static int __init hest_parse_cmc(struct acpi_hest_header *hest_hdr, void *data) in hest_parse_cmc() argument
132 if (hest_hdr->type != ACPI_HEST_TYPE_IA32_CORRECTED_CHECK) in hest_parse_cmc()
136 return !arch_apei_enable_cmcff(hest_hdr, data); in hest_parse_cmc()
146 static int __init hest_parse_ghes_count(struct acpi_hest_header *hest_hdr, void *data) in hest_parse_ghes_count() argument
150 if (is_generic_error(hest_hdr)) in hest_parse_ghes_count()
155 static int __init hest_parse_ghes(struct acpi_hest_header *hest_hdr, void *data) in hest_parse_ghes() argument
161 if (!is_generic_error(hest_hdr)) in hest_parse_ghes()
164 if (!((struct acpi_hest_generic *)hest_hdr)->enabled) in hest_parse_ghes()
170 if (hdr->source_id == hest_hdr->source_id) { in hest_parse_ghes()
176 ghes_dev = platform_device_alloc("GHES", hest_hdr->source_id); in hest_parse_ghes()
180 rc = platform_device_add_data(ghes_dev, &hest_hdr, sizeof(void *)); in hest_parse_ghes()