amso1100: Add missing memset
PATCH 1/1 amso1100: Add missing memset
--- drivers/infiniband/hw/amso1100/c2_rnic.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)
drivers/infiniband/hw/amso1100/c2_rnic.c +2 -0
@@ -155,6 +155,8 @@ static int c2_rnic_query(struct c2_dev *c2dev, struct ib_device_attr *props)if (err) goto bail2; +memset (props,0 ,sizeof *props); + props->fw_ver = ((u64 )be32_to_cpu (reply->fw_ver_major) <<32 ) | ((be32_to_cpu(reply->fw_ver_minor) & 0xFFFF) << 16) |
Signature · 6 lines
1.7.0.3 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
I think this patch is actually not needed. c2_rnic_query() is only called for the c2dev->props memory, and c2dev is allocated with ib_alloc_device, which will always zero it out.
Signature · 6 lines
Roland Dreier <[email protected]> || For corporate legal information go to: http://www.cisco.com/web/about/doing_business/legal/cri/index.html -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html