From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mail2-relais-roc.national.inria.fr ([192.134.164.83]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1h20gY-0004fU-O6 for ath10k@lists.infradead.org; Thu, 07 Mar 2019 21:36:16 +0000 Date: Thu, 7 Mar 2019 22:36:13 +0100 (CET) From: Julia Lawall Subject: [PATCH] ath11k: fix noderef.cocci warnings Message-ID: MIME-Version: 1.0 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "ath10k" Errors-To: ath10k-bounces+kvalo=adurom.com@lists.infradead.org To: Kalle Valo Cc: kbuild-all@01.org, ath10k@lists.infradead.org From: kbuild test robot sizeof when applied to a pointer typed expression gives the size of the pointer Generated by: scripts/coccinelle/misc/noderef.cocci Fixes: 258bbf525e65 ("ath11k: add driver") Signed-off-by: kbuild test robot Signed-off-by: Julia Lawall --- tree: https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git ath11k-bringup head: e7daa3ec639f390e383dae0db9e6b143bcc7b5bc commit: 258bbf525e652e244aa8b2331f55fda573fbe926 [3/42] ath11k: add driver :::::: branch date: 5 hours ago :::::: commit date: 4 weeks ago dp_rx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/net/wireless/ath/ath11k/dp_rx.c +++ b/drivers/net/wireless/ath/ath11k/dp_rx.c @@ -275,7 +275,7 @@ static void ath11k_dp_rx_tid_del_func(st if (status == HAL_REO_CMD_DRAIN) goto free_desc; - elem = kzalloc(sizeof(elem), GFP_ATOMIC); + elem = kzalloc(sizeof(*elem), GFP_ATOMIC); if (!elem) { ath11k_warn(ab, "failed to allocate memory for cache flush element\n"); goto free_desc; _______________________________________________ ath10k mailing list ath10k@lists.infradead.org http://lists.infradead.org/mailman/listinfo/ath10k