diff options
Diffstat (limited to 'drivers/s390/net/netiucv.c')
-rw-r--r-- | drivers/s390/net/netiucv.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/s390/net/netiucv.c b/drivers/s390/net/netiucv.c index 71d3853e8682..260a93c8c442 100644 --- a/drivers/s390/net/netiucv.c +++ b/drivers/s390/net/netiucv.c | |||
@@ -1728,14 +1728,13 @@ static int | |||
1728 | netiucv_register_device(struct net_device *ndev) | 1728 | netiucv_register_device(struct net_device *ndev) |
1729 | { | 1729 | { |
1730 | struct netiucv_priv *priv = ndev->priv; | 1730 | struct netiucv_priv *priv = ndev->priv; |
1731 | struct device *dev = kmalloc(sizeof(struct device), GFP_KERNEL); | 1731 | struct device *dev = kzalloc(sizeof(struct device), GFP_KERNEL); |
1732 | int ret; | 1732 | int ret; |
1733 | 1733 | ||
1734 | 1734 | ||
1735 | IUCV_DBF_TEXT(trace, 3, __FUNCTION__); | 1735 | IUCV_DBF_TEXT(trace, 3, __FUNCTION__); |
1736 | 1736 | ||
1737 | if (dev) { | 1737 | if (dev) { |
1738 | memset(dev, 0, sizeof(struct device)); | ||
1739 | snprintf(dev->bus_id, BUS_ID_SIZE, "net%s", ndev->name); | 1738 | snprintf(dev->bus_id, BUS_ID_SIZE, "net%s", ndev->name); |
1740 | dev->bus = &iucv_bus; | 1739 | dev->bus = &iucv_bus; |
1741 | dev->parent = iucv_root; | 1740 | dev->parent = iucv_root; |
@@ -1784,11 +1783,9 @@ netiucv_new_connection(struct net_device *dev, char *username) | |||
1784 | { | 1783 | { |
1785 | struct iucv_connection **clist = &iucv_connections; | 1784 | struct iucv_connection **clist = &iucv_connections; |
1786 | struct iucv_connection *conn = | 1785 | struct iucv_connection *conn = |
1787 | (struct iucv_connection *) | 1786 | kzalloc(sizeof(struct iucv_connection), GFP_KERNEL); |
1788 | kmalloc(sizeof(struct iucv_connection), GFP_KERNEL); | ||
1789 | 1787 | ||
1790 | if (conn) { | 1788 | if (conn) { |
1791 | memset(conn, 0, sizeof(struct iucv_connection)); | ||
1792 | skb_queue_head_init(&conn->collect_queue); | 1789 | skb_queue_head_init(&conn->collect_queue); |
1793 | skb_queue_head_init(&conn->commit_queue); | 1790 | skb_queue_head_init(&conn->commit_queue); |
1794 | conn->max_buffsize = NETIUCV_BUFSIZE_DEFAULT; | 1791 | conn->max_buffsize = NETIUCV_BUFSIZE_DEFAULT; |