2 * This file is part of the coreboot project.
4 * Copyright (C) 2014 Siemens AG
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; version 2 of the License.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
16 #ifndef SIEMENS_HWI_LIB_H_
17 #define SIEMENS_HWI_LIB_H_
22 /* Declare all supported fields which can be get with hwilib. */
53 /* Define used values in supported fields */
54 #define PF_COLOR_DEPTH_6BIT 0x00
55 #define PF_COLOR_DEPTH_8BIT 0x01
56 #define PF_COLOR_DEPTH_10BIT 0x02
57 #define PF_DISPLCON_LVDS_SINGLE 0x00
58 #define PF_DISPLCON_LVDS_DUAL 0x05
59 #define FF_FREEZE_DISABLE 0x01
60 #define FF_FAN_NEEDED 0x01
62 /* Use this function to find all supported blocks in cbfs. It must be called
63 * once with a valid cbfs file name before hwilib_get_field() can be used.
65 enum cb_err
hwilib_find_blocks (const char *hwi_filename
);
67 /* Use this function to get fields out of supported info blocks
68 * This function returns the number of copied bytes or 0 on error.
70 uint32_t hwilib_get_field (hwinfo_field_t field
, uint8_t *data
, uint32_t maxlen
);
72 /* This functions needs to be implemented for every mainboard that uses i210. */
73 enum cb_err
mainboard_get_mac_address(u16 bus
, u8 devfn
, u8 mac
[6]);
74 #endif /* SIEMENS_HWI_LIB_H_ */