xref: /linux-6.15/include/linux/dmi.h (revision e7d163f7)
1 #ifndef __DMI_H__
2 #define __DMI_H__
3 
4 enum dmi_field {
5 	DMI_NONE,
6 	DMI_BIOS_VENDOR,
7 	DMI_BIOS_VERSION,
8 	DMI_BIOS_DATE,
9 	DMI_SYS_VENDOR,
10 	DMI_PRODUCT_NAME,
11 	DMI_PRODUCT_VERSION,
12 	DMI_PRODUCT_SERIAL,
13 	DMI_BOARD_VENDOR,
14 	DMI_BOARD_NAME,
15 	DMI_BOARD_VERSION,
16 	DMI_STRING_MAX,
17 };
18 
19 /*
20  *	DMI callbacks for problem boards
21  */
22 struct dmi_strmatch {
23 	u8 slot;
24 	char *substr;
25 };
26 
27 struct dmi_system_id {
28 	int (*callback)(struct dmi_system_id *);
29 	char *ident;
30 	struct dmi_strmatch matches[4];
31 	void *driver_data;
32 };
33 
34 #define DMI_MATCH(a,b)	{ a, b }
35 
36 #if defined(CONFIG_X86) && !defined(CONFIG_X86_64)
37 
38 extern int dmi_check_system(struct dmi_system_id *list);
39 extern char * dmi_get_system_info(int field);
40 
41 #else
42 
43 static inline int dmi_check_system(struct dmi_system_id *list) { return 0; }
44 static inline char * dmi_get_system_info(int field) { return NULL; }
45 
46 #endif
47 
48 #endif	/* __DMI_H__ */
49