net/qede/base: add support for 2x10G mode
[dpdk.git] / drivers / net / qede / base / ecore.h
index 89e2bd0..034e885 100644 (file)
@@ -15,7 +15,7 @@
 #include <unistd.h>
 
 #define CONFIG_ECORE_BINARY_FW
-#define CONFIG_ECORE_ZIPPED_FW
+#undef CONFIG_ECORE_ZIPPED_FW
 
 #ifdef CONFIG_ECORE_ZIPPED_FW
 #include <zlib.h>
@@ -80,7 +80,7 @@ enum ecore_nvm_cmd {
 #define SET_FIELD(value, name, flag)                                   \
 do {                                                                   \
        (value) &= ~(name##_MASK << name##_SHIFT);                      \
-       (value) |= (((u64)flag) << (name##_SHIFT));                     \
+       (value) |= ((((u64)flag) & (u64)name##_MASK) << (name##_SHIFT));\
 } while (0)
 
 #define GET_FIELD(value, name)                                         \
@@ -302,6 +302,7 @@ enum ecore_port_mode {
        ECORE_PORT_MODE_DE_2X25G,
        ECORE_PORT_MODE_DE_1X25G,
        ECORE_PORT_MODE_DE_4X25G,
+       ECORE_PORT_MODE_DE_2X10G,
 };
 
 enum ecore_dev_cap {
@@ -711,8 +712,6 @@ struct ecore_dev {
        /* SRIOV */
        struct ecore_hw_sriov_info      *p_iov_info;
 #define IS_ECORE_SRIOV(p_dev)          (!!(p_dev)->p_iov_info)
-       bool                            b_hw_channel;
-
        unsigned long                   tunn_mode;
 
        bool                            b_is_vf;
@@ -800,7 +799,7 @@ static OSAL_INLINE u8 ecore_concrete_to_sw_fid(struct ecore_dev *p_dev,
 }
 
 #define PURE_LB_TC 8
-#define OOO_LB_TC 9
+#define PKT_LB_TC 9
 
 int ecore_configure_vport_wfq(struct ecore_dev *p_dev, u16 vp_id, u32 rate);
 void ecore_configure_vp_wfq_on_link_change(struct ecore_dev *p_dev,
@@ -811,6 +810,8 @@ int ecore_configure_pf_min_bandwidth(struct ecore_dev *p_dev, u8 min_bw);
 void ecore_clean_wfq_db(struct ecore_hwfn *p_hwfn, struct ecore_ptt *p_ptt);
 int ecore_device_num_engines(struct ecore_dev *p_dev);
 int ecore_device_num_ports(struct ecore_dev *p_dev);
+void ecore_set_fw_mac_addr(__le16 *fw_msb, __le16 *fw_mid, __le16 *fw_lsb,
+                          u8 *mac);
 
 #define ECORE_LEADING_HWFN(dev)        (&dev->hwfns[0])