All of lore.kernel.org
 help / color / mirror / Atom feed
From: mike@compulab.co.il (Mike Rapoport)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 07/16] ARM: Make PCIBIOS_* into global variables.
Date: Thu, 16 Dec 2010 08:51:45 +0200	[thread overview]
Message-ID: <4D09B701.3060204@compulab.co.il> (raw)
In-Reply-To: <20101215020331.GZ15575@mail.wantstofly.org>

On 12/15/10 04:03, Lennert Buytenhek wrote:
> From: Eric Miao <eric.miao@canonical.com>
> 
> And initialized with pci_common_init(), so that now <asm/pci.h>
> doesn't depend on <mach/hardware.h> any more.
> 
> Signed-off-by: Eric Miao <eric.miao@canonical.com>
> 
> [ buytenh at wantstofly.org: adapt to "Always reassign PCI bus numbers"
>   change, added support for cns3xxx, ixp4xx/vulcan-pci.c, mv78xx0,
>   tegra, rename platform PCIBIOS_MIN_* defines to avoid namespace
>   clashes, rename the arch-wide global variables themselves to
>   PCIBIOS_MIN_* to match mips/sh, build fixes. ]
> 
> Signed-off-by: Lennert Buytenhek <buytenh@secretlab.ca>
> ---

[ snip ]

> diff --git a/arch/arm/mach-pxa/cm-x2xx-pci.c b/arch/arm/mach-pxa/cm-x2xx-pci.c
> index 0f31305..f810a0e 100644
> --- a/arch/arm/mach-pxa/cm-x2xx-pci.c
> +++ b/arch/arm/mach-pxa/cm-x2xx-pci.c
> @@ -21,6 +21,8 @@
>  #include <linux/irq.h>
>  #include <linux/gpio.h>
>  
> +#include <mach/hardware.h>
> +
>  #include <asm/mach/pci.h>
>  #include <asm/mach-types.h>
>  
> @@ -214,8 +216,10 @@ static struct hw_pci cmx2xx_pci __initdata = {
>  
>  static int __init cmx2xx_init_pci(void)
>  {
> -	if (machine_is_armcore())
> -		pci_common_init(&cmx2xx_pci);
> +	if (machine_is_armcore()) {
> +		pci_common_init(&cmx2xx_pci, PXA_PCIBIOS_MIN_IO,
> +				PXA_PCIBIOS_MIN_MEM);
> +	}
>  
>  	return 0;
>  }
> diff --git a/arch/arm/mach-pxa/include/mach/hardware.h b/arch/arm/mach-pxa/include/mach/hardware.h
> index ad448af..86ea43f 100644
> --- a/arch/arm/mach-pxa/include/mach/hardware.h
> +++ b/arch/arm/mach-pxa/include/mach/hardware.h
> @@ -318,8 +318,8 @@ extern unsigned long get_clock_tick_rate(void);
>  #endif
>  
>  #if defined(CONFIG_MACH_ARMCORE) && defined(CONFIG_PCI)
> -#define PCIBIOS_MIN_IO		0
> -#define PCIBIOS_MIN_MEM		0
> +#define PXA_PCIBIOS_MIN_IO	0
> +#define PXA_PCIBIOS_MIN_MEM	0
>  #define ARCH_HAS_DMA_SET_COHERENT_MASK
>  #endif
>  

I think that in PXA case the PCIBIOS_MIN_{IO,MEM} can be completely dropped from
the mach/hardware.h and defined locally in the cm-x2xx-pci.c. Since PXA does not
have on-SoC PCI controller, there's no much sense to define
PXA_PCIBIOS_MIN_{IO,MEM} at all.

> diff --git a/arch/arm/mach-shark/include/mach/hardware.h b/arch/arm/mach-shark/include/mach/hardware.h
> index 24639ce..7d3f0e3 100644
> --- a/arch/arm/mach-shark/include/mach/hardware.h
> +++ b/arch/arm/mach-shark/include/mach/hardware.h
> @@ -12,8 +12,9 @@


-- 
Sincerely yours,
Mike.

  reply	other threads:[~2010-12-16  6:51 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <cover.1292377339.git.buytenh@wantstofly.org>
2010-12-15  2:02 ` [PATCH 01/16] ARM: Remove dependency of plat-orion time code on mach directory includes Lennert Buytenhek
2010-12-15  2:44   ` Nicolas Pitre
2010-12-15  9:16     ` Lennert Buytenhek
2010-12-15 15:37       ` Nicolas Pitre
2010-12-15 16:25   ` Russell King - ARM Linux
2010-12-15 16:59     ` Nicolas Pitre
2010-12-15  2:02 ` [PATCH 02/16] ARM: Remove dependency of plat-orion GPIO " Lennert Buytenhek
2010-12-15  8:08   ` Saeed Bishara
2010-12-15  9:10     ` Lennert Buytenhek
2010-12-15 15:34     ` Nicolas Pitre
2010-12-15  2:03 ` [PATCH 03/16] ARM: Remove some spurious mach dir includes Lennert Buytenhek
2010-12-15  2:03 ` [PATCH 04/16] ARM: Dove: Remove PXA compatibility IRQ defines Lennert Buytenhek
2010-12-15  8:10   ` Saeed Bishara
2010-12-15 13:13   ` Sergei Shtylyov
2010-12-15  2:03 ` [PATCH 05/16] ARM: Always reassign PCI bus numbers Lennert Buytenhek
2010-12-15  2:03 ` [PATCH 06/16] ARM: iop13xx: Make PCIBIOS_MIN_* constants Lennert Buytenhek
2010-12-15  2:03 ` [PATCH 07/16] ARM: Make PCIBIOS_* into global variables Lennert Buytenhek
2010-12-16  6:51   ` Mike Rapoport [this message]
2010-12-15  2:03 ` [PATCH 08/16] ARM: at91: Switch over to gpiolib ->to_irq() and __gpio_to_irq() Lennert Buytenhek
2010-12-17  9:55   ` Nicolas Ferre
2010-12-17 13:00     ` Jean-Christophe PLAGNIOL-VILLARD
2010-12-15  2:03 ` [PATCH 09/16] ARM: ep93xx: " Lennert Buytenhek
2010-12-15  2:03 ` [PATCH 10/16] ARM: gemini: " Lennert Buytenhek
2010-12-17 12:03   ` Hans Ulli Kroll
2010-12-15  2:03 ` [PATCH 11/16] ARM: mxc: " Lennert Buytenhek
2010-12-15 14:22   ` Sascha Hauer
2010-12-16  9:00     ` Shawn Guo
2010-12-16  9:58       ` Uwe Kleine-König
2010-12-15  2:03 ` [PATCH 12/16] ARM: pxa: Provide gpiolib ->to_irq() implementation Lennert Buytenhek
2010-12-15  2:03 ` [PATCH 13/16] ARM: mmp: Switch over to gpiolib's version of __gpio_to_irq() Lennert Buytenhek
2010-12-15  2:03 ` [PATCH 14/16] ARM: pxa: " Lennert Buytenhek
2010-12-15  2:03 ` [PATCH 15/16] ARM: sa1100: Switch over to gpiolib ->to_irq() and __gpio_to_irq() Lennert Buytenhek
2010-12-15  2:04 ` [PATCH 16/16] ARM: w90x900: " Lennert Buytenhek
2010-12-15  2:08   ` Wan ZongShun
2010-12-15  2:09   ` Wan ZongShun
2010-12-15  2:18   ` Wan ZongShun

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4D09B701.3060204@compulab.co.il \
    --to=mike@compulab.co.il \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.