From 06ba255571b0a2f1fb7e49e7406364e4194f4e10 Mon Sep 17 00:00:00 2001 From: Russell King Date: Mon, 14 May 2007 22:56:32 +0100 Subject: [ARM] Remove Integrator/CP SMP platform support The Integrator/CP SMP platform support was never fully merged, and now it's causing build breakage. Remove it. Signed-off-by: Russell King --- include/asm-arm/arch-integrator/smp.h | 18 ------------------ 1 file changed, 18 deletions(-) delete mode 100644 include/asm-arm/arch-integrator/smp.h (limited to 'include/asm-arm') diff --git a/include/asm-arm/arch-integrator/smp.h b/include/asm-arm/arch-integrator/smp.h deleted file mode 100644 index ab2c79bb950..00000000000 --- a/include/asm-arm/arch-integrator/smp.h +++ /dev/null @@ -1,18 +0,0 @@ -#ifndef ASMARM_ARCH_SMP_H -#define ASMARM_ARCH_SMP_H - - -#include -#include - -#define hard_smp_processor_id() \ - ({ \ - unsigned int cpunum; \ - __asm__("mrc p15, 0, %0, c0, c0, 5" \ - : "=r" (cpunum)); \ - cpunum &= 0x0F; \ - }) - -extern void secondary_scan_irqs(void); - -#endif -- cgit v1.2.3-70-g09d2 From e903382ceae1dd85e650ffc7e98facdd59cc7a3f Mon Sep 17 00:00:00 2001 From: Sandeep Sanjay Patil Date: Wed, 16 May 2007 10:51:45 +0100 Subject: [ARM] 4384/1: S3C2412/13 SPI registers offset correction Change the SPI Channel 1 register offset in s3c_spi1_resource[], and s3c2412_dma_mappings[]. Offset has to be 0x100 in s3c2412/13's case. Also, total SPI memory resource size changed to 0x24 for s3c2412/13. Signed-off-by: Sandeep Patil Signed-off-by: Ben Dooks Signed-off-by: Russell King --- arch/arm/mach-s3c2412/dma.c | 4 ++-- arch/arm/mach-s3c2412/s3c2412.c | 9 +++++++++ arch/arm/plat-s3c24xx/devs.c | 5 +++-- include/asm-arm/arch-s3c2410/regs-spi.h | 2 ++ 4 files changed, 16 insertions(+), 4 deletions(-) (limited to 'include/asm-arm') diff --git a/arch/arm/mach-s3c2412/dma.c b/arch/arm/mach-s3c2412/dma.c index d0f4695c09d..668cccefe7b 100644 --- a/arch/arm/mach-s3c2412/dma.c +++ b/arch/arm/mach-s3c2412/dma.c @@ -59,8 +59,8 @@ static struct s3c24xx_dma_map __initdata s3c2412_dma_mappings[] = { [DMACH_SPI1] = { .name = "spi1", .channels = MAP(S3C2412_DMAREQSEL_SPI1TX), - .hw_addr.to = S3C2410_PA_SPI + 0x20 + S3C2410_SPTDAT, - .hw_addr.from = S3C2410_PA_SPI + 0x20 + S3C2410_SPRDAT, + .hw_addr.to = S3C2410_PA_SPI + S3C2412_SPI1 + S3C2410_SPTDAT, + .hw_addr.from = S3C2410_PA_SPI + S3C2412_SPI1 + S3C2410_SPRDAT, }, [DMACH_UART0] = { .name = "uart0", diff --git a/arch/arm/mach-s3c2412/s3c2412.c b/arch/arm/mach-s3c2412/s3c2412.c index aafe0bc593f..c602aa39f9c 100644 --- a/arch/arm/mach-s3c2412/s3c2412.c +++ b/arch/arm/mach-s3c2412/s3c2412.c @@ -37,6 +37,7 @@ #include #include #include +#include #include #include @@ -74,6 +75,14 @@ void __init s3c2412_init_uarts(struct s3c2410_uartcfg *cfg, int no) s3c_device_sdi.name = "s3c2412-sdi"; s3c_device_lcd.name = "s3c2412-lcd"; s3c_device_nand.name = "s3c2412-nand"; + + /* spi channel related changes, s3c2412/13 specific */ + s3c_device_spi0.name = "s3c2412-spi"; + s3c_device_spi0.resource[0].end = S3C24XX_PA_SPI + 0x24; + s3c_device_spi1.name = "s3c2412-spi"; + s3c_device_spi1.resource[0].start = S3C24XX_PA_SPI + S3C2412_SPI1; + s3c_device_spi1.resource[0].end = S3C24XX_PA_SPI + S3C2412_SPI1 + 0x24; + } /* s3c2412_idle diff --git a/arch/arm/plat-s3c24xx/devs.c b/arch/arm/plat-s3c24xx/devs.c index 0fe53b39cb2..8eca9599ef6 100644 --- a/arch/arm/plat-s3c24xx/devs.c +++ b/arch/arm/plat-s3c24xx/devs.c @@ -33,6 +33,7 @@ #include #include +#include /* Serial port registrations */ @@ -437,8 +438,8 @@ EXPORT_SYMBOL(s3c_device_spi0); static struct resource s3c_spi1_resource[] = { [0] = { - .start = S3C24XX_PA_SPI + 0x20, - .end = S3C24XX_PA_SPI + 0x20 + 0x1f, + .start = S3C24XX_PA_SPI + S3C2410_SPI1, + .end = S3C24XX_PA_SPI + S3C2410_SPI1 + 0x1f, .flags = IORESOURCE_MEM, }, [1] = { diff --git a/include/asm-arm/arch-s3c2410/regs-spi.h b/include/asm-arm/arch-s3c2410/regs-spi.h index 3552280d1e8..4a499a13825 100644 --- a/include/asm-arm/arch-s3c2410/regs-spi.h +++ b/include/asm-arm/arch-s3c2410/regs-spi.h @@ -12,6 +12,8 @@ #ifndef __ASM_ARCH_REGS_SPI_H #define __ASM_ARCH_REGS_SPI_H +#define S3C2410_SPI1 (0x20) +#define S3C2412_SPI1 (0x100) #define S3C2410_SPCON (0x00) -- cgit v1.2.3-70-g09d2 From c05107911a38235fec87892d83dc54aba9aaf3bd Mon Sep 17 00:00:00 2001 From: Russell King Date: Wed, 16 May 2007 12:41:15 +0100 Subject: [ARM] Update ARM syscalls Add utimensat, signalfd, timerfd, eventfd syscalls. Add ignore defines for sync_file_range and fadvise64_64 which we implement differently. Signed-off-by: Russell King --- arch/arm/kernel/calls.S | 4 ++++ include/asm-arm/unistd.h | 10 ++++++++++ 2 files changed, 14 insertions(+) (limited to 'include/asm-arm') diff --git a/arch/arm/kernel/calls.S b/arch/arm/kernel/calls.S index ae89cdd82b1..19326d7cdeb 100644 --- a/arch/arm/kernel/calls.S +++ b/arch/arm/kernel/calls.S @@ -357,6 +357,10 @@ /* 345 */ CALL(sys_getcpu) CALL(sys_ni_syscall) /* eventually epoll_pwait */ CALL(sys_kexec_load) + CALL(sys_utimensat) + CALL(sys_signalfd) +/* 350 */ CALL(sys_timerfd) + CALL(sys_eventfd) #ifndef syscalls_counted .equ syscalls_padding, ((NR_syscalls + 3) & ~3) - NR_syscalls #define syscalls_counted diff --git a/include/asm-arm/unistd.h b/include/asm-arm/unistd.h index c025ab47e4b..250d7f145ac 100644 --- a/include/asm-arm/unistd.h +++ b/include/asm-arm/unistd.h @@ -373,6 +373,10 @@ #define __NR_getcpu (__NR_SYSCALL_BASE+345) /* 346 for epoll_pwait */ #define __NR_kexec_load (__NR_SYSCALL_BASE+347) +#define __NR_utimensat (__NR_SYSCALL_BASE+348) +#define __NR_signalfd (__NR_SYSCALL_BASE+349) +#define __NR_timerfd (__NR_SYSCALL_BASE+350) +#define __NR_eventfd (__NR_SYSCALL_BASE+351) /* * The following SWIs are ARM private. @@ -433,5 +437,11 @@ */ #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") +/* + * Unimplemented (or alternatively implemented) syscalls + */ +#define __IGNORE_sync_file_range 1 +#define __IGNORE_fadvise64_64 1 + #endif /* __KERNEL__ */ #endif /* __ASM_ARM_UNISTD_H */ -- cgit v1.2.3-70-g09d2 From 516793c61b3db1f60e0b0d0e3c382bcca9ae84fd Mon Sep 17 00:00:00 2001 From: Russell King Date: Thu, 17 May 2007 10:19:23 +0100 Subject: [ARM] ARMv6: add CPU_HAS_ASID configuration Presently, we check for the minimum ARM architecture that we're building for to determine whether we need ASID support. This is wrong - if we're going to support a range of CPUs which include ARMv6 or higher, we need the ASID. Convert the checks to use a new configuration symbol, and arrange for ARMv6 and higher CPU entries to select it. Signed-off-by: Russell King --- arch/arm/kernel/asm-offsets.c | 2 +- arch/arm/mm/Kconfig | 8 ++++++++ include/asm-arm/mmu.h | 4 ++-- include/asm-arm/mmu_context.h | 2 +- 4 files changed, 12 insertions(+), 4 deletions(-) (limited to 'include/asm-arm') diff --git a/arch/arm/kernel/asm-offsets.c b/arch/arm/kernel/asm-offsets.c index 3c078e34675..3278e713c32 100644 --- a/arch/arm/kernel/asm-offsets.c +++ b/arch/arm/kernel/asm-offsets.c @@ -85,7 +85,7 @@ int main(void) DEFINE(S_OLD_R0, offsetof(struct pt_regs, ARM_ORIG_r0)); DEFINE(S_FRAME_SIZE, sizeof(struct pt_regs)); BLANK(); -#if __LINUX_ARM_ARCH__ >= 6 +#ifdef CONFIG_CPU_HAS_ASID DEFINE(MM_CONTEXT_ID, offsetof(struct mm_struct, context.id)); BLANK(); #endif diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig index 15f0284010c..5f472a8b406 100644 --- a/arch/arm/mm/Kconfig +++ b/arch/arm/mm/Kconfig @@ -351,6 +351,7 @@ config CPU_V6 select CPU_CACHE_V6 select CPU_CACHE_VIPT select CPU_CP15_MMU + select CPU_HAS_ASID select CPU_COPY_V6 if MMU select CPU_TLB_V6 if MMU @@ -376,6 +377,7 @@ config CPU_V7 select CPU_CACHE_V7 select CPU_CACHE_VIPT select CPU_CP15_MMU + select CPU_HAS_ASID select CPU_COPY_V6 if MMU select CPU_TLB_V6 if MMU @@ -498,6 +500,12 @@ config CPU_TLB_V6 endif +config CPU_HAS_ASID + bool + help + This indicates whether the CPU has the ASID register; used to + tag TLB and possibly cache entries. + config CPU_CP15 bool help diff --git a/include/asm-arm/mmu.h b/include/asm-arm/mmu.h index fe2a23b5627..53099d4ee42 100644 --- a/include/asm-arm/mmu.h +++ b/include/asm-arm/mmu.h @@ -4,13 +4,13 @@ #ifdef CONFIG_MMU typedef struct { -#if __LINUX_ARM_ARCH__ >= 6 +#ifdef CONFIG_CPU_HAS_ASID unsigned int id; #endif unsigned int kvm_seq; } mm_context_t; -#if __LINUX_ARM_ARCH__ >= 6 +#ifdef CONFIG_CPU_HAS_ASID #define ASID(mm) ((mm)->context.id & 255) #else #define ASID(mm) (0) diff --git a/include/asm-arm/mmu_context.h b/include/asm-arm/mmu_context.h index 4981ad41919..6913d02ca5d 100644 --- a/include/asm-arm/mmu_context.h +++ b/include/asm-arm/mmu_context.h @@ -20,7 +20,7 @@ void __check_kvm_seq(struct mm_struct *mm); -#if __LINUX_ARM_ARCH__ >= 6 +#ifdef CONFIG_CPU_HAS_ASID /* * On ARMv6, we have the following structure in the Context ID: -- cgit v1.2.3-70-g09d2 From 95ba71f76f1cce550cb2e2b345a204d4a926d29c Mon Sep 17 00:00:00 2001 From: Greg Ungerer Date: Thu, 17 May 2007 06:22:41 +0100 Subject: [ARM] 4388/1: no need for arm/mm mmap range checks for non-mmu We don't need valid_phys_addr_range() or valid_mmap_phys_addr_range() for the !CONFIG_MMU case. Signed-off-by: Greg Ungerer Signed-off-by: Russell King --- include/asm-arm/io.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/asm-arm') diff --git a/include/asm-arm/io.h b/include/asm-arm/io.h index 8261ff9e795..1d3caa42a38 100644 --- a/include/asm-arm/io.h +++ b/include/asm-arm/io.h @@ -259,9 +259,11 @@ extern void pci_iounmap(struct pci_dev *dev, void __iomem *addr); #define BIOVEC_MERGEABLE(vec1, vec2) \ ((bvec_to_phys((vec1)) + (vec1)->bv_len) == bvec_to_phys((vec2))) +#ifdef CONFIG_MMU #define ARCH_HAS_VALID_PHYS_ADDR_RANGE extern int valid_phys_addr_range(unsigned long addr, size_t size); extern int valid_mmap_phys_addr_range(unsigned long pfn, size_t size); +#endif /* * Convert a physical pointer to a virtual kernel pointer for /dev/mem -- cgit v1.2.3-70-g09d2 From 5f2ef21703564d3e6f18fd92f2e72f723a5c3402 Mon Sep 17 00:00:00 2001 From: Ben Dooks Date: Sun, 20 May 2007 17:32:39 +0100 Subject: [ARM] 4397/1: S3C2443: remove SDI0/1 IRQ ambiguity Change the name of the S3C2443_SDI1 to S3C2443_HSMMC to ensure that it is correctly identified. Signed-off-by: Ben Dooks Signed-off-by: Russell King --- include/asm-arm/arch-s3c2410/irqs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/asm-arm') diff --git a/include/asm-arm/arch-s3c2410/irqs.h b/include/asm-arm/arch-s3c2410/irqs.h index c79cb181991..3b49cd1c345 100644 --- a/include/asm-arm/arch-s3c2410/irqs.h +++ b/include/asm-arm/arch-s3c2410/irqs.h @@ -124,7 +124,7 @@ #define IRQ_S3C2443_DMA S3C2410_IRQ(17) /* IRQ_DMA1 */ #define IRQ_S3C2443_UART3 S3C2410_IRQ(18) /* IRQ_DMA2 */ #define IRQ_S3C2443_CFCON S3C2410_IRQ(19) /* IRQ_DMA3 */ -#define IRQ_S3C2443_SDI1 S3C2410_IRQ(20) /* IRQ_SDI */ +#define IRQ_S3C2443_HSMMC S3C2410_IRQ(20) /* IRQ_SDI */ #define IRQ_S3C2443_NAND S3C2410_IRQ(24) /* reserved */ #define IRQ_S3C2443_LCD1 S3C2410_IRQSUB(14) -- cgit v1.2.3-70-g09d2 From 69e9c93d0d7d9dfa6bdf5144274dbe65a627b63a Mon Sep 17 00:00:00 2001 From: Ben Dooks Date: Sun, 20 May 2007 18:13:32 +0100 Subject: [ARM] 4400/1: S3C24XX: Add high-speed MMC device definition Add definition for high-speed MMC/SD device and add to SMDK2443 device list. Signed-off-by: Ben Dooks Signed-off-by: Russell King --- arch/arm/mach-s3c2443/mach-smdk2443.c | 1 + arch/arm/plat-s3c24xx/devs.c | 30 ++++++++++++++++++++++++++++++ include/asm-arm/plat-s3c24xx/devs.h | 1 + 3 files changed, 32 insertions(+) (limited to 'include/asm-arm') diff --git a/arch/arm/mach-s3c2443/mach-smdk2443.c b/arch/arm/mach-s3c2443/mach-smdk2443.c index b71ee53c286..b1eb709ee65 100644 --- a/arch/arm/mach-s3c2443/mach-smdk2443.c +++ b/arch/arm/mach-s3c2443/mach-smdk2443.c @@ -104,6 +104,7 @@ static struct s3c2410_uartcfg smdk2443_uartcfgs[] __initdata = { static struct platform_device *smdk2443_devices[] __initdata = { &s3c_device_wdt, &s3c_device_i2c, + &s3c_device_hsmmc, }; static void __init smdk2443_map_io(void) diff --git a/arch/arm/plat-s3c24xx/devs.c b/arch/arm/plat-s3c24xx/devs.c index 8eca9599ef6..5875da0ae0e 100644 --- a/arch/arm/plat-s3c24xx/devs.c +++ b/arch/arm/plat-s3c24xx/devs.c @@ -403,6 +403,36 @@ struct platform_device s3c_device_sdi = { EXPORT_SYMBOL(s3c_device_sdi); +/* High-speed MMC/SD */ + +static struct resource s3c_hsmmc_resource[] = { + [0] = { + .start = S3C2443_PA_HSMMC, + .end = S3C2443_PA_HSMMC + S3C2443_SZ_HSMMC - 1, + .flags = IORESOURCE_MEM, + }, + [1] = { + .start = IRQ_S3C2443_HSMMC, + .end = IRQ_S3C2443_HSMMC, + .flags = IORESOURCE_IRQ, + } +}; + +static u64 s3c_device_hsmmc_dmamask = 0xffffffffUL; + +struct platform_device s3c_device_hsmmc = { + .name = "s3c-sdhci", + .id = -1, + .num_resources = ARRAY_SIZE(s3c_hsmmc_resource), + .resource = s3c_hsmmc_resource, + .dev = { + .dma_mask = &s3c_device_hsmmc_dmamask, + .coherent_dma_mask = 0xffffffffUL + } +}; + + + /* SPI (0) */ static struct resource s3c_spi0_resource[] = { diff --git a/include/asm-arm/plat-s3c24xx/devs.h b/include/asm-arm/plat-s3c24xx/devs.h index dddf485fc06..f9d6f0317bc 100644 --- a/include/asm-arm/plat-s3c24xx/devs.h +++ b/include/asm-arm/plat-s3c24xx/devs.h @@ -29,6 +29,7 @@ extern struct platform_device s3c_device_iis; extern struct platform_device s3c_device_rtc; extern struct platform_device s3c_device_adc; extern struct platform_device s3c_device_sdi; +extern struct platform_device s3c_device_hsmmc; extern struct platform_device s3c_device_spi0; extern struct platform_device s3c_device_spi1; -- cgit v1.2.3-70-g09d2 From fc432e1952a3899ce35e84b417e5d60f74cb901b Mon Sep 17 00:00:00 2001 From: Mariusz Kozlowski Date: Sat, 19 May 2007 00:39:36 +0200 Subject: [ARM] at91_adc parenthesis balance Trivial unbalanced parenthesis macro fix. Signed-off-by: Mariusz Kozlowski Signed-off-by: Russell King --- include/asm-arm/arch-at91/at91_adc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/asm-arm') diff --git a/include/asm-arm/arch-at91/at91_adc.h b/include/asm-arm/arch-at91/at91_adc.h index 1ed66eaaf83..6d71ea2637b 100644 --- a/include/asm-arm/arch-at91/at91_adc.h +++ b/include/asm-arm/arch-at91/at91_adc.h @@ -55,7 +55,7 @@ #define AT91_ADC_IDR 0x28 /* Interrupt Disable Register */ #define AT91_ADC_IMR 0x2C /* Interrupt Mask Register */ -#define AT91_ADC_CHR(n) (0x30 + ((n) * 4) /* Channel Data Register N */ +#define AT91_ADC_CHR(n) (0x30 + ((n) * 4)) /* Channel Data Register N */ #define AT91_ADC_DATA (0x3ff) #endif -- cgit v1.2.3-70-g09d2