Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7adf4f31 authored by Chaehyun Lim's avatar Chaehyun Lim Committed by Greg Kroah-Hartman
Browse files

staging: wilc1000: fix coding style of kmalloc usage



This patch fixes coding style of kmalloc usage found by checkpatch.
CHECK: Prefer kmalloc(sizeof(*new_msg)...) over kmalloc(sizeof(struct message)...)

Signed-off-by: default avatarChaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 5b8e7ba9
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -70,7 +70,7 @@ int wilc_mq_send(struct message_queue *mq,
	}
	}


	/* construct a new message */
	/* construct a new message */
	new_msg = kmalloc(sizeof(struct message), GFP_ATOMIC);
	new_msg = kmalloc(sizeof(*new_msg), GFP_ATOMIC);
	if (!new_msg)
	if (!new_msg)
		return -ENOMEM;
		return -ENOMEM;