]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commitdiff
staging: rtl8192e: rtllib_module: Remove redundant memset
authorHariprasad Kelam <hariprasad.kelam@gmail.com>
Tue, 18 Jun 2019 18:04:31 +0000 (23:34 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 20 Jun 2019 12:39:15 +0000 (14:39 +0200)
alloc_etherdev function internally calls kvzalloc . So we may not need
explicit memset after this call.

Signed-off-by: Hariprasad Kelam <hariprasad.kelam@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8192e/rtllib_module.c

index bb13b1de27974f787ab43c415dcfa20846c7c1d0..64d9feee1f392d33fb575336289570e565caa300 100644 (file)
@@ -83,7 +83,6 @@ struct net_device *alloc_rtllib(int sizeof_priv)
                return NULL;
        }
        ieee = (struct rtllib_device *)netdev_priv_rsl(dev);
-       memset(ieee, 0, sizeof(struct rtllib_device) + sizeof_priv);
        ieee->dev = dev;
 
        err = rtllib_networks_allocate(ieee);