lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <BANLkTinYLcgh=Q2ODv9PraDdTQJkf4B2qA@mail.gmail.com>
Date:	Thu, 21 Apr 2011 16:16:47 -0700
From:	Yinghai Lu <yinghai@...nel.org>
To:	Alex Williamson <alex.williamson@...hat.com>
Cc:	dwmw2@...radead.org, iommu@...ts.linux-foundation.org,
	linux-kernel@...r.kernel.org, linux-pci@...r.kernel.org,
	ddutile@...hat.com, chrisw@...hat.com
Subject: Re: [RESEND PATCH v2 2/2] intel-iommu: Fix get_domain_for_dev() error path

On Fri, Mar 4, 2011 at 1:52 PM, Alex Williamson
<alex.williamson@...hat.com> wrote:
> If we run out of domain_ids and fail iommu_attach_domain(), we
> fall into domain_exit() without having setup enough of the
> domain structure for this to do anything useful.  In fact, it
> typically runs off into the weeds walking the bogus domain->devices
> list.  Just free the domain.
>
> Signed-off-by: Alex Williamson <alex.williamson@...hat.com>
> Acked-by: Donald Dutile <ddutile@...hat.com>
> ---
>
>  drivers/pci/intel-iommu.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/pci/intel-iommu.c b/drivers/pci/intel-iommu.c
> index c58dbd7..4a66bea 100644
> --- a/drivers/pci/intel-iommu.c
> +++ b/drivers/pci/intel-iommu.c
> @@ -1835,7 +1835,7 @@ static struct dmar_domain *get_domain_for_dev(struct pci_dev *pdev, int gaw)
>
>        ret = iommu_attach_domain(domain, iommu);
>        if (ret) {
> -               domain_exit(domain);
> +               free_domain_mem(domain);
>                goto error;
>        }
>
>

can you fix another path like David pointed out last year?

https://patchwork.kernel.org/patch/91732/

Thanks

Yinghai
--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ