vfio/spapr_tce: Check kzalloc() return when preregistering memory
authorAlexey Kardashevskiy <aik@ozlabs.ru>
Mon, 27 Mar 2017 03:23:40 +0000 (14:23 +1100)
committerAlex Williamson <alex.williamson@redhat.com>
Tue, 11 Apr 2017 19:40:09 +0000 (13:40 -0600)
commit3393af24b665cb0aea7353b05e522b03ab1e7d73
tree4cead9a9bc1979fa5e333fca7a9b6185b405ee0b
parent1282ba7fc28dbc66c3f0e4aaafaaa228361d1ae5
vfio/spapr_tce: Check kzalloc() return when preregistering memory

This adds missing checking for kzalloc() return value.

Fixes: 4b6fad7097f8 ("powerpc/mm/iommu, vfio/spapr: Put pages on VFIO container shutdown")
Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Reviewed-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
drivers/vfio/vfio_iommu_spapr_tce.c