diff --git a/drivers/iommu/intel/iommu.c b/drivers/iommu/intel/iommu.c index 606c4f6f3d849b9a35b30b3e831b7c9a103f6a7c..fe94013e9a620352c3f74e2908f54d3b807b39f8 100644 --- a/drivers/iommu/intel/iommu.c +++ b/drivers/iommu/intel/iommu.c @@ -5262,6 +5262,8 @@ static int auxiliary_link_device(struct dmar_domain *domain, if (!sinfo) { sinfo = kzalloc(sizeof(*sinfo), GFP_ATOMIC); + if (!sinfo) + return -ENOMEM; sinfo->domain = domain; sinfo->pdev = dev; list_add(&sinfo->link_phys, &info->subdevices);