From patchwork Tue Feb 4 16:41:14 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Catalin Marinas X-Patchwork-Id: 24127 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-qa0-f69.google.com (mail-qa0-f69.google.com [209.85.216.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 15068202FA for ; Tue, 4 Feb 2014 16:42:04 +0000 (UTC) Received: by mail-qa0-f69.google.com with SMTP id w8sf20673177qac.4 for ; Tue, 04 Feb 2014 08:42:04 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:date:from:to:cc:subject:message-id :references:mime-version:in-reply-to:user-agent:sender:precedence :list-id:x-original-sender:x-original-authentication-results :mailing-list:list-post:list-help:list-archive:list-unsubscribe :content-type:content-disposition; bh=F/9b8GHFJ20alEmcg21eSA9FELnkWfrwz84/prg71UE=; b=ID1/ajAHpTG0WwlV5YnpCKe9nuvxpmuPWZ1HCTVI6/GR26ES94ijknMQOM3XiPNrU2 bF97/tgDRVacwOyAO/mQRCQMfKnSolo1JHLTZYzQUPLzq1wv5KP4Zd9CHBK5YN/qMR60 /AnQBriiYsf0EsZYRcSXgHeSBEtci+e15MkJ4Kjqze77PBRZlZkxumVyRQh23JaagF8P t6rULXddeWTIMTrTGu25M/U85jpxRXCnapojsJoEIHNSA6GMishY+oLV6UVK456KAiaf 5wbFds9faqiMrk+/B3dmnMxUulu8PJxlgtNIuf2ZX3VkxQwHpsDhRPCqdnpyXg02KYQX PFGQ== X-Gm-Message-State: ALoCoQlG06zrwPE4tCfFCDkParx6d5Y4Hc72Nn78wiEknw31DBmjEMCFuOL3cXQmUbhHLftwr9VS X-Received: by 10.236.26.83 with SMTP id b59mr3929739yha.51.1391532124208; Tue, 04 Feb 2014 08:42:04 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.84.165 with SMTP id l34ls2260179qgd.5.gmail; Tue, 04 Feb 2014 08:42:04 -0800 (PST) X-Received: by 10.58.145.9 with SMTP id sq9mr173358veb.53.1391532124060; Tue, 04 Feb 2014 08:42:04 -0800 (PST) Received: from mail-ve0-f182.google.com (mail-ve0-f182.google.com [209.85.128.182]) by mx.google.com with ESMTPS id cy15si8354807veb.144.2014.02.04.08.42.03 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 04 Feb 2014 08:42:03 -0800 (PST) Received-SPF: neutral (google.com: 209.85.128.182 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.128.182; Received: by mail-ve0-f182.google.com with SMTP id jy13so6352016veb.27 for ; Tue, 04 Feb 2014 08:42:03 -0800 (PST) X-Received: by 10.58.49.129 with SMTP id u1mr34321574ven.0.1391532123756; Tue, 04 Feb 2014 08:42:03 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.174.196 with SMTP id u4csp250303vcz; Tue, 4 Feb 2014 08:42:02 -0800 (PST) X-Received: by 10.66.142.107 with SMTP id rv11mr45288793pab.17.1391532122144; Tue, 04 Feb 2014 08:42:02 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id cf2si14543269pad.314.2014.02.04.08.41.57; Tue, 04 Feb 2014 08:41:57 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753431AbaBDQl4 (ORCPT + 9 others); Tue, 4 Feb 2014 11:41:56 -0500 Received: from fw-tnat.austin.arm.com ([217.140.110.23]:30968 "EHLO collaborate-mta1.arm.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752629AbaBDQlz (ORCPT ); Tue, 4 Feb 2014 11:41:55 -0500 Received: from arm.com (e102109-lin.cambridge.arm.com [10.1.203.24]) by collaborate-mta1.arm.com (Postfix) with ESMTPS id 961C213F651; Tue, 4 Feb 2014 10:41:50 -0600 (CST) Date: Tue, 4 Feb 2014 16:41:14 +0000 From: Catalin Marinas To: Arnd Bergmann Cc: "linaro-kernel@lists.linaro.org" , Liviu Dudau , "devicetree@vger.kernel.org" , LKML , linux-pci , Bjorn Helgaas , LAKML Subject: Re: [PATCH] arm64: Add architecture support for PCI Message-ID: <20140204164114.GJ30676@arm.com> References: <1391453028-23191-1-git-send-email-Liviu.Dudau@arm.com> <3808209.DeG1VobanZ@wuerfel> <20140203213658.GA24036@e106497-lin.cambridge.arm.com> <3277167.UhkSU8Sf56@wuerfel> MIME-Version: 1.0 In-Reply-To: <3277167.UhkSU8Sf56@wuerfel> User-Agent: Mutt/1.5.20 (2009-06-14) Sender: devicetree-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: devicetree@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: catalin.marinas@arm.com X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.128.182 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Content-Disposition: inline On Tue, Feb 04, 2014 at 08:44:36AM +0000, Arnd Bergmann wrote: > On Monday 03 February 2014 21:36:58 Liviu Dudau wrote: > > On Mon, Feb 03, 2014 at 08:05:56PM +0000, Arnd Bergmann wrote: > > > 2 MB was a compromise on arm32 to allow up to 32 PCI host bridges but not > > > take up too much virtual space. On arm64 it should be at least as big. > > > Could be more than that, although I don't see a reason why it should be, > > > unless we expect to see systems with tons of host bridges, or buses > > > that exceed 64KB of I/O space. > > > > I will increase the size to 2MB for v2. > > Thinking about this some more, I'd go a little higher. In case of > pci_mv, we already register a 1MB region for one logical host > (which has multiple I/O spaces behind an emulated bridge), so > going to 16MB or more would let us handle multiple 1MB windows > for some amount of future proofing. > > Maybe Catalin can assign us some virtual address space to use, > with the constraints that it should be 16MB or more in an > area that doesn't require additional kernel page table pages. See below, 16MB and could be extended further if needed. ------------>8-------------------- >From 00521f109ac8a2589c9089a5feaaaa1be7f26108 Mon Sep 17 00:00:00 2001 From: Catalin Marinas Date: Tue, 4 Feb 2014 16:37:59 +0000 Subject: [PATCH] arm64: Extend the PCI I/O space to 16MB The patch moves the PCI I/O space (currently at 64K) before the earlyprintk mapping and extends it to 16MB. Signed-off-by: Catalin Marinas --- Documentation/arm64/memory.txt | 16 ++++++++++------ arch/arm64/include/asm/io.h | 2 +- 2 files changed, 11 insertions(+), 7 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/Documentation/arm64/memory.txt b/Documentation/arm64/memory.txt index 5e054bfe4dde..85e24c4f215c 100644 --- a/Documentation/arm64/memory.txt +++ b/Documentation/arm64/memory.txt @@ -35,11 +35,13 @@ ffffffbc00000000 ffffffbdffffffff 8GB vmemmap ffffffbe00000000 ffffffbffbbfffff ~8GB [guard, future vmmemap] -ffffffbffbc00000 ffffffbffbdfffff 2MB earlyprintk device +ffffffbffa000000 ffffffbffaffffff 16MB PCI I/O space + +ffffffbffb000000 ffffffbffbbfffff 12MB [guard] -ffffffbffbe00000 ffffffbffbe0ffff 64KB PCI I/O space +ffffffbffbc00000 ffffffbffbdfffff 2MB earlyprintk device -ffffffbffbe10000 ffffffbcffffffff ~2MB [guard] +ffffffbffbe00000 ffffffbffbffffff 2MB [guard] ffffffbffc000000 ffffffbfffffffff 64MB modules @@ -60,11 +62,13 @@ fffffdfc00000000 fffffdfdffffffff 8GB vmemmap fffffdfe00000000 fffffdfffbbfffff ~8GB [guard, future vmmemap] -fffffdfffbc00000 fffffdfffbdfffff 2MB earlyprintk device +fffffdfffa000000 fffffdfffaffffff 16MB PCI I/O space + +fffffdfffb000000 fffffdfffbbfffff 12MB [guard] -fffffdfffbe00000 fffffdfffbe0ffff 64KB PCI I/O space +fffffdfffbc00000 fffffdfffbdfffff 2MB earlyprintk device -fffffdfffbe10000 fffffdfffbffffff ~2MB [guard] +fffffdfffbe00000 fffffdfffbffffff 2MB [guard] fffffdfffc000000 fffffdffffffffff 64MB modules diff --git a/arch/arm64/include/asm/io.h b/arch/arm64/include/asm/io.h index 4cc813eddacb..7846a6bb0833 100644 --- a/arch/arm64/include/asm/io.h +++ b/arch/arm64/include/asm/io.h @@ -121,7 +121,7 @@ static inline u64 __raw_readq(const volatile void __iomem *addr) * I/O port access primitives. */ #define IO_SPACE_LIMIT 0xffff -#define PCI_IOBASE ((void __iomem *)(MODULES_VADDR - SZ_2M)) +#define PCI_IOBASE ((void __iomem *)(MODULES_VADDR - SZ_32M)) static inline u8 inb(unsigned long addr) {