Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp1164314ybi; Sat, 15 Jun 2019 22:18:16 -0700 (PDT) X-Google-Smtp-Source: APXvYqy9wmytIPEAUr6jpd0Y6h5Nvq+2GYYF9aJgBU9JH0TZxhL94XgCNOzBKzzhI2lA1KYZFvdn X-Received: by 2002:a62:2ccc:: with SMTP id s195mr44143051pfs.256.1560662296291; Sat, 15 Jun 2019 22:18:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560662296; cv=none; d=google.com; s=arc-20160816; b=sJPVpE7GJjBnF4vwJoHsPkAmQFkknBMBnhQQtcKsXf0fpcdzDZwk+6+helRVSLF+zn 6uI2PfUH7l5xuc2ETNrFIijoSrZ/SQ0V9E0LLU/4licvA49DmEC9xN9Z3vxWvfjBCWTT CYVr1ysddpY3xcvpLyUo8J4kbWzF+cFb+koFUugM0yBXl8gbkKILIFY9YQLbMSHQ5OeC Kstry91/7ZnabgAW4uvJhxmbtB4GL551owqco/woWIor+sTgXFdEwPzXP/Rmt6NEsYyl XfzizPIkrXrnCcZwT6uTrdot/vW0vNvF1OcSUKQPYXqfHjeKIptxKlLFUlI2smITWxqQ WhOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:content-disposition :mime-version:message-id:subject:to:from:date:dkim-signature; bh=+nuBJ9f4dkhbGZ0ut/+UiUe+NLKEceMx/7LyP3DsD7I=; b=ynm831n5wXgCqEA+gZhV2cJ6DzDX1GPA+2hajBOhZbHAGF5792SmUH5CL2YxiZpTgl 3+Ay8z0ZbIoxHXI/4HhvXINN/bSPIZEYZejH9TyMK4sjkSH/NDKKv1JcA0obIjFbx4Lw EBB7G+KN/S+zQVSBupz8LVrcr+OPdn4yLXdjiFr5hPnElqGvuW6dGVz9JtZfe8RoTLZB rS6iHN+XIjaKGuc/XeBGCtOqBZ9RbUsE7kFtoVRpnfk261x3182WwQH6WipqNRvqPjcU cse/4kMNGOj6Auy+slmVJc4D2GkrSZa2ONjU48FhPSgc2ZS++4/uLpzAylKljUk14xhB DuKw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=TuUAr0n8; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 38si3036134pgt.33.2019.06.15.22.17.17; Sat, 15 Jun 2019 22:18:16 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=TuUAr0n8; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725888AbfFPFQ0 (ORCPT + 99 others); Sun, 16 Jun 2019 01:16:26 -0400 Received: from mail-pf1-f195.google.com ([209.85.210.195]:41514 "EHLO mail-pf1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725773AbfFPFQ0 (ORCPT ); Sun, 16 Jun 2019 01:16:26 -0400 Received: by mail-pf1-f195.google.com with SMTP id m30so3825793pff.8 for ; Sat, 15 Jun 2019 22:16:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:mime-version:content-disposition :user-agent; bh=+nuBJ9f4dkhbGZ0ut/+UiUe+NLKEceMx/7LyP3DsD7I=; b=TuUAr0n8xoqntV8JDFYaOXCTj8WoMRADx5SOFlvQX8eeiUrl0v5LFBLbeT0qQSZKft BNTVgHkm/15dKOyKyky4fMDx7LLcQxJgsFJScN6zp/K9CcF3ZuPKFFjGf506ieiRcgy5 z02tq9L9vf4W1uFDdtJIqoCU6Ym8lhRP2NELJrDXAYbhfqAFiiSOeEXeZvNGFlVan4RR rOWM3KNJ+3ItmsiDPm4CMVUu4bYlMcRfJdqhVdQL0Hp/cEDhHLKtDcwMxclW/X5nBiA6 Twjpa4Uj6lwhND4smeCP85XPz56i6kuUbZelanCYNtfOYZ5CEfiCDyvWXfjazZD1QxQ+ a4Cw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:mime-version :content-disposition:user-agent; bh=+nuBJ9f4dkhbGZ0ut/+UiUe+NLKEceMx/7LyP3DsD7I=; b=JBa0MyyvEA4lWDWl2jVGtesA6wj95zbP6sX9fN3lZd1BGOSet7vljg9zgcWQQZxzbA 9JegfyO9HSvesGFMjolBjiiQtaXpZ9DmiEl0LOG9ms+jA8yqv55FbTHvEJrNDvV73D88 szkIYzANUT9SnG4zI3iiUVjQKS3lHJpbXtTDO3h9LvZCIyKBTBxChg/ZUgM2scS8z7cs OeWeA/9iNvHfJ6StTixxKkF6A1zCSEWcen0ia1SUCGisJK0PFJ94/qS4+DTVjxouYWA5 DoRYMmNMa778DO0OVRHlENGHzYK2IWpP8IbBwFC35EazDZR3M3MSlFqj+tigMts9IaCc 4Vbg== X-Gm-Message-State: APjAAAVAvTqWNk5rO5pfKshcxFBRUgJ6rpcuQOaoL9hK8jNcZfh/4VTg 2AyJVVphML9u7Rp2T8wzzulUuvp8 X-Received: by 2002:aa7:9ab5:: with SMTP id x21mr10583861pfi.139.1560662185746; Sat, 15 Jun 2019 22:16:25 -0700 (PDT) Received: from hari-Inspiron-1545 ([183.83.89.153]) by smtp.gmail.com with ESMTPSA id q7sm8638868pfb.32.2019.06.15.22.16.21 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 15 Jun 2019 22:16:24 -0700 (PDT) Date: Sun, 16 Jun 2019 10:46:19 +0530 From: Hariprasad Kelam To: Greg Kroah-Hartman , Hariprasad Kelam , Jeeeun Evans , Larry Finger , Quytelda Kahja , Omer Efrat , Arnd Bergmann , Puranjay Mohan , devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: [PATCH] staging: rtl8723bs: os_dep: Make use rtw_zmalloc Message-ID: <20190616051619.GA15036@hari-Inspiron-1545> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org rtw_malloc with memset can be replaced with rtw_zmalloc. Signed-off-by: Hariprasad Kelam --- drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c index 9bc6856..aa7cc50 100644 --- a/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c +++ b/drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c @@ -1078,12 +1078,10 @@ static int cfg80211_rtw_add_key(struct wiphy *wiphy, struct net_device *ndev, DBG_871X("pairwise =%d\n", pairwise); param_len = sizeof(struct ieee_param) + params->key_len; - param = rtw_malloc(param_len); + param = rtw_zmalloc(param_len); if (param == NULL) return -1; - memset(param, 0, param_len); - param->cmd = IEEE_CMD_SET_ENCRYPTION; memset(param->sta_addr, 0xff, ETH_ALEN); -- 2.7.4