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
| ||
|
Date: Fri, 24 Feb 2012 23:47:26 -0800 From: Yinghai Lu <yinghai@...nel.org> To: Jesse Barnes <jbarnes@...tuousgeek.org> Cc: Bjorn Helgaas <bhelgaas@...gle.com>, Benjamin Herrenschmidt <benh@...nel.crashing.org>, Tony Luck <tony.luck@...el.com>, Dominik Brodowski <linux@...inikbrodowski.net>, Andrew Morton <akpm@...ux-foundation.org>, Linus Torvalds <torvalds@...ux-foundation.org>, linux-pci@...r.kernel.org, linux-kernel@...r.kernel.org, linux-arch@...r.kernel.org, Paul Mackerras <paulus@...ba.org>, linuxppc-dev@...ts.ozlabs.org Subject: Re: [PATCH 09/24] PCI, powerpc: Register busn_res for root buses On Fri, Feb 24, 2012 at 2:24 PM, Jesse Barnes <jbarnes@...tuousgeek.org> wrote: > On Thu, 23 Feb 2012 12:51:30 -0800 > Bjorn Helgaas <bhelgaas@...gle.com> wrote: >> 2) We already have a way to add resources to a root bus: the >> pci_add_resource() used to add I/O port and MMIO apertures. I think >> it'd be a lot simpler to just use that same interface for the bus >> number aperture, e.g., >> >> pci_add_resource(&resources, hose->io_space); >> pci_add_resource(&resources, hose->mem_space); >> pci_add_resource(&resources, hose->busnr_space); >> bus = pci_scan_root_bus(dev, next_busno, pci_ops, sysdata, &resources); >> >> This is actually a bit redundant, since "next_busno" should be the >> same as hose->busnr_space->start. So if we adopted this approach, we >> might want to eventually drop the "next_busno" argument. > > Yeah that would be nice, the call would certainly make more sense that > way. no, I don't think so. using pci_add_resource will need to create dummy resource abut bus range. there is lots of pci_scan_root_bus(), and those user does not bus end yet before scan. so could just hide pci_insert_busn_res in pci_scan_root_bus, and update busn_res end there. other arch like x86, ia64, powerpc, sparc, will insert exact bus range between pci_create_root_bus and pci_scan_child_bus, will not need to update busn_res end. please check v7 of this patchset. git://git.kernel.org/pub/scm/linux/kernel/git/yinghai/linux-yinghai.git for-pci-busn-alloc It should be clean and have minimum lines of change. 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