Commit 2aa45984 authored by David S. Miller's avatar David S. Miller

Merge branch 'qed-mf-updates'

Yuval Mintz says:

====================
qed: Management firmware updates

This series contains several changes to driver interaction with the
management fw.
The biggest [& most significant] change here is a change in the locking
scheme and re-definition of the 'critical section' when accessing shared
resources toward the goal of interacting with the management firmware.
====================
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents 627caa9d 8f60bafe
......@@ -303,6 +303,9 @@ struct qed_hwfn {
bool b_int_enabled;
bool b_int_requested;
/* True if the driver requests for the link */
bool b_drv_link_init;
struct qed_mcp_info *mcp_info;
struct qed_hw_cid_data *p_tx_cids;
......
......@@ -3621,6 +3621,9 @@ struct public_port {
u32 fc_npiv_nvram_tbl_addr;
u32 fc_npiv_nvram_tbl_size;
u32 transceiver_data;
#define PMM_TRANSCEIVER_STATE_MASK 0x000000FF
#define PMM_TRANSCEIVER_STATE_SHIFT 0x00000000
#define PMM_TRANSCEIVER_STATE_PRESENT 0x00000001
};
/**************************************/
......@@ -3955,6 +3958,14 @@ enum MFW_DRV_MSG_TYPE {
MFW_DRV_MSG_DCBX_REMOTE_MIB_UPDATED,
MFW_DRV_MSG_DCBX_OPERATIONAL_MIB_UPDATED,
MFW_DRV_MSG_ERROR_RECOVERY,
MFW_DRV_MSG_BW_UPDATE,
MFW_DRV_MSG_S_TAG_UPDATE,
MFW_DRV_MSG_GET_LAN_STATS,
MFW_DRV_MSG_GET_FCOE_STATS,
MFW_DRV_MSG_GET_ISCSI_STATS,
MFW_DRV_MSG_GET_RDMA_STATS,
MFW_DRV_MSG_FAILURE_DETECTED,
MFW_DRV_MSG_TRANSCEIVER_STATE_CHANGE,
MFW_DRV_MSG_MAX
};
......
This diff is collapsed.
......@@ -11,8 +11,8 @@
#include <linux/types.h>
#include <linux/delay.h>
#include <linux/mutex.h>
#include <linux/slab.h>
#include <linux/spinlock.h>
#include "qed_hsi.h"
struct qed_mcp_link_speed_params {
......@@ -255,7 +255,8 @@ int qed_mcp_set_led(struct qed_hwfn *p_hwfn,
#define MFW_PORT(_p_hwfn) ((_p_hwfn)->abs_pf_id % \
((_p_hwfn)->cdev->num_ports_in_engines * 2))
struct qed_mcp_info {
struct mutex mutex; /* MCP access lock */
spinlock_t lock;
bool block_mb_sending;
u32 public_base;
u32 drv_mb_addr;
u32 mfw_mb_addr;
......@@ -272,6 +273,15 @@ struct qed_mcp_info {
u16 mcp_hist;
};
struct qed_mcp_mb_params {
u32 cmd;
u32 param;
union drv_union_data *p_data_src;
union drv_union_data *p_data_dst;
u32 mcp_resp;
u32 mcp_param;
};
/**
* @brief Initialize the interface with the MCP
*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment