qlogic: qed: fix a test for MODE_MF_SI
authorDan Carpenter <dan.carpenter@oracle.com>
Wed, 4 Nov 2015 13:29:11 +0000 (16:29 +0300)
committerDavid S. Miller <davem@davemloft.net>
Thu, 5 Nov 2015 03:06:13 +0000 (22:06 -0500)
MODE_MF_SI is 9.  We should be testing bit 9 instead of AND 0x9.

Fixes: fe56b9e6a8d9 ('qed: Add module with basic common support')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Yuval Mintz <Yuval.Mintz@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qed/qed_dev.c

index b9b7b7e6fa534cc70cd96a97aaf7afb12f734b3f..774b2231b79acc265a694bfedfc7cd57959130f0 100644 (file)
@@ -562,7 +562,7 @@ static int qed_hw_init_pf(struct qed_hwfn *p_hwfn,
        }
 
        /* Enable classification by MAC if needed */
-       if (hw_mode & MODE_MF_SI) {
+       if (hw_mode & (1 << MODE_MF_SI)) {
                DP_VERBOSE(p_hwfn, NETIF_MSG_HW,
                           "Configuring TAGMAC_CLS_TYPE\n");
                STORE_RT_REG(p_hwfn,