[<prev] [next>] [day] [month] [year] [list]
Message-ID: <529BE547.9030508@huawei.com>
Date: Mon, 2 Dec 2013 09:41:27 +0800
From: Yijing Wang <wangyijing@...wei.com>
To: Jiang Liu <jiang.liu@...ux.intel.com>,
Yinghai Lu <yinghai@...nel.org>,
Joerg Roedel <joro@...tes.org>,
David Woodhouse <dwmw2@...radead.org>,
"Dan Williams" <dan.j.williams@...el.com>,
Vinod Koul <vinod.koul@...el.com>,
Ashok Raj <ashok.raj@...el.com>
CC: <iommu@...ts.linux-foundation.org>, <linux-pci@...r.kernel.org>,
<linux-kernel@...r.kernel.org>, <dmaengine@...r.kernel.org>
Subject: Re: [Patch Part1 V2 04/17] iommu/vt-d: fix resource leakage on error
recovery path in iommu_init_domains()
On 2013/11/29 16:50, Jiang Liu wrote:
> Release allocated resources on error recovery path in function
> iommu_init_domains().
>
> Signed-off-by: Jiang Liu <jiang.liu@...ux.intel.com>
> ---
> drivers/iommu/intel-iommu.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/iommu/intel-iommu.c b/drivers/iommu/intel-iommu.c
> index b8e3b48..2398876 100644
> --- a/drivers/iommu/intel-iommu.c
> +++ b/drivers/iommu/intel-iommu.c
> @@ -1273,6 +1273,8 @@ static int iommu_init_domains(struct intel_iommu *iommu)
> GFP_KERNEL);
> if (!iommu->domains) {
> printk(KERN_ERR "Allocating domain array failed\n");
> + kfree(iommu->domain_ids);
> + iommu->domain_ids = NULL;
> return -ENOMEM;
> }
>
>
Acked-by: Yijing Wang <wangyijing@...wei.com>
--
Thanks!
Yijing
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists