lkml.org 
[lkml]   [2015]   [Jul]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH] net: qlcnic: Deletion of unnecessary memset
    Date
    There is no need to memset memory allocated with vzalloc.

    Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
    ---
    drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c | 1 -
    1 file changed, 1 deletion(-)

    diff --git a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c
    index 2f6cc42..7dbab3c 100644
    --- a/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c
    +++ b/drivers/net/ethernet/qlogic/qlcnic/qlcnic_main.c
    @@ -2403,7 +2403,6 @@ int qlcnic_alloc_tx_rings(struct qlcnic_adapter *adapter,
    qlcnic_free_tx_rings(adapter);
    return -ENOMEM;
    }
    - memset(cmd_buf_arr, 0, TX_BUFF_RINGSIZE(tx_ring));
    tx_ring->cmd_buf_arr = cmd_buf_arr;
    spin_lock_init(&tx_ring->tx_clean_lock);
    }
    --
    2.1.4


    \
     
     \ /
      Last update: 2015-07-13 22:01    [W:5.306 / U:0.008 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site