From patchwork Mon May 6 13:44:18 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gavin Shan X-Patchwork-Id: 241668 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from ozlabs.org (localhost [IPv6:::1]) by ozlabs.org (Postfix) with ESMTP id 7983D2C0235 for ; Mon, 6 May 2013 23:45:44 +1000 (EST) Received: from e9.ny.us.ibm.com (e9.ny.us.ibm.com [32.97.182.139]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "e9.ny.us.ibm.com", Issuer "GeoTrust SSL CA" (not verified)) by ozlabs.org (Postfix) with ESMTPS id 7BE422C00F5 for ; Mon, 6 May 2013 23:44:41 +1000 (EST) Received: from /spool/local by e9.ny.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 6 May 2013 09:44:38 -0400 Received: from d01dlp03.pok.ibm.com (9.56.250.168) by e9.ny.us.ibm.com (192.168.1.109) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Mon, 6 May 2013 09:44:36 -0400 Received: from d01relay04.pok.ibm.com (d01relay04.pok.ibm.com [9.56.227.236]) by d01dlp03.pok.ibm.com (Postfix) with ESMTP id 4C96DC90028 for ; Mon, 6 May 2013 09:44:35 -0400 (EDT) Received: from d03av04.boulder.ibm.com (d03av04.boulder.ibm.com [9.17.195.170]) by d01relay04.pok.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id r46DiZZb290254 for ; Mon, 6 May 2013 09:44:35 -0400 Received: from d03av04.boulder.ibm.com (loopback [127.0.0.1]) by d03av04.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id r46DiWvV012346 for ; Mon, 6 May 2013 07:44:34 -0600 Received: from shangw ([9.125.31.68]) by d03av04.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id r46DiMjr011081; Mon, 6 May 2013 07:44:23 -0600 Received: by shangw (Postfix, from userid 1000) id 727613019BA; Mon, 6 May 2013 21:44:22 +0800 (CST) From: Gavin Shan To: linuxppc-dev@lists.ozlabs.org, linux-pci@vger.kernel.org Subject: [PATCH 3/3] powerpc/powernv: Don't configure IO window on PHB3 Date: Mon, 6 May 2013 21:44:18 +0800 Message-Id: <1367847858-6506-3-git-send-email-shangw@linux.vnet.ibm.com> X-Mailer: git-send-email 1.7.5.4 In-Reply-To: <1367847858-6506-1-git-send-email-shangw@linux.vnet.ibm.com> References: <1367847858-6506-1-git-send-email-shangw@linux.vnet.ibm.com> X-TM-AS-MML: No X-Content-Scanned: Fidelis XPS MAILER x-cbid: 13050613-7182-0000-0000-0000068E1826 Cc: bhelgaas@google.com, yinghai@kernel.org, Gavin Shan X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" We needn't configure IO windows for the corresponding PEs on PHB3 since that doesn't support IO. Signed-off-by: Gavin Shan --- arch/powerpc/platforms/powernv/pci-ioda.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/arch/powerpc/platforms/powernv/pci-ioda.c b/arch/powerpc/platforms/powernv/pci-ioda.c index 0c3fa29..b4f3edb 100644 --- a/arch/powerpc/platforms/powernv/pci-ioda.c +++ b/arch/powerpc/platforms/powernv/pci-ioda.c @@ -894,7 +894,9 @@ static void pnv_ioda_setup_pe_seg(struct pci_controller *hose, res->start > res->end) continue; - if (res->flags & IORESOURCE_IO) { + /* We needn't setup IO windows for PHB3 */ + if (!(pe->pbus->bus_flags & PCI_BUS_FLAGS_NO_IO) && + res->flags & IORESOURCE_IO) { region.start = res->start - phb->ioda.io_pci_base; region.end = res->end - phb->ioda.io_pci_base; index = region.start / phb->ioda.io_segsize;