From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753491AbYI3OtI (ORCPT ); Tue, 30 Sep 2008 10:49:08 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752759AbYI3Osy (ORCPT ); Tue, 30 Sep 2008 10:48:54 -0400 Received: from smtp1.linux-foundation.org ([140.211.169.13]:44633 "EHLO smtp1.linux-foundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752406AbYI3Osx (ORCPT ); Tue, 30 Sep 2008 10:48:53 -0400 Date: Tue, 30 Sep 2008 07:48:00 -0700 (PDT) From: Linus Torvalds To: Rene Herman cc: Bjorn Helgaas , Jesse Barnes , Len Brown , Frans Pop , "Rafael J. Wysocki" , linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, linux-acpi@vger.kernel.org, Adam Belay , Avuton Olrich , Karl Bellve , Willem Riede , Matthew Hall Subject: Re: [patch 2/2] PNP: don't check disabled PCI BARs for conflicts in quirk_system_pci_resources() In-Reply-To: <48E1EF0E.8030006@keyaccess.nl> Message-ID: References: <200809290953.56565.bjorn.helgaas@hp.com> <200809290957.59813.bjorn.helgaas@hp.com> <48E11EFA.8010402@keyaccess.nl> <48E1EF0E.8030006@keyaccess.nl> User-Agent: Alpine 2.00 (LFD 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 30 Sep 2008, Rene Herman wrote: > > Just did the attached which might match that intention. Please do not consider > this a submission as I've no idea if this is sensible nor if it actually helps > Frans. Just for discussion. Anything here should arrive through Bjorn. I think you got the logic the wrong way around: + /* have we been registered already? */ + if (pci_res->parent) + continue; This ignores resources that are _registered_, but it should be the other way around - we should ignore resources that aren't (because they may be invalid or they may move around) + pci_start = pci_res->start; + pci_end = pci_res->end; + + if (pci_end < pci_start || !pci_end) + continue; Hmm. This should be unnecessary with any registered resource, since the resource code wouldn't allow registering such a resource in the first place. Of course, it may be that the PnP code runs too early, and we have only parsed the PCI resources, not inserted them into the resource tree yet. If so, none of this will work, of course. Linus