]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
bnx2x: Support Queue Per Cos in 5771xx devices
authorAriel Elior <ariele@broadcom.com>
Thu, 26 Jan 2012 06:01:45 +0000 (06:01 +0000)
committerJoe Jin <joe.jin@oracle.com>
Wed, 16 May 2012 14:41:19 +0000 (22:41 +0800)
Enable the use of up to three hardware queues for transmission. The queues
are always dequed round robin (i.e. strict priority, PFC and ETS are not
supported). This does allow the allocation of a seperate HW queue for low
volume, high priority traffic which will be serviced more promptly.

(cherry picked from commit 8d7b02783bc2b05974f6e47c2be8157f3a9cd89e)
Signed-off-by: Ariel Elior <ariele@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Joe Jin <joe.jin@oracle.com>
drivers/net/bnx2x/bnx2x_cmn.h
drivers/net/bnx2x/bnx2x_sp.h

index 0d761e6d98dc0d8d67465690d1e9220cb29015d2..6cdb70cf5a054bbdb3c409e7c13aec1a6e515f6b 100644 (file)
@@ -983,10 +983,11 @@ static inline int bnx2x_func_start(struct bnx2x *bp)
        /* Function parameters */
        start_params->mf_mode = bp->mf_mode;
        start_params->sd_vlan_tag = bp->mf_ov;
-       if (CHIP_IS_E1x(bp))
-               start_params->network_cos_mode = OVERRIDE_COS;
-       else
+
+       if (CHIP_IS_E2(bp) || CHIP_IS_E3(bp))
                start_params->network_cos_mode = STATIC_COS;
+       else /* CHIP_IS_E1X */
+               start_params->network_cos_mode = FW_WRR;
 
        return bnx2x_func_state_change(bp, &func_params);
 }
index 66da39f0c84a4f4b476eaaea82af8afcc21b0fe9..f33bc5722e584e9ca11b19cef0623bb954a557d5 100644 (file)
@@ -803,10 +803,10 @@ enum bnx2x_q_type {
 };
 
 #define BNX2X_PRIMARY_CID_INDEX                        0
-#define BNX2X_MULTI_TX_COS_E1X                 1
+#define BNX2X_MULTI_TX_COS_E1X                 3 /* QM only */
 #define BNX2X_MULTI_TX_COS_E2_E3A0             2
 #define BNX2X_MULTI_TX_COS_E3B0                        3
-#define BNX2X_MULTI_TX_COS                     BNX2X_MULTI_TX_COS_E3B0
+#define BNX2X_MULTI_TX_COS                     3 /* Maximum possible */
 
 
 struct bnx2x_queue_init_params {