Commit 993ac7b5 authored by Michael Chan's avatar Michael Chan Committed by David S. Miller

bnx2x: Add main CNIC interface functions.

Add the main CNIC registration, callback, MAC addr. setup functions.
Signed-off-by: default avatarMichael Chan <mchan@broadcom.com>
Signed-off-by: default avatarShmulik Ravid - Rabinovitz <shmulikr@broadcom.com>
Acked-by: default avatarEilon Greenstein <eilong@broadcom.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 37b091ba
...@@ -24,6 +24,10 @@ ...@@ -24,6 +24,10 @@
#define BCM_VLAN 1 #define BCM_VLAN 1
#endif #endif
#if defined(CONFIG_CNIC) || defined(CONFIG_CNIC_MODULE)
#define BCM_CNIC 1
#include "cnic_if.h"
#endif
#define BNX2X_MULTI_QUEUE #define BNX2X_MULTI_QUEUE
......
This diff is collapsed.
...@@ -12,8 +12,8 @@ ...@@ -12,8 +12,8 @@
#ifndef CNIC_IF_H #ifndef CNIC_IF_H
#define CNIC_IF_H #define CNIC_IF_H
#define CNIC_MODULE_VERSION "2.0.1" #define CNIC_MODULE_VERSION "2.1.0"
#define CNIC_MODULE_RELDATE "Oct 01, 2009" #define CNIC_MODULE_RELDATE "Oct 10, 2009"
#define CNIC_ULP_RDMA 0 #define CNIC_ULP_RDMA 0
#define CNIC_ULP_ISCSI 1 #define CNIC_ULP_ISCSI 1
...@@ -81,6 +81,8 @@ struct kcqe { ...@@ -81,6 +81,8 @@ struct kcqe {
#define DRV_CTL_CTX_WR_CMD 0x103 #define DRV_CTL_CTX_WR_CMD 0x103
#define DRV_CTL_CTXTBL_WR_CMD 0x104 #define DRV_CTL_CTXTBL_WR_CMD 0x104
#define DRV_CTL_COMPLETION_CMD 0x105 #define DRV_CTL_COMPLETION_CMD 0x105
#define DRV_CTL_START_L2_CMD 0x106
#define DRV_CTL_STOP_L2_CMD 0x107
struct cnic_ctl_completion { struct cnic_ctl_completion {
u32 cid; u32 cid;
...@@ -105,11 +107,17 @@ struct drv_ctl_io { ...@@ -105,11 +107,17 @@ struct drv_ctl_io {
dma_addr_t dma_addr; dma_addr_t dma_addr;
}; };
struct drv_ctl_l2_ring {
u32 client_id;
u32 cid;
};
struct drv_ctl_info { struct drv_ctl_info {
int cmd; int cmd;
union { union {
struct drv_ctl_completion comp; struct drv_ctl_completion comp;
struct drv_ctl_io io; struct drv_ctl_io io;
struct drv_ctl_l2_ring ring;
char bytes[MAX_DRV_CTL_DATA]; char bytes[MAX_DRV_CTL_DATA];
} data; } data;
}; };
...@@ -143,6 +151,7 @@ struct cnic_eth_dev { ...@@ -143,6 +151,7 @@ struct cnic_eth_dev {
u32 max_kwqe_pending; u32 max_kwqe_pending;
struct pci_dev *pdev; struct pci_dev *pdev;
void __iomem *io_base; void __iomem *io_base;
void __iomem *io_base2;
u32 ctx_tbl_offset; u32 ctx_tbl_offset;
u32 ctx_tbl_len; u32 ctx_tbl_len;
...@@ -298,5 +307,6 @@ extern int cnic_register_driver(int ulp_type, struct cnic_ulp_ops *ulp_ops); ...@@ -298,5 +307,6 @@ extern int cnic_register_driver(int ulp_type, struct cnic_ulp_ops *ulp_ops);
extern int cnic_unregister_driver(int ulp_type); extern int cnic_unregister_driver(int ulp_type);
extern struct cnic_eth_dev *bnx2_cnic_probe(struct net_device *dev); extern struct cnic_eth_dev *bnx2_cnic_probe(struct net_device *dev);
extern struct cnic_eth_dev *bnx2x_cnic_probe(struct net_device *dev);
#endif #endif
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