[PATCH] usnic: correctly handle kzalloc return value

2015-10-19 Thread Insu Yun
Since kzalloc returns memory address, not error code, it should be checked whether it is null or not. Signed-off-by: Insu Yun --- drivers/infiniband/hw/usnic/usnic_ib_qp_grp.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/infiniband/hw/usnic

[PATCH] usnix: correctly handle kzalloc return value

2015-10-17 Thread Insu Yun
Since kzalloc returns memory address, not error code, it should be checked whether it is null or not. Signed-off-by: Insu Yun --- drivers/infiniband/hw/usnic/usnic_ib_qp_grp.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/infiniband/hw/usnic

[PATCH] usnic: correctly check failed allocation

2015-10-15 Thread Insu Yun
Since ib_alloc_device returns allocated memory address, not error, it should be checked as IS_NULL, not IS_ERR_OR_NULL. Signed-off-by: Insu Yun --- drivers/infiniband/hw/usnic/usnic_ib_main.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/drivers/infiniband/hw

[PATCH] usnic: corretly check failed allocation

2015-10-15 Thread Insu Yun
Since ib_alloc_device returns allocated memory address, not error, it should be checked as IS_NULL, not IS_ERR_OR_NULL. Signed-off-by: Insu Yun --- drivers/infiniband/hw/usnic/usnic_ib_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/infiniband/hw/usnic