lazybios 3.0.0
Lightweight SMBIOS/DMI parsing library
Loading...
Searching...
No Matches
type7.h
Go to the documentation of this file.
1/*
2 * SPDX-License-Identifier: LGPL-2.1-or-later
3 *
4 * This file is part of lazybios.
5 *
6 * lazybios is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU Lesser General Public License as published by
8 * the Free Software Foundation, either version 2.1 of the License, or
9 * (at your option) any later version.
10 *
11 * lazybios is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU Lesser General Public License for more details.
15 *
16 * You should have received a copy of the GNU Lesser General Public License
17 * along with lazybios. If not, see <https://www.gnu.org/licenses/>.
18 */
19/**
20 * @file type7.h
21 * @brief Public API for SMBIOS Type 7 Cache Information.
22 * @author LazySeldi
23 */
24
25#ifndef LAZYBIOS_TYPE7_H
26#define LAZYBIOS_TYPE7_H
27
28#ifndef LAZYBIOS_SHARED_API_H
29#define LAZYBIOS_TYPE_HEADER_ONLY
30#include "lazybios/lazybios.h"
31#undef LAZYBIOS_TYPE_HEADER_ONLY
32#endif
33
34#ifdef __cplusplus
35extern "C" {
36#endif
37
38/** @brief Availability metadata for SMBIOS Type 7 fields. */
53
54/**
55 * @brief Decoded forms of the Type 7 encoded fields.
56 *
57 * Each member holds the decoded form of the raw field it is named for.
58 * Consult the matching `field_status` member before using one.
59 */
71
72/**
73 * @brief Parsed SMBIOS Type 7 Cache Information.
74 * @ingroup api_type7
75 */
94
95/**
96 * @brief A parsed set of SMBIOS Type 7 structures.
97 * @ingroup api_type7
98 */
103
104/** @addtogroup api_type7
105 * @{
106 */
107
108/**
109 * @brief Parses all SMBIOS Type 7 structures.
110 * @param DMIData Raw DMI table container to parse.
111 * @return Newly allocated set, empty when the table holds no Type 7 structure,
112 * or NULL when the arguments are unusable or an allocation fails.
113 */
115
116/**
117 * @brief Releases a parsed set of SMBIOS Type 7 structures.
118 * @param Type7 Set to release; may be NULL.
119 */
121
122/** @} */
123
124#ifdef __cplusplus
125}
126#endif
127
128#endif
LAZYBIOS_WARN_UNUSED lazybiosType7Array_t * lazybiosGetType7(const lazybiosDMI_t *DMIData)
Parses all SMBIOS Type 7 structures.
void lazybiosFreeType7(lazybiosType7Array_t *Type7)
Releases a parsed set of SMBIOS Type 7 structures.
Public API for lazybios. Include this and nothing else.
uint8_t lazybiosFieldStatus_t
Storage for one field's availability.
Definition lazybios.h:115
#define LAZYBIOS_WARN_UNUSED
Expands to nothing on compilers without a return-value check.
Definition lazybios.h:150
Owns raw DMI table data and its parsed SMBIOS entry point.
Definition lazybios.h:218
A parsed set of SMBIOS Type 7 structures.
Definition type7.h:99
lazybiosType7_t * entries
Definition type7.h:100
Decoded forms of the Type 7 encoded fields.
Definition type7.h:60
uint64_t maximum_cache_size
Definition type7.h:65
const char * system_cache_type
Definition type7.h:67
char * supported_sram_type
Definition type7.h:69
const char * associativity
Definition type7.h:61
char * cache_configuration
Definition type7.h:68
uint64_t installed_cache_size_2
Definition type7.h:63
const char * error_correction_type
Definition type7.h:62
uint64_t maximum_cache_size_2
Definition type7.h:66
uint64_t installed_size
Definition type7.h:64
Availability metadata for SMBIOS Type 7 fields.
Definition type7.h:39
lazybiosFieldStatus_t system_cache_type
Definition type7.h:48
lazybiosFieldStatus_t installed_size
Definition type7.h:43
lazybiosFieldStatus_t error_correction_type
Definition type7.h:47
lazybiosFieldStatus_t current_sram_type
Definition type7.h:45
lazybiosFieldStatus_t installed_cache_size_2
Definition type7.h:51
lazybiosFieldStatus_t socket_designation
Definition type7.h:40
lazybiosFieldStatus_t maximum_cache_size
Definition type7.h:42
lazybiosFieldStatus_t cache_configuration
Definition type7.h:41
lazybiosFieldStatus_t associativity
Definition type7.h:49
lazybiosFieldStatus_t maximum_cache_size_2
Definition type7.h:50
lazybiosFieldStatus_t supported_sram_type
Definition type7.h:44
lazybiosFieldStatus_t cache_speed
Definition type7.h:46
Parsed SMBIOS Type 7 Cache Information.
Definition type7.h:76
uint32_t maximum_cache_size_2
Definition type7.h:89
uint8_t associativity
Definition type7.h:88
uint16_t installed_size
Definition type7.h:82
const char * socket_designation
Definition type7.h:79
uint8_t length
Definition type7.h:78
uint8_t system_cache_type
Definition type7.h:87
uint16_t maximum_cache_size
Definition type7.h:81
uint16_t current_sram_type
Definition type7.h:84
uint8_t cache_speed
Definition type7.h:85
lazybiosType7FieldStatus_t field_status
Definition type7.h:92
uint16_t supported_sram_type
Definition type7.h:83
uint32_t installed_cache_size_2
Definition type7.h:90
lazybiosType7Decoded_t decoded
Definition type7.h:91
uint8_t error_correction_type
Definition type7.h:86
uint16_t handle
Definition type7.h:77
uint16_t cache_configuration
Definition type7.h:80