[golan] Add Connect-IB, ConnectX-4 and ConnectX-4 Lx (Infiniband) support
[ipxe.git] / src / drivers / infiniband / mlx_utils / mlx_lib / mlx_nvconfig / mlx_nvconfig_defaults.h
1 #ifndef MLX_NVCONFIG_DEFAULTS_H_
2 #define MLX_NVCONFIG_DEFAULTS_H_
3
4 /*
5 * Copyright (C) 2015 Mellanox Technologies Ltd.
6 *
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License as
9 * published by the Free Software Foundation; either version 2 of the
10 * License, or any later version.
11 *
12 * This program is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
20 * 02110-1301, USA.
21 */
22
23 FILE_LICENCE ( GPL2_OR_LATER );
24 #include "mlx_nvconfig_prm.h"
25 /*
26 * Default values
27 */
28 #define DEFAULT_FLEXBOOT_MENU_TO 4
29 #define DEFAULT_MAX_VFS 8
30 #define DEFAULT_BOOT_PROTOCOL 1
31 #define DEFAULT_OPTION_ROM_EN 1
32 #define DEFAULT_BOOT_VLAN 1
33 #define DEFAULT_ISCSI_DHCP_PARAM_EN 1
34 #define DEFAULT_ISCSI_IPV4_DHCP_EN 1
35 #define DEFAULT_OCSD_OCBB_EN 1
36 #define DEFAULT_BOOT_IP_VER 0
37 #define DEFAULT_BOOT_LINK_UP_TO 0
38
39 struct mlx_nvconfig_port_conf_defaults {
40 mlx_uint8 pptx;
41 mlx_uint8 pprx;
42 mlx_boolean boot_option_rom_en;
43 mlx_boolean boot_vlan_en;
44 mlx_uint8 boot_retry_count;
45 mlx_uint8 boot_protocol;
46 mlx_uint8 boot_vlan;
47 mlx_uint8 boot_pkey;
48 mlx_boolean en_wol_magic;
49 mlx_uint8 network_link_type;
50 mlx_uint8 iscsi_boot_to_target;
51 mlx_boolean iscsi_vlan_en;
52 mlx_boolean iscsi_tcp_timestamps_en;
53 mlx_boolean iscsi_chap_mutual_auth_en;
54 mlx_boolean iscsi_chap_auth_en;
55 mlx_boolean iscsi_dhcp_params_en;
56 mlx_boolean iscsi_ipv4_dhcp_en;
57 mlx_uint8 iscsi_lun_busy_retry_count;
58 mlx_uint8 iscsi_link_up_delay_time;
59 mlx_uint8 client_identifier;
60 mlx_uint8 mac_admin_bit;
61 mlx_uint8 default_link_type;
62 mlx_uint8 linkup_timeout;
63 mlx_uint8 ip_ver;
64 };
65
66 struct mlx_nvconfig_conf_defaults {
67 mlx_uint8 max_vfs;
68 mlx_uint8 total_vfs;
69 mlx_uint8 sriov_en;
70 mlx_uint8 maximum_uar_bar_size;
71 mlx_uint8 uar_bar_size;
72 mlx_uint8 flexboot_menu_to;
73 mlx_boolean ocsd_ocbb_en;
74 };
75
76 mlx_status
77 nvconfig_read_port_default_values(
78 IN mlx_utils *utils,
79 IN mlx_uint8 port,
80 OUT struct mlx_nvconfig_port_conf_defaults *port_conf_def
81 );
82
83 mlx_status
84 nvconfig_read_general_default_values(
85 IN mlx_utils *utils,
86 OUT struct mlx_nvconfig_conf_defaults *conf_def
87 );
88
89 mlx_status
90 nvconfig_read_rom_ini_values(
91 IN mlx_utils *utils,
92 OUT struct mlx_nvcofnig_romini *rom_ini
93 );
94 #endif /* MLX_NVCONFIG_DEFAULTS_H_ */