diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-30 10:04:01 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-30 10:04:01 -0700 |
commit | f54496f55a729078e9eef90bf9e0783857a27db1 (patch) | |
tree | 104cf71ea8349a35990a9d3b58679229a604df31 /arch | |
parent | aa2d3322989d8fd40fb2e417142c9a029d7831a4 (diff) | |
parent | cdea460643072e1ee3647434aa254b5b81364f68 (diff) | |
download | linux-f54496f55a729078e9eef90bf9e0783857a27db1.tar.bz2 |
Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm:
[ARM] Fix some section mismatch warnings
[ARM] 4417/1: Serial: Fix AMBA drivers locking
[ARM] 4394/1: ARMv7: Add the TLB range operations
[ARM] 4410/1: Remove extern declarations in coyote/ixdpg425-pci.c
[ARM] 4416/1: NWFPE: fix undeclared symbols
[ARM] 4415/1: AML5900: fix sparse warnings from map_io
[ARM] 4414/1: S3C2443: sparse fix for clock.c
[ARM] 4412/1: S3C2412: reset errata fix
[ARM] 4411/1: KS8695: Another serial driver fix
[ARM] oprofile: avoid lockdep warnings on mpcore oprofile init
[ARM] Fix stacktrace FP range checking
[ARM] use __used attribute
[ARM] enable arbitary speed tty ioctls and split input/output speed
[ARM] remove unused header file: arch/arm/mach-s3c2410/bast.h
[ARM] 4406/1: Trivial NSLU2 / NAS-100D header & setup code cleanup
[ARM] 4405/1: NSLU2, DSM-G600 frequency fixup code
[ARM] 4404/1: Trivial IXP42x Kconfig cleanup
[ARM] 4403/1: Make the PXA-I2C driver work with lockdep validator
[ARM] 4402/1: S3C2443: Add physical address of HSMMC controller
[ARM] 4401/1: S3C2443: Add definitions for port GPIOJ
Diffstat (limited to 'arch')
33 files changed, 189 insertions, 60 deletions
diff --git a/arch/arm/kernel/armksyms.c b/arch/arm/kernel/armksyms.c index 9179e8220314..f73d62e8ab60 100644 --- a/arch/arm/kernel/armksyms.c +++ b/arch/arm/kernel/armksyms.c @@ -57,7 +57,7 @@ extern void fp_enter(void); #define EXPORT_SYMBOL_ALIAS(sym,orig) \ EXPORT_CRC_ALIAS(sym) \ static const struct kernel_symbol __ksymtab_##sym \ - __attribute_used__ __attribute__((section("__ksymtab"))) = \ + __used __attribute__((section("__ksymtab"))) = \ { (unsigned long)&orig, #sym }; /* diff --git a/arch/arm/kernel/stacktrace.c b/arch/arm/kernel/stacktrace.c index 8b63ad89d0a8..ae31deb2d065 100644 --- a/arch/arm/kernel/stacktrace.c +++ b/arch/arm/kernel/stacktrace.c @@ -13,7 +13,7 @@ int walk_stackframe(unsigned long fp, unsigned long low, unsigned long high, /* * Check current frame pointer is within bounds */ - if ((fp - 12) < low || fp + 4 >= high) + if (fp < (low + 12) || fp + 4 >= high) break; frame = (struct stackframe *)(fp - 12); diff --git a/arch/arm/mach-at91/board-dk.c b/arch/arm/mach-at91/board-dk.c index 6043c38c0a9e..af497896a96c 100644 --- a/arch/arm/mach-at91/board-dk.c +++ b/arch/arm/mach-at91/board-dk.c @@ -132,7 +132,7 @@ static struct mtd_partition __initdata dk_nand_partition[] = { }, }; -static struct mtd_partition *nand_partitions(int size, int *num_partitions) +static struct mtd_partition * __init nand_partitions(int size, int *num_partitions) { *num_partitions = ARRAY_SIZE(dk_nand_partition); return dk_nand_partition; diff --git a/arch/arm/mach-at91/board-kb9202.c b/arch/arm/mach-at91/board-kb9202.c index 76f6e1e553ea..7d9b1a278fd6 100644 --- a/arch/arm/mach-at91/board-kb9202.c +++ b/arch/arm/mach-at91/board-kb9202.c @@ -96,7 +96,7 @@ static struct mtd_partition __initdata kb9202_nand_partition[] = { }, }; -static struct mtd_partition *nand_partitions(int size, int *num_partitions) +static struct mtd_partition * __init nand_partitions(int size, int *num_partitions) { *num_partitions = ARRAY_SIZE(kb9202_nand_partition); return kb9202_nand_partition; diff --git a/arch/arm/mach-at91/board-sam9261ek.c b/arch/arm/mach-at91/board-sam9261ek.c index 1f0c8a400b3a..26ca8ab3f62a 100644 --- a/arch/arm/mach-at91/board-sam9261ek.c +++ b/arch/arm/mach-at91/board-sam9261ek.c @@ -178,7 +178,7 @@ static struct mtd_partition __initdata ek_nand_partition[] = { }, }; -static struct mtd_partition *nand_partitions(int size, int *num_partitions) +static struct mtd_partition * __init nand_partitions(int size, int *num_partitions) { *num_partitions = ARRAY_SIZE(ek_nand_partition); return ek_nand_partition; diff --git a/arch/arm/mach-at91/board-sam9263ek.c b/arch/arm/mach-at91/board-sam9263ek.c index f57458559fb6..c164c8e58ae6 100644 --- a/arch/arm/mach-at91/board-sam9263ek.c +++ b/arch/arm/mach-at91/board-sam9263ek.c @@ -180,7 +180,7 @@ static struct mtd_partition __initdata ek_nand_partition[] = { }, }; -static struct mtd_partition *nand_partitions(int size, int *num_partitions) +static struct mtd_partition * __init nand_partitions(int size, int *num_partitions) { *num_partitions = ARRAY_SIZE(ek_nand_partition); return ek_nand_partition; diff --git a/arch/arm/mach-at91/board-sam9rlek.c b/arch/arm/mach-at91/board-sam9rlek.c index 30c79aca84d4..9b61320f295a 100644 --- a/arch/arm/mach-at91/board-sam9rlek.c +++ b/arch/arm/mach-at91/board-sam9rlek.c @@ -87,7 +87,7 @@ static struct mtd_partition __initdata ek_nand_partition[] = { }, }; -static struct mtd_partition *nand_partitions(int size, int *num_partitions) +static struct mtd_partition * __init nand_partitions(int size, int *num_partitions) { *num_partitions = ARRAY_SIZE(ek_nand_partition); return ek_nand_partition; diff --git a/arch/arm/mach-footbridge/cats-pci.c b/arch/arm/mach-footbridge/cats-pci.c index 4f984fde7375..35eb232a649a 100644 --- a/arch/arm/mach-footbridge/cats-pci.c +++ b/arch/arm/mach-footbridge/cats-pci.c @@ -45,7 +45,7 @@ static struct hw_pci cats_pci __initdata = { .postinit = dc21285_postinit, }; -static int cats_pci_init(void) +static int __init cats_pci_init(void) { if (machine_is_cats()) pci_common_init(&cats_pci); diff --git a/arch/arm/mach-imx/generic.c b/arch/arm/mach-imx/generic.c index 7a7fa51ec62c..1c474cf709ca 100644 --- a/arch/arm/mach-imx/generic.c +++ b/arch/arm/mach-imx/generic.c @@ -201,7 +201,6 @@ void __init imx_set_mmc_info(struct imxmmc_platform_data *info) { imx_mmc_device.dev.platform_data = info; } -EXPORT_SYMBOL(imx_set_mmc_info); static struct imxfb_mach_info imx_fb_info; diff --git a/arch/arm/mach-ixp2000/ixdp2400.c b/arch/arm/mach-ixp2000/ixdp2400.c index 0fdd03ab36e6..ce7c15c73004 100644 --- a/arch/arm/mach-ixp2000/ixdp2400.c +++ b/arch/arm/mach-ixp2000/ixdp2400.c @@ -164,7 +164,7 @@ int __init ixdp2400_pci_init(void) subsys_initcall(ixdp2400_pci_init); -void ixdp2400_init_irq(void) +void __init ixdp2400_init_irq(void) { ixdp2x00_init_irq(IXDP2400_CPLD_INT_STAT, IXDP2400_CPLD_INT_MASK, IXDP2400_NR_IRQS); } diff --git a/arch/arm/mach-ixp2000/ixdp2800.c b/arch/arm/mach-ixp2000/ixdp2800.c index 70d247f09a7e..14f09b80ab77 100644 --- a/arch/arm/mach-ixp2000/ixdp2800.c +++ b/arch/arm/mach-ixp2000/ixdp2800.c @@ -279,7 +279,7 @@ int __init ixdp2800_pci_init(void) subsys_initcall(ixdp2800_pci_init); -void ixdp2800_init_irq(void) +void __init ixdp2800_init_irq(void) { ixdp2x00_init_irq(IXDP2800_CPLD_INT_STAT, IXDP2800_CPLD_INT_MASK, IXDP2800_NR_IRQS); } diff --git a/arch/arm/mach-ixp2000/ixdp2x00.c b/arch/arm/mach-ixp2000/ixdp2x00.c index 011065b967b4..73c651e83d92 100644 --- a/arch/arm/mach-ixp2000/ixdp2x00.c +++ b/arch/arm/mach-ixp2000/ixdp2x00.c @@ -145,7 +145,7 @@ static struct irq_chip ixdp2x00_cpld_irq_chip = { .unmask = ixdp2x00_irq_unmask }; -void ixdp2x00_init_irq(volatile unsigned long *stat_reg, volatile unsigned long *mask_reg, unsigned long nr_irqs) +void __init ixdp2x00_init_irq(volatile unsigned long *stat_reg, volatile unsigned long *mask_reg, unsigned long nr_irqs) { unsigned int irq; diff --git a/arch/arm/mach-ixp23xx/ixdp2351.c b/arch/arm/mach-ixp23xx/ixdp2351.c index 7a86a2516eaa..c41a6b5a0acc 100644 --- a/arch/arm/mach-ixp23xx/ixdp2351.c +++ b/arch/arm/mach-ixp23xx/ixdp2351.c @@ -124,7 +124,7 @@ static struct irq_chip ixdp2351_intb_chip = { .unmask = ixdp2351_intb_unmask }; -void ixdp2351_init_irq(void) +void __init ixdp2351_init_irq(void) { int irq; diff --git a/arch/arm/mach-ixp23xx/pci.c b/arch/arm/mach-ixp23xx/pci.c index ac7d43d23c28..227f808dc0ec 100644 --- a/arch/arm/mach-ixp23xx/pci.c +++ b/arch/arm/mach-ixp23xx/pci.c @@ -284,7 +284,7 @@ int ixp23xx_pci_setup(int nr, struct pci_sys_data *sys) return 1; } -void ixp23xx_pci_slave_init(void) +void __init ixp23xx_pci_slave_init(void) { ixp23xx_pci_common_init(); } diff --git a/arch/arm/mach-ixp23xx/roadrunner.c b/arch/arm/mach-ixp23xx/roadrunner.c index d06e21b70de5..e35644961aa4 100644 --- a/arch/arm/mach-ixp23xx/roadrunner.c +++ b/arch/arm/mach-ixp23xx/roadrunner.c @@ -110,7 +110,7 @@ static int __init roadrunner_map_irq(struct pci_dev *dev, u8 idsel, u8 pin) return NO_IRQ; } -static void roadrunner_pci_preinit(void) +static void __init roadrunner_pci_preinit(void) { set_irq_type(IRQ_ROADRUNNER_PCI_INTC, IRQT_LOW); set_irq_type(IRQ_ROADRUNNER_PCI_INTD, IRQT_LOW); diff --git a/arch/arm/mach-ixp4xx/Kconfig b/arch/arm/mach-ixp4xx/Kconfig index 9715ef506c24..060909870b50 100644 --- a/arch/arm/mach-ixp4xx/Kconfig +++ b/arch/arm/mach-ixp4xx/Kconfig @@ -104,9 +104,6 @@ config MACH_DSMG600 DSM-G600 RevA device. For more information on this platform, see http://www.nslu2-linux.org/wiki/DSMG600/HomePage -# -# Avila and IXDP share the same source for now. Will change in future -# config ARCH_IXDP4XX bool depends on ARCH_IXDP425 || MACH_IXDP465 || MACH_KIXRP435 diff --git a/arch/arm/mach-ixp4xx/common.c b/arch/arm/mach-ixp4xx/common.c index 64685da1462d..8112f726ffa0 100644 --- a/arch/arm/mach-ixp4xx/common.c +++ b/arch/arm/mach-ixp4xx/common.c @@ -283,7 +283,7 @@ static struct irqaction ixp4xx_timer_irq = { .handler = ixp4xx_timer_interrupt, }; -static void __init ixp4xx_timer_init(void) +void __init ixp4xx_timer_init(void) { /* Reset/disable counter */ *IXP4XX_OSRT1 = 0; diff --git a/arch/arm/mach-ixp4xx/coyote-pci.c b/arch/arm/mach-ixp4xx/coyote-pci.c index 7bc94f3def1c..ad2e5b97966e 100644 --- a/arch/arm/mach-ixp4xx/coyote-pci.c +++ b/arch/arm/mach-ixp4xx/coyote-pci.c @@ -25,10 +25,6 @@ #include <asm/mach/pci.h> -extern void ixp4xx_pci_preinit(void); -extern int ixp4xx_setup(int nr, struct pci_sys_data *sys); -extern struct pci_bus *ixp4xx_scan_bus(int nr, struct pci_sys_data *sys); - void __init coyote_pci_preinit(void) { set_irq_type(IRQ_COYOTE_PCI_SLOT0, IRQT_LOW); diff --git a/arch/arm/mach-ixp4xx/dsmg600-setup.c b/arch/arm/mach-ixp4xx/dsmg600-setup.c index 1caff65e22cc..1e75e105c4f7 100644 --- a/arch/arm/mach-ixp4xx/dsmg600-setup.c +++ b/arch/arm/mach-ixp4xx/dsmg600-setup.c @@ -18,6 +18,7 @@ #include <asm/mach-types.h> #include <asm/mach/arch.h> #include <asm/mach/flash.h> +#include <asm/mach/time.h> static struct flash_platform_data dsmg600_flash_data = { .map_name = "cfi_probe", @@ -128,6 +129,19 @@ static void dsmg600_power_off(void) gpio_line_set(DSMG600_PO_GPIO, IXP4XX_GPIO_HIGH); } +static void __init dsmg600_timer_init(void) +{ + /* The xtal on this machine is non-standard. */ + ixp4xx_timer_freq = DSMG600_FREQ; + + /* Call standard timer_init function. */ + ixp4xx_timer_init(); +} + +static struct sys_timer dsmg600_timer = { + .init = dsmg600_timer_init, +}; + static void __init dsmg600_init(void) { ixp4xx_sys_init(); @@ -155,21 +169,13 @@ static void __init dsmg600_init(void) #endif } -static void __init dsmg600_fixup(struct machine_desc *desc, - struct tag *tags, char **cmdline, struct meminfo *mi) -{ - /* The xtal on this machine is non-standard. */ - ixp4xx_timer_freq = DSMG600_FREQ; -} - MACHINE_START(DSMG600, "D-Link DSM-G600 RevA") /* Maintainer: www.nslu2-linux.org */ .phys_io = IXP4XX_PERIPHERAL_BASE_PHYS, .io_pg_offst = ((IXP4XX_PERIPHERAL_BASE_VIRT) >> 18) & 0xFFFC, .boot_params = 0x00000100, - .fixup = dsmg600_fixup, .map_io = ixp4xx_map_io, .init_irq = ixp4xx_init_irq, - .timer = &ixp4xx_timer, + .timer = &dsmg600_timer, .init_machine = dsmg600_init, MACHINE_END diff --git a/arch/arm/mach-ixp4xx/ixdpg425-pci.c b/arch/arm/mach-ixp4xx/ixdpg425-pci.c index 509a95a692a4..d1e75b7dc3b1 100644 --- a/arch/arm/mach-ixp4xx/ixdpg425-pci.c +++ b/arch/arm/mach-ixp4xx/ixdpg425-pci.c @@ -23,10 +23,6 @@ #include <asm/mach/pci.h> -extern void ixp4xx_pci_preinit(void); -extern int ixp4xx_setup(int nr, struct pci_sys_data *sys); -extern struct pci_bus *ixp4xx_scan_bus(int nr, struct pci_sys_data *sys); - void __init ixdpg425_pci_preinit(void) { set_irq_type(IRQ_IXP4XX_GPIO6, IRQT_LOW); diff --git a/arch/arm/mach-ixp4xx/nas100d-setup.c b/arch/arm/mach-ixp4xx/nas100d-setup.c index 9a31444d9214..78a17413ceca 100644 --- a/arch/arm/mach-ixp4xx/nas100d-setup.c +++ b/arch/arm/mach-ixp4xx/nas100d-setup.c @@ -155,7 +155,8 @@ static void __init nas100d_init(void) pm_power_off = nas100d_power_off; - /* This is only useful on a modified machine, but it is valuable + /* + * This is only useful on a modified machine, but it is valuable * to have it first in order to see debug messages, and so that * it does *not* get removed if platform_add_devices fails! */ diff --git a/arch/arm/mach-ixp4xx/nslu2-setup.c b/arch/arm/mach-ixp4xx/nslu2-setup.c index 162c266e5f8f..9bf8ccbcaccf 100644 --- a/arch/arm/mach-ixp4xx/nslu2-setup.c +++ b/arch/arm/mach-ixp4xx/nslu2-setup.c @@ -22,6 +22,7 @@ #include <asm/mach-types.h> #include <asm/mach/arch.h> #include <asm/mach/flash.h> +#include <asm/mach/time.h> static struct flash_platform_data nslu2_flash_data = { .map_name = "cfi_probe", @@ -49,26 +50,26 @@ static struct ixp4xx_i2c_pins nslu2_i2c_gpio_pins = { static struct resource nslu2_led_resources[] = { { .name = "ready", /* green led */ - .start = NSLU2_LED_GRN, - .end = NSLU2_LED_GRN, + .start = NSLU2_LED_GRN_GPIO, + .end = NSLU2_LED_GRN_GPIO, .flags = IXP4XX_GPIO_HIGH, }, { .name = "status", /* red led */ - .start = NSLU2_LED_RED, - .end = NSLU2_LED_RED, + .start = NSLU2_LED_RED_GPIO, + .end = NSLU2_LED_RED_GPIO, .flags = IXP4XX_GPIO_HIGH, }, { .name = "disk-1", - .start = NSLU2_LED_DISK1, - .end = NSLU2_LED_DISK1, + .start = NSLU2_LED_DISK1_GPIO, + .end = NSLU2_LED_DISK1_GPIO, .flags = IXP4XX_GPIO_LOW, }, { .name = "disk-2", - .start = NSLU2_LED_DISK2, - .end = NSLU2_LED_DISK2, + .start = NSLU2_LED_DISK2_GPIO, + .end = NSLU2_LED_DISK2_GPIO, .flags = IXP4XX_GPIO_LOW, }, }; @@ -157,10 +158,21 @@ static void nslu2_power_off(void) gpio_line_set(NSLU2_PO_GPIO, IXP4XX_GPIO_HIGH); } -static void __init nslu2_init(void) +static void __init nslu2_timer_init(void) { - ixp4xx_timer_freq = NSLU2_FREQ; + /* The xtal on this machine is non-standard. */ + ixp4xx_timer_freq = NSLU2_FREQ; + + /* Call standard timer_init function. */ + ixp4xx_timer_init(); +} +static struct sys_timer nslu2_timer = { + .init = nslu2_timer_init, +}; + +static void __init nslu2_init(void) +{ ixp4xx_sys_init(); nslu2_flash_resource.start = IXP4XX_EXP_BUS_BASE(0); @@ -169,7 +181,8 @@ static void __init nslu2_init(void) pm_power_off = nslu2_power_off; - /* This is only useful on a modified machine, but it is valuable + /* + * This is only useful on a modified machine, but it is valuable * to have it first in order to see debug messages, and so that * it does *not* get removed if platform_add_devices fails! */ @@ -185,6 +198,6 @@ MACHINE_START(NSLU2, "Linksys NSLU2") .boot_params = 0x00000100, .map_io = ixp4xx_map_io, .init_irq = ixp4xx_init_irq, - .timer = &ixp4xx_timer, + .timer = &nslu2_timer, .init_machine = nslu2_init, MACHINE_END diff --git a/arch/arm/mach-s3c2410/bast.h b/arch/arm/mach-s3c2410/bast.h deleted file mode 100644 index e98543742eb9..000000000000 --- a/arch/arm/mach-s3c2410/bast.h +++ /dev/null @@ -1,2 +0,0 @@ -/* linux/arch/arm/mach-s3c2410/bast.h -extern void bast_init_irq(void); diff --git a/arch/arm/mach-s3c2410/mach-amlm5900.c b/arch/arm/mach-s3c2410/mach-amlm5900.c index bc308ceb91c3..435adcce6482 100644 --- a/arch/arm/mach-s3c2410/mach-amlm5900.c +++ b/arch/arm/mach-s3c2410/mach-amlm5900.c @@ -160,7 +160,7 @@ static struct platform_device *amlm5900_devices[] __initdata = { #endif }; -void __init amlm5900_map_io(void) +static void __init amlm5900_map_io(void) { s3c24xx_init_io(amlm5900_iodesc, ARRAY_SIZE(amlm5900_iodesc)); s3c24xx_init_clocks(0); diff --git a/arch/arm/mach-s3c2412/s3c2412.c b/arch/arm/mach-s3c2412/s3c2412.c index c602aa39f9c4..782b5814ced2 100644 --- a/arch/arm/mach-s3c2412/s3c2412.c +++ b/arch/arm/mach-s3c2412/s3c2412.c @@ -16,6 +16,7 @@ #include <linux/list.h> #include <linux/timer.h> #include <linux/init.h> +#include <linux/delay.h> #include <linux/sysdev.h> #include <linux/serial_core.h> #include <linux/platform_device.h> @@ -29,6 +30,7 @@ #include <asm/io.h> #include <asm/irq.h> +#include <asm/arch/reset.h> #include <asm/arch/idle.h> #include <asm/arch/regs-clock.h> @@ -38,6 +40,7 @@ #include <asm/arch/regs-gpioj.h> #include <asm/arch/regs-dsc.h> #include <asm/arch/regs-spi.h> +#include <asm/arch/regs-s3c2412.h> #include <asm/plat-s3c24xx/s3c2412.h> #include <asm/plat-s3c24xx/cpu.h> @@ -106,6 +109,23 @@ static void s3c2412_idle(void) cpu_do_idle(); } +static void s3c2412_hard_reset(void) +{ + /* errata "Watch-dog/Software Reset Problem" specifies that + * this reset must be done with the SYSCLK sourced from + * EXTCLK instead of FOUT to avoid a glitch in the reset + * mechanism. + * + * See the watchdog section of the S3C2412 manual for more + * information on this fix. + */ + + __raw_writel(0x00, S3C2412_CLKSRC); + __raw_writel(S3C2412_SWRST_RESET, S3C2412_SWRST); + + mdelay(1); +} + /* s3c2412_map_io * * register the standard cpu IO areas, and any passed in from the @@ -122,6 +142,10 @@ void __init s3c2412_map_io(struct map_desc *mach_desc, int mach_size) s3c24xx_idle = s3c2412_idle; + /* set custom reset hook */ + + s3c24xx_reset_hook = s3c2412_hard_reset; + /* register our io-tables */ iotable_init(s3c2412_iodesc, ARRAY_SIZE(s3c2412_iodesc)); diff --git a/arch/arm/mach-s3c2443/clock.c b/arch/arm/mach-s3c2443/clock.c index 5955efb5de8d..58402948c47c 100644 --- a/arch/arm/mach-s3c2443/clock.c +++ b/arch/arm/mach-s3c2443/clock.c @@ -394,7 +394,7 @@ static int s3c2443_setrate_usbhost(struct clk *clk, unsigned long rate) return 0; } -struct clk clk_usb_bus_host = { +static struct clk clk_usb_bus_host = { .name = "usb-bus-host-parent", .id = -1, .parent = &clk_esysclk, @@ -758,7 +758,6 @@ static struct clk init_clocks[] = { .parent = &clk_h, .enable = s3c2443_clkcon_enable_h, .ctrlbit = S3C2443_HCLKCON_CFC, - .ctrlbit = S3C2443_HCLKCON_HSMMC, }, { .name = "ssmc", .id = -1, diff --git a/arch/arm/mach-sa1100/neponset.c b/arch/arm/mach-sa1100/neponset.c index d7c038a0256b..4cbf9468f654 100644 --- a/arch/arm/mach-sa1100/neponset.c +++ b/arch/arm/mach-sa1100/neponset.c @@ -139,12 +139,12 @@ static u_int neponset_get_mctrl(struct uart_port *port) return ret; } -static struct sa1100_port_fns neponset_port_fns __initdata = { +static struct sa1100_port_fns neponset_port_fns __devinitdata = { .set_mctrl = neponset_set_mctrl, .get_mctrl = neponset_get_mctrl, }; -static int neponset_probe(struct platform_device *dev) +static int __devinit neponset_probe(struct platform_device *dev) { sa1100_register_uart_fns(&neponset_port_fns); diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig index 5f472a8b406a..e7904bc92c73 100644 --- a/arch/arm/mm/Kconfig +++ b/arch/arm/mm/Kconfig @@ -379,7 +379,7 @@ config CPU_V7 select CPU_CP15_MMU select CPU_HAS_ASID select CPU_COPY_V6 if MMU - select CPU_TLB_V6 if MMU + select CPU_TLB_V7 if MMU # Figure out what processor architecture version we should be using. # This defines the compiler instruction set which depends on the machine type. @@ -498,6 +498,9 @@ config CPU_TLB_V4WBI config CPU_TLB_V6 bool +config CPU_TLB_V7 + bool + endif config CPU_HAS_ASID diff --git a/arch/arm/mm/Makefile b/arch/arm/mm/Makefile index b5bd335ff14a..762702765fc3 100644 --- a/arch/arm/mm/Makefile +++ b/arch/arm/mm/Makefile @@ -46,6 +46,7 @@ obj-$(CONFIG_CPU_TLB_V4WT) += tlb-v4.o obj-$(CONFIG_CPU_TLB_V4WB) += tlb-v4wb.o obj-$(CONFIG_CPU_TLB_V4WBI) += tlb-v4wbi.o obj-$(CONFIG_CPU_TLB_V6) += tlb-v6.o +obj-$(CONFIG_CPU_TLB_V7) += tlb-v7.o obj-$(CONFIG_CPU_ARM610) += proc-arm6_7.o obj-$(CONFIG_CPU_ARM710) += proc-arm6_7.o diff --git a/arch/arm/mm/proc-v7.S b/arch/arm/mm/proc-v7.S index dd823dd4a374..718f4782ee8b 100644 --- a/arch/arm/mm/proc-v7.S +++ b/arch/arm/mm/proc-v7.S @@ -256,7 +256,7 @@ __v7_proc_info: .long HWCAP_SWP|HWCAP_HALF|HWCAP_THUMB|HWCAP_FAST_MULT|HWCAP_EDSP .long cpu_v7_name .long v7_processor_functions - .long v6wbi_tlb_fns + .long v7wbi_tlb_fns .long v6_user_fns .long v7_cache_fns .size __v7_proc_info, . - __v7_proc_info diff --git a/arch/arm/mm/tlb-v7.S b/arch/arm/mm/tlb-v7.S new file mode 100644 index 000000000000..b56dda8052f7 --- /dev/null +++ b/arch/arm/mm/tlb-v7.S @@ -0,0 +1,88 @@ +/* + * linux/arch/arm/mm/tlb-v7.S + * + * Copyright (C) 1997-2002 Russell King + * Modified for ARMv7 by Catalin Marinas + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + * + * ARM architecture version 6 TLB handling functions. + * These assume a split I/D TLB. + */ +#include <linux/linkage.h> +#include <asm/asm-offsets.h> +#include <asm/page.h> +#include <asm/tlbflush.h> +#include "proc-macros.S" + +/* + * v7wbi_flush_user_tlb_range(start, end, vma) + * + * Invalidate a range of TLB entries in the specified address space. + * + * - start - start address (may not be aligned) + * - end - end address (exclusive, may not be aligned) + * - vma - vma_struct describing address range + * + * It is assumed that: + * - the "Invalidate single entry" instruction will invalidate + * both the I and the D TLBs on Harvard-style TLBs + */ +ENTRY(v7wbi_flush_user_tlb_range) + vma_vm_mm r3, r2 @ get vma->vm_mm + mmid r3, r3 @ get vm_mm->context.id + dsb + mov r0, r0, lsr #PAGE_SHIFT @ align address + mov r1, r1, lsr #PAGE_SHIFT + asid r3, r3 @ mask ASID + orr r0, r3, r0, lsl #PAGE_SHIFT @ Create initial MVA + mov r1, r1, lsl #PAGE_SHIFT + vma_vm_flags r2, r2 @ get vma->vm_flags +1: + mcr p15, 0, r0, c8, c6, 1 @ TLB invalidate D MVA (was 1) + tst r2, #VM_EXEC @ Executable area ? + mcrne p15, 0, r0, c8, c5, 1 @ TLB invalidate I MVA (was 1) + add r0, r0, #PAGE_SZ + cmp r0, r1 + blo 1b + mov ip, #0 + mcr p15, 0, ip, c7, c5, 6 @ flush BTAC/BTB + dsb + mov pc, lr + +/* + * v7wbi_flush_kern_tlb_range(start,end) + * + * Invalidate a range of kernel TLB entries + * + * - start - start address (may not be aligned) + * - end - end address (exclusive, may not be aligned) + */ +ENTRY(v7wbi_flush_kern_tlb_range) + dsb + mov r0, r0, lsr #PAGE_SHIFT @ align address + mov r1, r1, lsr #PAGE_SHIFT + mov r0, r0, lsl #PAGE_SHIFT + mov r1, r1, lsl #PAGE_SHIFT +1: + mcr p15, 0, r0, c8, c6, 1 @ TLB invalidate D MVA + mcr p15, 0, r0, c8, c5, 1 @ TLB invalidate I MVA + add r0, r0, #PAGE_SZ + cmp r0, r1 + blo 1b + mov r2, #0 + mcr p15, 0, r2, c7, c5, 6 @ flush BTAC/BTB + dsb + isb + mov pc, lr + + .section ".text.init", #alloc, #execinstr + + .type v7wbi_tlb_fns, #object +ENTRY(v7wbi_tlb_fns) + .long v7wbi_flush_user_tlb_range + .long v7wbi_flush_kern_tlb_range + .long v6wbi_tlb_flags + .size v7wbi_tlb_fns, . - v7wbi_tlb_fns diff --git a/arch/arm/nwfpe/softfloat.h b/arch/arm/nwfpe/softfloat.h index 0a3067452cd2..260fe29d73f5 100644 --- a/arch/arm/nwfpe/softfloat.h +++ b/arch/arm/nwfpe/softfloat.h @@ -273,4 +273,7 @@ static inline flag float64_lt_nocheck(float64 a, float64 b) extern flag float32_is_nan( float32 a ); extern flag float64_is_nan( float64 a ); +extern int32 float64_to_uint32( struct roundingData *roundData, float64 a ); +extern int32 float64_to_uint32_round_to_zero( float64 a ); + #endif diff --git a/arch/arm/oprofile/op_model_mpcore.c b/arch/arm/oprofile/op_model_mpcore.c index 898500718249..7791da791f5f 100644 --- a/arch/arm/oprofile/op_model_mpcore.c +++ b/arch/arm/oprofile/op_model_mpcore.c @@ -257,8 +257,13 @@ static void em_stop(void) */ static void em_route_irq(int irq, unsigned int cpu) { - irq_desc[irq].affinity = cpumask_of_cpu(cpu); - irq_desc[irq].chip->set_affinity(irq, cpumask_of_cpu(cpu)); + struct irq_desc *desc = irq_desc + irq; + cpumask_t mask = cpumask_of_cpu(cpu); + + spin_lock_irq(&desc->lock); + desc->affinity = mask; + desc->chip->set_affinity(irq, mask); + spin_unlock_irq(&desc->lock); } static int em_setup(void) |