Thread (6 messages) 6 messages, 6 authors, 2016-11-22

Re: [PATCH] cxl: Fix memory allocation failure test

From: Andrew Donnellan <hidden>
Date: 2016-10-31 06:16:57
Also in: kernel-janitors, lkml

On 31/10/16 06:35, Christophe JAILLET wrote:
'cxl_context_alloc()' does not return an error pointer. It is just a
shortcut for a call to 'kzalloc' with 'sizeof(struct cxl_context)' as the
size parameter.

So its return value should be compared with NULL.
While fixing it, simplify a bit the code.

Signed-off-by: Christophe JAILLET <redacted>
Reviewed-by: Andrew Donnellan <redacted>
---
un-compiled because I don't have the required  cross build environment.
Compiles on my system!

-- 
Andrew Donnellan              OzLabs, ADL Canberra
andrew.donnellan@au1.ibm.com  IBM Australia Limited
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help