Fix below checkpatch issue found in mgmt_tx() Prefer kmalloc(sizeof(*mgmt_tx)...) over kmalloc(sizeof(struct p2p_mgmt_data)...) Signed-off-by: Ajay Singh <ajay.kathat@xxxxxxxxxxxxx> --- drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c index 102facd..d0fb31a 100644 --- a/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c +++ b/drivers/staging/wilc1000/wilc_wfi_cfgoperations.c @@ -1628,7 +1628,7 @@ static int mgmt_tx(struct wiphy *wiphy, if (!ieee80211_is_mgmt(mgmt->frame_control)) goto out; - mgmt_tx = kmalloc(sizeof(struct p2p_mgmt_data), GFP_KERNEL); + mgmt_tx = kmalloc(sizeof(*mgmt_tx), GFP_KERNEL); if (!mgmt_tx) { ret = -ENOMEM; goto out; -- 2.7.4 _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel