[PATCH] block: nvme-scsi: Catch kcalloc failure

Jens Axboe axboe at fb.com
Sat Jun 20 09:33:22 PDT 2015


On 06/20/2015 02:29 AM, Axel Lin wrote:
> res variable was initialized to -ENOMEM, but it's override by
> nvme_trans_copy_from_user(). So current code returns 0 if kcalloc fails.
> Fix it to return proper error code.

Looks good to me, applied for 4.2.

-- 
Jens Axboe




More information about the Linux-nvme mailing list