summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/broadcom/brcm80211/brcmsmac/mac80211_if.c
diff options
context:
space:
mode:
authorErick Archer <erick.archer@outlook.com>2024-05-27 19:34:25 +0200
committerKalle Valo <kvalo@kernel.org>2024-06-01 13:08:57 +0300
commitdcb77f854ae086bf32596fae02c88665393a13e8 (patch)
treefb7c1c02c9ac215a78a5257c6a84d4563d0f7029 /drivers/net/wireless/broadcom/brcm80211/brcmsmac/mac80211_if.c
parent8526f8c877baf3f9e678b31fd7d1066b776775cc (diff)
wifi: brcm80211: use sizeof(*pointer) instead of sizeof(type)
It is preferred to use sizeof(*pointer) instead of sizeof(type) due to the type of the variable can change and one needs not change the former (unlike the latter). This patch has no effect on runtime behavior. At the same time remove some redundant NULL initializations. Acked-by: Arend van Spriel <arend.vanspriel@broadcom.com> Signed-off-by: Erick Archer <erick.archer@outlook.com> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://msgid.link/AS8PR02MB7237FF1C2E880D1231684D708BF02@AS8PR02MB7237.eurprd02.prod.outlook.com
Diffstat (limited to 'drivers/net/wireless/broadcom/brcm80211/brcmsmac/mac80211_if.c')
-rw-r--r--drivers/net/wireless/broadcom/brcm80211/brcmsmac/mac80211_if.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmsmac/mac80211_if.c b/drivers/net/wireless/broadcom/brcm80211/brcmsmac/mac80211_if.c
index 92860dc0a92e..860ef9c11c46 100644
--- a/drivers/net/wireless/broadcom/brcm80211/brcmsmac/mac80211_if.c
+++ b/drivers/net/wireless/broadcom/brcm80211/brcmsmac/mac80211_if.c
@@ -1496,7 +1496,7 @@ struct brcms_timer *brcms_init_timer(struct brcms_info *wl,
{
struct brcms_timer *t;
- t = kzalloc(sizeof(struct brcms_timer), GFP_ATOMIC);
+ t = kzalloc(sizeof(*t), GFP_ATOMIC);
if (!t)
return NULL;