[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <89E2752CFA8EC044846EB8499819134102BD7E1856@EXCH-MBX-4.vmware.com>
Date: Sat, 16 Oct 2010 08:57:37 -0700
From: Shreyas Bhatewara <sbhatewara@...are.com>
To: Harvey Harrison <harvey.harrison@...il.com>
CC: "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"shemminger@...tta.com" <shemminger@...tta.com>
Subject: RE: [PATCH] vmxnet3: remove set_flag_le{16,64} functions
________________________________________
From: Harvey Harrison [harvey.harrison@...il.com]
Sent: Saturday, October 16, 2010 12:33 AM
To: Shreyas Bhatewara
Cc: netdev@...r.kernel.org; shemminger@...tta.com
Subject: [PATCH] vmxnet3: remove set_flag_le{16,64} functions
Opencode the flag setting in the few places it was being done.
Signed-off-by: Harvey Harrison harvey.harrison@...il.com
---
@@ -1617,8 +1599,7 @@ vmxnet3_vlan_rx_register(struct net_device *netdev, struct vlan_group *grp)
VMXNET3_CMD_UPDATE_VLAN_FILTERS);
/* update FEATURES to device */
- reset_flag_le64(&devRead->misc.uptFeatures,
- UPT1_F_RXVLAN);
+ devRead->misc.uptFeatures |= cpu_to_le64(UPT1_F_RXVLAN);
VMXNET3_WRITE_BAR1_REG(adapter, VMXNET3_REG_CMD,
VMXNET3_CMD_UPDATE_FEATURE);
}
This hunk is wrong, UPT1_F_RXVLAN should be reset here.
I fail to understand why set/reset functions were not good enough and why this opencoding is required. I agree with your earlier suggestion about replacing two conversions with *data |= cpu_to_le16(flag); though.
Regards.
Shreyas--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists