blob: 89507190628dbbbccd246adefeac628fb0361186 [file] [log] [blame]
Yuval Mintzfe56b9e2015-10-26 11:02:25 +02001/* QLogic qed NIC Driver
2 * Copyright (c) 2015 QLogic Corporation
3 *
4 * This software is available under the terms of the GNU General Public License
5 * (GPL) Version 2, available from the file COPYING in the main directory of
6 * this source tree.
7 */
8
9#ifndef _QED_MCP_H
10#define _QED_MCP_H
11
12#include <linux/types.h>
13#include <linux/delay.h>
Yuval Mintzfe56b9e2015-10-26 11:02:25 +020014#include <linux/slab.h>
Tomer Tayar5529bad2016-03-09 09:16:24 +020015#include <linux/spinlock.h>
Yuval Mintzfe56b9e2015-10-26 11:02:25 +020016#include "qed_hsi.h"
17
Yuval Mintzcc875c22015-10-26 11:02:31 +020018struct qed_mcp_link_speed_params {
19 bool autoneg;
20 u32 advertised_speeds; /* bitmask of DRV_SPEED_CAPABILITY */
21 u32 forced_speed; /* In Mb/s */
22};
23
24struct qed_mcp_link_pause_params {
25 bool autoneg;
26 bool forced_rx;
27 bool forced_tx;
28};
29
30struct qed_mcp_link_params {
31 struct qed_mcp_link_speed_params speed;
32 struct qed_mcp_link_pause_params pause;
33 u32 loopback_mode;
34};
35
36struct qed_mcp_link_capabilities {
37 u32 speed_capabilities;
38};
39
40struct qed_mcp_link_state {
41 bool link_up;
42
Manish Chopraa64b02d2016-04-26 10:56:10 -040043 u32 min_pf_rate;
44
Manish Chopra4b01e512016-04-26 10:56:09 -040045 /* Actual link speed in Mb/s */
46 u32 line_speed;
47
48 /* PF max speed in Mb/s, deduced from line_speed
49 * according to PF max bandwidth configuration.
50 */
51 u32 speed;
Yuval Mintzcc875c22015-10-26 11:02:31 +020052 bool full_duplex;
53
54 bool an;
55 bool an_complete;
56 bool parallel_detection;
57 bool pfc_enabled;
58
59#define QED_LINK_PARTNER_SPEED_1G_HD BIT(0)
60#define QED_LINK_PARTNER_SPEED_1G_FD BIT(1)
61#define QED_LINK_PARTNER_SPEED_10G BIT(2)
62#define QED_LINK_PARTNER_SPEED_20G BIT(3)
Sudarsana Reddy Kalluru054c67d2016-08-09 03:51:23 -040063#define QED_LINK_PARTNER_SPEED_25G BIT(4)
64#define QED_LINK_PARTNER_SPEED_40G BIT(5)
65#define QED_LINK_PARTNER_SPEED_50G BIT(6)
66#define QED_LINK_PARTNER_SPEED_100G BIT(7)
Yuval Mintzcc875c22015-10-26 11:02:31 +020067 u32 partner_adv_speed;
68
69 bool partner_tx_flow_ctrl_en;
70 bool partner_rx_flow_ctrl_en;
71
72#define QED_LINK_PARTNER_SYMMETRIC_PAUSE (1)
73#define QED_LINK_PARTNER_ASYMMETRIC_PAUSE (2)
74#define QED_LINK_PARTNER_BOTH_PAUSE (3)
75 u8 partner_adv_pause;
76
77 bool sfp_tx_fault;
78};
79
Yuval Mintzfe56b9e2015-10-26 11:02:25 +020080struct qed_mcp_function_info {
81 u8 pause_on_host;
82
83 enum qed_pci_personality protocol;
84
85 u8 bandwidth_min;
86 u8 bandwidth_max;
87
88 u8 mac[ETH_ALEN];
89
90 u64 wwn_port;
91 u64 wwn_node;
92
93#define QED_MCP_VLAN_UNSET (0xffff)
94 u16 ovlan;
Sudarsana Kalluru0fefbfb2016-10-31 07:14:21 +020095
96 u16 mtu;
Yuval Mintzfe56b9e2015-10-26 11:02:25 +020097};
98
99struct qed_mcp_nvm_common {
100 u32 offset;
101 u32 param;
102 u32 resp;
103 u32 cmd;
104};
105
106struct qed_mcp_drv_version {
107 u32 version;
108 u8 name[MCP_DRV_VER_STR_SIZE - 4];
109};
110
Sudarsana Reddy Kalluru6c754242016-08-16 10:51:03 -0400111struct qed_mcp_lan_stats {
112 u64 ucast_rx_pkts;
113 u64 ucast_tx_pkts;
114 u32 fcs_err;
115};
116
117struct qed_mcp_fcoe_stats {
118 u64 rx_pkts;
119 u64 tx_pkts;
120 u32 fcs_err;
121 u32 login_failure;
122};
123
124struct qed_mcp_iscsi_stats {
125 u64 rx_pdus;
126 u64 tx_pdus;
127 u64 rx_bytes;
128 u64 tx_bytes;
129};
130
131struct qed_mcp_rdma_stats {
132 u64 rx_pkts;
133 u64 tx_pkts;
134 u64 rx_bytes;
135 u64 tx_byts;
136};
137
138enum qed_mcp_protocol_type {
139 QED_MCP_LAN_STATS,
140 QED_MCP_FCOE_STATS,
141 QED_MCP_ISCSI_STATS,
142 QED_MCP_RDMA_STATS
143};
144
145union qed_mcp_protocol_stats {
146 struct qed_mcp_lan_stats lan_stats;
147 struct qed_mcp_fcoe_stats fcoe_stats;
148 struct qed_mcp_iscsi_stats iscsi_stats;
149 struct qed_mcp_rdma_stats rdma_stats;
150};
151
Sudarsana Kalluru0fefbfb2016-10-31 07:14:21 +0200152enum qed_ov_eswitch {
153 QED_OV_ESWITCH_NONE,
154 QED_OV_ESWITCH_VEB,
155 QED_OV_ESWITCH_VEPA
156};
157
158enum qed_ov_client {
159 QED_OV_CLIENT_DRV,
160 QED_OV_CLIENT_USER,
161 QED_OV_CLIENT_VENDOR_SPEC
162};
163
164enum qed_ov_driver_state {
165 QED_OV_DRIVER_STATE_NOT_LOADED,
166 QED_OV_DRIVER_STATE_DISABLED,
167 QED_OV_DRIVER_STATE_ACTIVE
168};
169
170enum qed_ov_wol {
171 QED_OV_WOL_DEFAULT,
172 QED_OV_WOL_DISABLED,
173 QED_OV_WOL_ENABLED
174};
175
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200176/**
Yuval Mintzcc875c22015-10-26 11:02:31 +0200177 * @brief - returns the link params of the hw function
178 *
179 * @param p_hwfn
180 *
181 * @returns pointer to link params
182 */
183struct qed_mcp_link_params *qed_mcp_get_link_params(struct qed_hwfn *);
184
185/**
186 * @brief - return the link state of the hw function
187 *
188 * @param p_hwfn
189 *
190 * @returns pointer to link state
191 */
192struct qed_mcp_link_state *qed_mcp_get_link_state(struct qed_hwfn *);
193
194/**
195 * @brief - return the link capabilities of the hw function
196 *
197 * @param p_hwfn
198 *
199 * @returns pointer to link capabilities
200 */
201struct qed_mcp_link_capabilities
202 *qed_mcp_get_link_capabilities(struct qed_hwfn *p_hwfn);
203
204/**
205 * @brief Request the MFW to set the the link according to 'link_input'.
206 *
207 * @param p_hwfn
208 * @param p_ptt
209 * @param b_up - raise link if `true'. Reset link if `false'.
210 *
211 * @return int
212 */
213int qed_mcp_set_link(struct qed_hwfn *p_hwfn,
214 struct qed_ptt *p_ptt,
215 bool b_up);
216
217/**
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200218 * @brief Get the management firmware version value
219 *
Yuval Mintz1408cc1f2016-05-11 16:36:14 +0300220 * @param p_hwfn
221 * @param p_ptt
222 * @param p_mfw_ver - mfw version value
223 * @param p_running_bundle_id - image id in nvram; Optional.
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200224 *
Yuval Mintz1408cc1f2016-05-11 16:36:14 +0300225 * @return int - 0 - operation was successful.
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200226 */
Yuval Mintz1408cc1f2016-05-11 16:36:14 +0300227int qed_mcp_get_mfw_ver(struct qed_hwfn *p_hwfn,
228 struct qed_ptt *p_ptt,
229 u32 *p_mfw_ver, u32 *p_running_bundle_id);
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200230
231/**
Yuval Mintzcc875c22015-10-26 11:02:31 +0200232 * @brief Get media type value of the port.
233 *
234 * @param cdev - qed dev pointer
235 * @param mfw_ver - media type value
236 *
237 * @return int -
238 * 0 - Operation was successul.
239 * -EBUSY - Operation failed
240 */
241int qed_mcp_get_media_type(struct qed_dev *cdev,
242 u32 *media_type);
243
244/**
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200245 * @brief General function for sending commands to the MCP
246 * mailbox. It acquire mutex lock for the entire
247 * operation, from sending the request until the MCP
248 * response. Waiting for MCP response will be checked up
249 * to 5 seconds every 5ms.
250 *
251 * @param p_hwfn - hw function
252 * @param p_ptt - PTT required for register access
253 * @param cmd - command to be sent to the MCP.
254 * @param param - Optional param
255 * @param o_mcp_resp - The MCP response code (exclude sequence).
256 * @param o_mcp_param- Optional parameter provided by the MCP
257 * response
258 * @return int - 0 - operation
259 * was successul.
260 */
261int qed_mcp_cmd(struct qed_hwfn *p_hwfn,
262 struct qed_ptt *p_ptt,
263 u32 cmd,
264 u32 param,
265 u32 *o_mcp_resp,
266 u32 *o_mcp_param);
267
268/**
269 * @brief - drains the nig, allowing completion to pass in case of pauses.
270 * (Should be called only from sleepable context)
271 *
272 * @param p_hwfn
273 * @param p_ptt
274 */
275int qed_mcp_drain(struct qed_hwfn *p_hwfn,
276 struct qed_ptt *p_ptt);
277
278/**
Manish Chopracee4d262015-10-26 11:02:28 +0200279 * @brief Get the flash size value
280 *
281 * @param p_hwfn
282 * @param p_ptt
283 * @param p_flash_size - flash size in bytes to be filled.
284 *
285 * @return int - 0 - operation was successul.
286 */
287int qed_mcp_get_flash_size(struct qed_hwfn *p_hwfn,
288 struct qed_ptt *p_ptt,
289 u32 *p_flash_size);
290
291/**
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200292 * @brief Send driver version to MFW
293 *
294 * @param p_hwfn
295 * @param p_ptt
296 * @param version - Version value
297 * @param name - Protocol driver name
298 *
299 * @return int - 0 - operation was successul.
300 */
301int
302qed_mcp_send_drv_version(struct qed_hwfn *p_hwfn,
303 struct qed_ptt *p_ptt,
304 struct qed_mcp_drv_version *p_ver);
305
Sudarsana Kalluru91420b82015-11-30 12:25:03 +0200306/**
Sudarsana Kalluru0fefbfb2016-10-31 07:14:21 +0200307 * @brief Notify MFW about the change in base device properties
308 *
309 * @param p_hwfn
310 * @param p_ptt
311 * @param client - qed client type
312 *
313 * @return int - 0 - operation was successful.
314 */
315int qed_mcp_ov_update_current_config(struct qed_hwfn *p_hwfn,
316 struct qed_ptt *p_ptt,
317 enum qed_ov_client client);
318
319/**
320 * @brief Notify MFW about the driver state
321 *
322 * @param p_hwfn
323 * @param p_ptt
324 * @param drv_state - Driver state
325 *
326 * @return int - 0 - operation was successful.
327 */
328int qed_mcp_ov_update_driver_state(struct qed_hwfn *p_hwfn,
329 struct qed_ptt *p_ptt,
330 enum qed_ov_driver_state drv_state);
331
332/**
333 * @brief Send MTU size to MFW
334 *
335 * @param p_hwfn
336 * @param p_ptt
337 * @param mtu - MTU size
338 *
339 * @return int - 0 - operation was successful.
340 */
341int qed_mcp_ov_update_mtu(struct qed_hwfn *p_hwfn,
342 struct qed_ptt *p_ptt, u16 mtu);
343
344/**
345 * @brief Send MAC address to MFW
346 *
347 * @param p_hwfn
348 * @param p_ptt
349 * @param mac - MAC address
350 *
351 * @return int - 0 - operation was successful.
352 */
353int qed_mcp_ov_update_mac(struct qed_hwfn *p_hwfn,
354 struct qed_ptt *p_ptt, u8 *mac);
355
356/**
357 * @brief Send WOL mode to MFW
358 *
359 * @param p_hwfn
360 * @param p_ptt
361 * @param wol - WOL mode
362 *
363 * @return int - 0 - operation was successful.
364 */
365int qed_mcp_ov_update_wol(struct qed_hwfn *p_hwfn,
366 struct qed_ptt *p_ptt,
367 enum qed_ov_wol wol);
368
369/**
Sudarsana Kalluru91420b82015-11-30 12:25:03 +0200370 * @brief Set LED status
371 *
372 * @param p_hwfn
373 * @param p_ptt
374 * @param mode - LED mode
375 *
376 * @return int - 0 - operation was successful.
377 */
378int qed_mcp_set_led(struct qed_hwfn *p_hwfn,
379 struct qed_ptt *p_ptt,
380 enum qed_led_mode mode);
381
Sudarsana Reddy Kalluru03dc76c2016-04-28 20:20:52 -0400382/**
383 * @brief Bist register test
384 *
385 * @param p_hwfn - hw function
386 * @param p_ptt - PTT required for register access
387 *
388 * @return int - 0 - operation was successful.
389 */
390int qed_mcp_bist_register_test(struct qed_hwfn *p_hwfn,
391 struct qed_ptt *p_ptt);
392
393/**
394 * @brief Bist clock test
395 *
396 * @param p_hwfn - hw function
397 * @param p_ptt - PTT required for register access
398 *
399 * @return int - 0 - operation was successful.
400 */
401int qed_mcp_bist_clock_test(struct qed_hwfn *p_hwfn,
402 struct qed_ptt *p_ptt);
403
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200404/* Using hwfn number (and not pf_num) is required since in CMT mode,
405 * same pf_num may be used by two different hwfn
406 * TODO - this shouldn't really be in .h file, but until all fields
407 * required during hw-init will be placed in their correct place in shmem
408 * we need it in qed_dev.c [for readin the nvram reflection in shmem].
409 */
410#define MCP_PF_ID_BY_REL(p_hwfn, rel_pfid) (QED_IS_BB((p_hwfn)->cdev) ? \
411 ((rel_pfid) | \
412 ((p_hwfn)->abs_pf_id & 1) << 3) : \
413 rel_pfid)
414#define MCP_PF_ID(p_hwfn) MCP_PF_ID_BY_REL(p_hwfn, (p_hwfn)->rel_pf_id)
415
416/* TODO - this is only correct as long as only BB is supported, and
417 * no port-swapping is implemented; Afterwards we'll need to fix it.
418 */
419#define MFW_PORT(_p_hwfn) ((_p_hwfn)->abs_pf_id % \
420 ((_p_hwfn)->cdev->num_ports_in_engines * 2))
421struct qed_mcp_info {
Tomer Tayar5529bad2016-03-09 09:16:24 +0200422 spinlock_t lock;
423 bool block_mb_sending;
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200424 u32 public_base;
425 u32 drv_mb_addr;
426 u32 mfw_mb_addr;
427 u32 port_addr;
428 u16 drv_mb_seq;
429 u16 drv_pulse_seq;
Yuval Mintzcc875c22015-10-26 11:02:31 +0200430 struct qed_mcp_link_params link_input;
431 struct qed_mcp_link_state link_output;
432 struct qed_mcp_link_capabilities link_capabilities;
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200433 struct qed_mcp_function_info func_info;
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200434 u8 *mfw_mb_cur;
435 u8 *mfw_mb_shadow;
436 u16 mfw_mb_length;
437 u16 mcp_hist;
438};
439
Tomer Tayar5529bad2016-03-09 09:16:24 +0200440struct qed_mcp_mb_params {
441 u32 cmd;
442 u32 param;
443 union drv_union_data *p_data_src;
444 union drv_union_data *p_data_dst;
445 u32 mcp_resp;
446 u32 mcp_param;
447};
448
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200449/**
450 * @brief Initialize the interface with the MCP
451 *
452 * @param p_hwfn - HW func
453 * @param p_ptt - PTT required for register access
454 *
455 * @return int
456 */
457int qed_mcp_cmd_init(struct qed_hwfn *p_hwfn,
458 struct qed_ptt *p_ptt);
459
460/**
461 * @brief Initialize the port interface with the MCP
462 *
463 * @param p_hwfn
464 * @param p_ptt
465 * Can only be called after `num_ports_in_engines' is set
466 */
467void qed_mcp_cmd_port_init(struct qed_hwfn *p_hwfn,
468 struct qed_ptt *p_ptt);
469/**
470 * @brief Releases resources allocated during the init process.
471 *
472 * @param p_hwfn - HW func
473 * @param p_ptt - PTT required for register access
474 *
475 * @return int
476 */
477
478int qed_mcp_free(struct qed_hwfn *p_hwfn);
479
480/**
Yuval Mintzcc875c22015-10-26 11:02:31 +0200481 * @brief This function is called from the DPC context. After
482 * pointing PTT to the mfw mb, check for events sent by the MCP
483 * to the driver and ack them. In case a critical event
484 * detected, it will be handled here, otherwise the work will be
485 * queued to a sleepable work-queue.
486 *
487 * @param p_hwfn - HW function
488 * @param p_ptt - PTT required for register access
489 * @return int - 0 - operation
490 * was successul.
491 */
492int qed_mcp_handle_events(struct qed_hwfn *p_hwfn,
493 struct qed_ptt *p_ptt);
494
495/**
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200496 * @brief Sends a LOAD_REQ to the MFW, and in case operation
497 * succeed, returns whether this PF is the first on the
498 * chip/engine/port or function. This function should be
499 * called when driver is ready to accept MFW events after
500 * Storms initializations are done.
501 *
502 * @param p_hwfn - hw function
503 * @param p_ptt - PTT required for register access
504 * @param p_load_code - The MCP response param containing one
505 * of the following:
506 * FW_MSG_CODE_DRV_LOAD_ENGINE
507 * FW_MSG_CODE_DRV_LOAD_PORT
508 * FW_MSG_CODE_DRV_LOAD_FUNCTION
509 * @return int -
510 * 0 - Operation was successul.
511 * -EBUSY - Operation failed
512 */
513int qed_mcp_load_req(struct qed_hwfn *p_hwfn,
514 struct qed_ptt *p_ptt,
515 u32 *p_load_code);
516
517/**
518 * @brief Read the MFW mailbox into Current buffer.
519 *
520 * @param p_hwfn
521 * @param p_ptt
522 */
523void qed_mcp_read_mb(struct qed_hwfn *p_hwfn,
524 struct qed_ptt *p_ptt);
525
526/**
Yuval Mintz0b55e272016-05-11 16:36:15 +0300527 * @brief Ack to mfw that driver finished FLR process for VFs
528 *
529 * @param p_hwfn
530 * @param p_ptt
531 * @param vfs_to_ack - bit mask of all engine VFs for which the PF acks.
532 *
533 * @param return int - 0 upon success.
534 */
535int qed_mcp_ack_vf_flr(struct qed_hwfn *p_hwfn,
536 struct qed_ptt *p_ptt, u32 *vfs_to_ack);
537
538/**
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200539 * @brief - calls during init to read shmem of all function-related info.
540 *
541 * @param p_hwfn
542 *
543 * @param return 0 upon success.
544 */
545int qed_mcp_fill_shmem_func_info(struct qed_hwfn *p_hwfn,
546 struct qed_ptt *p_ptt);
547
548/**
549 * @brief - Reset the MCP using mailbox command.
550 *
551 * @param p_hwfn
552 * @param p_ptt
553 *
554 * @param return 0 upon success.
555 */
556int qed_mcp_reset(struct qed_hwfn *p_hwfn,
557 struct qed_ptt *p_ptt);
558
559/**
Tomer Tayar41024262016-09-05 14:35:10 +0300560 * @brief - Sends an NVM read command request to the MFW to get
561 * a buffer.
562 *
563 * @param p_hwfn
564 * @param p_ptt
565 * @param cmd - Command: DRV_MSG_CODE_NVM_GET_FILE_DATA or
566 * DRV_MSG_CODE_NVM_READ_NVRAM commands
567 * @param param - [0:23] - Offset [24:31] - Size
568 * @param o_mcp_resp - MCP response
569 * @param o_mcp_param - MCP response param
570 * @param o_txn_size - Buffer size output
571 * @param o_buf - Pointer to the buffer returned by the MFW.
572 *
573 * @param return 0 upon success.
574 */
575int qed_mcp_nvm_rd_cmd(struct qed_hwfn *p_hwfn,
576 struct qed_ptt *p_ptt,
577 u32 cmd,
578 u32 param,
579 u32 *o_mcp_resp,
580 u32 *o_mcp_param, u32 *o_txn_size, u32 *o_buf);
581
582/**
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200583 * @brief indicates whether the MFW objects [under mcp_info] are accessible
584 *
585 * @param p_hwfn
586 *
587 * @return true iff MFW is running and mcp_info is initialized
588 */
589bool qed_mcp_is_init(struct qed_hwfn *p_hwfn);
Yuval Mintz1408cc1f2016-05-11 16:36:14 +0300590
591/**
592 * @brief request MFW to configure MSI-X for a VF
593 *
594 * @param p_hwfn
595 * @param p_ptt
596 * @param vf_id - absolute inside engine
597 * @param num_sbs - number of entries to request
598 *
599 * @return int
600 */
601int qed_mcp_config_vf_msix(struct qed_hwfn *p_hwfn,
602 struct qed_ptt *p_ptt, u8 vf_id, u8 num);
603
Tomer Tayar41024262016-09-05 14:35:10 +0300604/**
605 * @brief - Halt the MCP.
606 *
607 * @param p_hwfn
608 * @param p_ptt
609 *
610 * @param return 0 upon success.
611 */
612int qed_mcp_halt(struct qed_hwfn *p_hwfn, struct qed_ptt *p_ptt);
613
614/**
615 * @brief - Wake up the MCP.
616 *
617 * @param p_hwfn
618 * @param p_ptt
619 *
620 * @param return 0 upon success.
621 */
622int qed_mcp_resume(struct qed_hwfn *p_hwfn, struct qed_ptt *p_ptt);
623
Manish Chopraa64b02d2016-04-26 10:56:10 -0400624int qed_configure_pf_min_bandwidth(struct qed_dev *cdev, u8 min_bw);
Manish Chopra4b01e512016-04-26 10:56:09 -0400625int qed_configure_pf_max_bandwidth(struct qed_dev *cdev, u8 max_bw);
626int __qed_configure_pf_max_bandwidth(struct qed_hwfn *p_hwfn,
627 struct qed_ptt *p_ptt,
628 struct qed_mcp_link_state *p_link,
629 u8 max_bw);
Manish Chopraa64b02d2016-04-26 10:56:10 -0400630int __qed_configure_pf_min_bandwidth(struct qed_hwfn *p_hwfn,
631 struct qed_ptt *p_ptt,
632 struct qed_mcp_link_state *p_link,
633 u8 min_bw);
Yuval Mintz351a4ded2016-06-02 10:23:29 +0300634
Tomer Tayar41024262016-09-05 14:35:10 +0300635int qed_mcp_mask_parities(struct qed_hwfn *p_hwfn,
636 struct qed_ptt *p_ptt, u32 mask_parities);
637
Sudarsana Kalluru0fefbfb2016-10-31 07:14:21 +0200638/**
639 * @brief Send eswitch mode to MFW
640 *
641 * @param p_hwfn
642 * @param p_ptt
643 * @param eswitch - eswitch mode
644 *
645 * @return int - 0 - operation was successful.
646 */
647int qed_mcp_ov_update_eswitch(struct qed_hwfn *p_hwfn,
648 struct qed_ptt *p_ptt,
649 enum qed_ov_eswitch eswitch);
650
Yuval Mintzfe56b9e2015-10-26 11:02:25 +0200651#endif