From: Chaehyun Lim Date: Mon, 17 Aug 2015 02:05:10 +0000 (+0900) Subject: staging: wilc1000: use kmalloc instead of WILC_NEW X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5c07828f5db4c620a4f574b3a4bb0a0bba82826b;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git staging: wilc1000: use kmalloc instead of WILC_NEW WILC_NEW is replaced by kmallo with GFP_ATOMIC. This kmalloc is inside a spin_lock_irqsave region. Signed-off-by: Chaehyun Lim Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/wilc1000/wilc_msgqueue.c b/drivers/staging/wilc1000/wilc_msgqueue.c index d9035482ecd2..70e4fa6a07a6 100644 --- a/drivers/staging/wilc1000/wilc_msgqueue.c +++ b/drivers/staging/wilc1000/wilc_msgqueue.c @@ -68,7 +68,7 @@ WILC_ErrNo WILC_MsgQueueSend(WILC_MsgQueueHandle *pHandle, spin_lock_irqsave(&pHandle->strCriticalSection, flags); /* construct a new message */ - pstrMessage = WILC_NEW(Message, 1); + pstrMessage = kmalloc(sizeof(Message), GFP_ATOMIC); WILC_NULLCHECK(s32RetStatus, pstrMessage); pstrMessage->u32Length = u32SendBufferSize; pstrMessage->pstrNext = NULL;