Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758314Ab2BIVgX (ORCPT ); Thu, 9 Feb 2012 16:36:23 -0500 Received: from gate.crashing.org ([63.228.1.57]:55540 "EHLO gate.crashing.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758216Ab2BIVgV (ORCPT ); Thu, 9 Feb 2012 16:36:21 -0500 Message-ID: <1328823358.2903.77.camel@pasglop> Subject: Re: [PATCH 09/24] PCI, powerpc: Register busn_res for root buses From: Benjamin Herrenschmidt To: Bjorn Helgaas Cc: Yinghai Lu , Jesse Barnes , Tony Luck , Dominik Brodowski , Andrew Morton , Linus Torvalds , linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, Paul Mackerras , linuxppc-dev@lists.ozlabs.org Date: Fri, 10 Feb 2012 08:35:58 +1100 In-Reply-To: References: <1328425088-6562-1-git-send-email-yinghai@kernel.org> <1328425088-6562-10-git-send-email-yinghai@kernel.org> <1328738567.2903.45.camel@pasglop> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.2.2- Content-Transfer-Encoding: 7bit Mime-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1618 Lines: 35 On Thu, 2012-02-09 at 11:24 -0800, Bjorn Helgaas wrote: > My point is that the interface between the arch and the PCI core > should be simply the arch telling the core "this is the range of bus > numbers you can use." If the firmware doesn't give you the HW limits, > that's the arch's problem. If you want to assume 0..255 are > available, again, that's the arch's decision. > > But the answer to the question "what bus numbers are available to me" > depends only on the host bridge HW configuration. It does not depend > on what pci_scan_child_bus() found. Therefore, I think we can come up > with a design where pci_bus_update_busn_res_end() is unnecessary. In an ideal world yes. In a world where there are reverse engineered platforms on which we aren't 100% sure how thing actually work under the hood and have the code just adapt on "what's there" (and try to fix it up -sometimes-), thinks can get a bit murky :-) But yes, I see your point. As for what is the "correct" setting that needs to be done so that the patch doesn't end up a regression for us, I'll have to dig into some ancient HW to dbl check a few things. I hope 0...255 will just work but I can't guarantee it. What I'll probably do is constraint the core to the values in hose->min/max, and update selected platforms to put 0..255 in there when I know for sure they can cope. Cheers, Ben. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/