]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commitdiff
gianfar: remove use of VLAN_TAG_PRESENT
authorMichał Mirosław <mirq-linux@rere.qmqm.pl>
Thu, 8 Nov 2018 17:44:50 +0000 (18:44 +0100)
committerDavid S. Miller <davem@davemloft.net>
Fri, 9 Nov 2018 03:49:32 +0000 (19:49 -0800)
Reviewed-by: Claudiu Manoil <claudiu.manoil@nxp.com>
Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/freescale/gianfar_ethtool.c

index 0d76e15cd6dd65f51696711d4486505215ddce3f..241325c35cb40445580ea13cf6844d9d06528c39 100644 (file)
@@ -1134,11 +1134,9 @@ static int gfar_convert_to_filer(struct ethtool_rx_flow_spec *rule,
                prio = vlan_tci_prio(rule);
                prio_mask = vlan_tci_priom(rule);
 
-               if (cfi == VLAN_TAG_PRESENT && cfi_mask == VLAN_TAG_PRESENT) {
-                       vlan |= RQFPR_CFI;
-                       vlan_mask |= RQFPR_CFI;
-               } else if (cfi != VLAN_TAG_PRESENT &&
-                          cfi_mask == VLAN_TAG_PRESENT) {
+               if (cfi_mask) {
+                       if (cfi)
+                               vlan |= RQFPR_CFI;
                        vlan_mask |= RQFPR_CFI;
                }
        }