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: <20101112091858.3db4787a@jbarnes-desktop>
Date:	Fri, 12 Nov 2010 09:18:58 -0800
From:	Jesse Barnes <jbarnes@...tuousgeek.org>
To:	Bjorn Helgaas <bjorn.helgaas@...com>
Cc:	Bob Picco <bpicco@...hat.com>,
	Brian Bloniarz <phunge0@...mail.com>,
	Charles Butterfield <charles.butterfield@...tcentury.com>,
	Denys Vlasenko <dvlasenk@...hat.com>,
	Ingo Molnar <mingo@...e.hu>, linux-pci@...r.kernel.org,
	"Horst H. von Brand" <vonbrand@....utfsm.cl>,
	"H. Peter Anvin" <hpa@...or.com>, linux-kernel@...r.kernel.org,
	Borislav Petkov <bp@...64.org>,
	Stefan Becker <chemobejk@...il.com>,
	Chuck Ebbert <cebbert@...hat.com>,
	Fabrice Bellet <fabrice@...let.info>,
	Yinghai Lu <yinghai@...nel.org>,
	Leann Ogasawara <leann.ogasawara@...onical.com>,
	Linus Torvalds <torvalds@...ux-foundation.org>,
	Thomas Gleixner <tglx@...utronix.de>
Subject: Re: [PATCH v2] PCI: fix pci_bus_alloc_resource() hang, prefer
 positive decode

On Wed, 10 Nov 2010 10:26:07 -0700
Bjorn Helgaas <bjorn.helgaas@...com> wrote:

> 
> When a PCI bus has two resources with the same start/end, e.g.,
> 
>     pci_bus 0000:04: resource 2 [mem 0xd0000000-0xd7ffffff pref]
>     pci_bus 0000:04: resource 7 [mem 0xd0000000-0xd7ffffff]
> 
> the previous pci_bus_find_resource_prev() implementation would alternate
> between them forever:
> 
>     pci_bus_find_resource_prev(... [mem 0xd0000000-0xd7ffffff pref])
>         returns [mem 0xd0000000-0xd7ffffff]
>     pci_bus_find_resource_prev(... [mem 0xd0000000-0xd7ffffff])
>         returns [mem 0xd0000000-0xd7ffffff pref]
>     pci_bus_find_resource_prev(... [mem 0xd0000000-0xd7ffffff pref])
>         returns [mem 0xd0000000-0xd7ffffff]
>     ...
> 
> This happened because there was no ordering between two resources with the
> same start and end.  A resource that had the same start and end as the
> cursor, but was not itself the cursor, was considered to be before the
> cursor.
> 
> This patch fixes the hang by making a fixed ordering between any two
> resources.
> 
> In addition, it tries to allocate from positively decoded regions before
> using any subtractively decoded resources.  This means we will use a
> positive decode region before a subtractive decode one, even if it means
> using a smaller address.
> 
> Reference: https://bugzilla.kernel.org/show_bug.cgi?id=22062
> Reported-by: Borislav Petkov <bp@...64.org>
> Signed-off-by: Bjorn Helgaas <bjorn.helgaas@...com>
> ---

Applied to my for-linus branch, thanks.

-- 
Jesse Barnes, Intel Open Source Technology Center
--
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