Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754688AbbHFQSa (ORCPT ); Thu, 6 Aug 2015 12:18:30 -0400 Received: from bh-25.webhostbox.net ([208.91.199.152]:44696 "EHLO bh-25.webhostbox.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751075AbbHFQS2 (ORCPT ); Thu, 6 Aug 2015 12:18:28 -0400 Message-ID: <55C388CF.4090501@roeck-us.net> Date: Thu, 06 Aug 2015 09:18:23 -0700 From: Guenter Roeck User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.8.0 MIME-Version: 1.0 To: Yinghai Lu CC: Bjorn Helgaas , "linux-pci@vger.kernel.org" , Linux Kernel Mailing List , Lorenzo Pieralisi Subject: Re: [PATCH v3] PCI: Only enable IO window if supported References: <1438308908-12259-1-git-send-email-linux@roeck-us.net> <55C2C4F4.1040600@roeck-us.net> <55C2E79E.3090809@roeck-us.net> In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Authenticated_sender: linux@roeck-us.net X-OutGoing-Spam-Status: No, score=-1.0 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - bh-25.webhostbox.net X-AntiAbuse: Original Domain - vger.kernel.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - roeck-us.net X-Get-Message-Sender-Via: bh-25.webhostbox.net: authenticated_id: linux@roeck-us.net X-Source: X-Source-Args: X-Source-Dir: Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1708 Lines: 47 On 08/06/2015 08:58 AM, Yinghai Lu wrote: > On Wed, Aug 5, 2015 at 9:50 PM, Guenter Roeck wrote: >> If I understand you correctly, we might need to change the code >> in pci_read_bridge_io() as follows. >> >> From >> >> if (!(child->bus_flags & PCI_BUS_FLAGS_SUPPORTS_IO)) >> return; >> >> to something like >> >> if (!(child->bus_flags & PCI_BUS_FLAGS_SUPPORTS_IO)) { >> if (dev->transparent) >> return; >> child->bus_flags |= PCI_BUS_FLAGS_SUPPORTS_IO; >> } >> > Then how about: the root bus really does not support IO PORT resource. > Ok, I admit that I am lost. Earlier it seemed that you were concerned about this case, where no io window is available or a bus doesn't support io, but a non-transparent child does. Now you seem to say that the non-transparent child would not be able to support IO either. For my education, can you list the possible options, and how you suggest to solve them ? I can see the following situations. - root supports IO, but has no io window assigned - root does not support IO and has or has not an IO window assigned - a bridge does not support IO For the transparent case, each of those should result in all children not even trying to assign an IO window, which is what we want, and what my patc set tries to do. How should those cases be handled for non-transparent bridges ? Thanks, Guenter -- 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/