From patchwork Thu May 29 16:03:46 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kumar Gala X-Patchwork-Id: 4266141 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id A10FBBEEA7 for ; Thu, 29 May 2014 16:06:44 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DB128202DD for ; Thu, 29 May 2014 16:06:43 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 3333120125 for ; Thu, 29 May 2014 16:06:42 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1Wq2oY-0000sf-PR; Thu, 29 May 2014 16:04:22 +0000 Received: from smtp.codeaurora.org ([198.145.11.231]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1Wq2oK-0000dW-MK for linux-arm-kernel@lists.infradead.org; Thu, 29 May 2014 16:04:12 +0000 Received: from smtp.codeaurora.org (localhost [127.0.0.1]) by smtp.codeaurora.org (Postfix) with ESMTP id 3FF8513F414; Thu, 29 May 2014 16:03:50 +0000 (UTC) Received: by smtp.codeaurora.org (Postfix, from userid 486) id 2B4CC13F4C8; Thu, 29 May 2014 16:03:50 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from galak-ubuntu.qualcomm.com (rrcs-67-52-129-61.west.biz.rr.com [67.52.129.61]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: galak@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 6BBCB13F414; Thu, 29 May 2014 16:03:48 +0000 (UTC) From: Kumar Gala To: Rob Herring , Grant Likely , Pawel Moll , Mark Rutland , Ian Campbell , Bjorn Helgaas Subject: [PATCH] of: treat PCI config space as IORESOURCE_MEM type Date: Thu, 29 May 2014 11:03:46 -0500 Message-Id: <1401379426-9701-1-git-send-email-galak@codeaurora.org> X-Mailer: git-send-email 1.8.2.1 X-Virus-Scanned: ClamAV using ClamSMTP X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140529_090408_745803_8DC29008 X-CRM114-Status: GOOD ( 11.65 ) X-Spam-Score: -0.7 (/) Cc: devicetree@vger.kernel.org, Liviu Dudau , linux-arm-msm@vger.kernel.org, Kumar Gala , linux-kernel@vger.kernel.org, Kishon Vijay Abraham I , linux-pci@vger.kernel.org, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP If we have a PCI config space specified in something like a ranges property we should treat it as memory type resource. Signed-off-by: Kumar Gala --- drivers/of/address.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/of/address.c b/drivers/of/address.c index cb4242a..4e7ee59 100644 --- a/drivers/of/address.c +++ b/drivers/of/address.c @@ -122,6 +122,9 @@ static unsigned int of_bus_pci_get_flags(const __be32 *addr) u32 w = be32_to_cpup(addr); switch((w >> 24) & 0x03) { + case 0x00: /* cfg space */ + flags |= IORESOURCE_MEM; + break; case 0x01: flags |= IORESOURCE_IO; break;