summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorRoland Dreier <rolandd@cisco.com>2005-11-02 10:07:59 -0800
committerRoland Dreier <rolandd@cisco.com>2005-11-02 10:07:59 -0800
commit21a384897d48c116b879924c3dd9e96f6f1e764b (patch)
tree3179960b8e0f3ccb4feff19eb5582298d48324a0 /drivers
parentde6eb66b56d9df5ce6bd254994f05e065214e8cd (diff)
downloadlinux-3.10-21a384897d48c116b879924c3dd9e96f6f1e764b.tar.gz
linux-3.10-21a384897d48c116b879924c3dd9e96f6f1e764b.tar.bz2
linux-3.10-21a384897d48c116b879924c3dd9e96f6f1e764b.zip
[IPoIB] remove unneeded initializations to 0
Shrink our source and .text a little by removing a few assignments of NULL and 0 to memory that is already cleared as part of the allocation. Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/infiniband/ulp/ipoib/ipoib_main.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/drivers/infiniband/ulp/ipoib/ipoib_main.c b/drivers/infiniband/ulp/ipoib/ipoib_main.c
index 8b67db86830..ce0296273e7 100644
--- a/drivers/infiniband/ulp/ipoib/ipoib_main.c
+++ b/drivers/infiniband/ulp/ipoib/ipoib_main.c
@@ -356,18 +356,15 @@ static struct ipoib_path *path_rec_create(struct net_device *dev,
struct ipoib_dev_priv *priv = netdev_priv(dev);
struct ipoib_path *path;
- path = kmalloc(sizeof *path, GFP_ATOMIC);
+ path = kzalloc(sizeof *path, GFP_ATOMIC);
if (!path)
return NULL;
- path->dev = dev;
- path->pathrec.dlid = 0;
- path->ah = NULL;
+ path->dev = dev;
skb_queue_head_init(&path->queue);
INIT_LIST_HEAD(&path->neigh_list);
- path->query = NULL;
init_completion(&path->done);
memcpy(path->pathrec.dgid.raw, gid->raw, sizeof (union ib_gid));
@@ -800,10 +797,6 @@ static void ipoib_setup(struct net_device *dev)
dev->watchdog_timeo = HZ;
- dev->rebuild_header = NULL;
- dev->set_mac_address = NULL;
- dev->header_cache_update = NULL;
-
dev->flags |= IFF_BROADCAST | IFF_MULTICAST;
/*