rtl8366_smi: fix port->flags calculation in rtl8366_get_ports
authorGabor Juhos <juhosg@openwrt.org>
Wed, 20 Jan 2010 07:06:10 +0000 (07:06 +0000)
committerGabor Juhos <juhosg@openwrt.org>
Wed, 20 Jan 2010 07:06:10 +0000 (07:06 +0000)
SVN-Revision: 19237

target/linux/ar71xx/files/drivers/net/phy/rtl8366_smi.c

index b9158d6e3e6f7f1badac03221974f56a69e5e6e8..a79de4e6bc1d14bd587d9b7ecc7c872510e56ed4 100644 (file)
@@ -1498,7 +1498,8 @@ static int rtl8366_get_ports(struct switch_dev *dev,
                        continue;
 
                port->id = i;
-               port->flags = vlanmc.untag ? 0 : BIT(SWITCH_PORT_FLAG_TAGGED);
+               port->flags = (vlanmc.untag & BIT(i)) ?
+                                       0 : BIT(SWITCH_PORT_FLAG_TAGGED);
                val->len++;
                port++;
        }