aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@g5.osdl.org>2006-04-10 19:45:24 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2006-04-10 19:45:24 -0400
commit30d41bfbfb40bc6615e62eaa17fead79e3083c32 (patch)
treeb570a428b88e5cde113236c9cb208cdc1045ffb3 /arch
parente38d557896c4213dd0919770feac0f4a8f60151b (diff)
parent1356c1948da967bc1d4c663762bfe21dfcec4b2f (diff)
Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm: [ARM] 3473/1: Use numbers 0-15 for the VFP double registers [ARM] 3472/1: Use the D variants of FLDMIA/FSTMIA on ARMv6 [ARM] 3471/1: FTOSI functions should return 0 for NaN [ARM] 3470/1: Clear the HWCAP bits for the disabled kernel features [ARM] 3469/1: S3C24XX: clkout missing hclk selector [ARM] 3468/1: S3C2410: SMDK common include fix [ARM] 3461/1: ARM: OMAP: Fix clk_get() when using id and name [ARM] 3460/1: ARM: OMAP: Remove unnecessary nop_release() [ARM] 3459/1: ixp23xx: fix debug serial macros for big-endian operation [ARM] Allow decompressor to be built with -ffunction-sections [ARM] Fix SA110/SA1100 cache flushing [ARM] ebsa110: Fix incorrect serial port address [ARM] Fix ebsa110 debug macros [ARM] Move FLUSH_BASE macros to asm/arch/memory.h [ARM] Remove unnecessary extra parens in include/asm-arm/memory.h [ARM] arm's arch_local_page_offset() fix against 2.6.17-rc1
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/boot/compressed/vmlinux.lds.in1
-rw-r--r--arch/arm/kernel/setup.c6
-rw-r--r--arch/arm/mach-omap1/devices.c11
-rw-r--r--arch/arm/mach-omap2/devices.c10
-rw-r--r--arch/arm/mach-s3c2410/clock.c4
-rw-r--r--arch/arm/mach-s3c2410/common-smdk.c1
-rw-r--r--arch/arm/mm/cache-v4wb.S26
-rw-r--r--arch/arm/mm/init.c7
-rw-r--r--arch/arm/mm/proc-sa110.S25
-rw-r--r--arch/arm/mm/proc-sa1100.S37
-rw-r--r--arch/arm/plat-omap/clock.c3
-rw-r--r--arch/arm/plat-omap/devices.c22
-rw-r--r--arch/arm/vfp/vfpdouble.c29
-rw-r--r--arch/arm/vfp/vfphw.S6
-rw-r--r--arch/arm/vfp/vfpsingle.c9
15 files changed, 72 insertions, 125 deletions
diff --git a/arch/arm/boot/compressed/vmlinux.lds.in b/arch/arm/boot/compressed/vmlinux.lds.in
index eed616113e47..153a07e7222b 100644
--- a/arch/arm/boot/compressed/vmlinux.lds.in
+++ b/arch/arm/boot/compressed/vmlinux.lds.in
@@ -18,6 +18,7 @@ SECTIONS
18 _start = .; 18 _start = .;
19 *(.start) 19 *(.start)
20 *(.text) 20 *(.text)
21 *(.text.*)
21 *(.fixup) 22 *(.fixup)
22 *(.gnu.warning) 23 *(.gnu.warning)
23 *(.rodata) 24 *(.rodata)
diff --git a/arch/arm/kernel/setup.c b/arch/arm/kernel/setup.c
index 437528403959..8cff73e668b3 100644
--- a/arch/arm/kernel/setup.c
+++ b/arch/arm/kernel/setup.c
@@ -322,6 +322,12 @@ static void __init setup_processor(void)
322 sprintf(system_utsname.machine, "%s%c", list->arch_name, ENDIANNESS); 322 sprintf(system_utsname.machine, "%s%c", list->arch_name, ENDIANNESS);
323 sprintf(elf_platform, "%s%c", list->elf_name, ENDIANNESS); 323 sprintf(elf_platform, "%s%c", list->elf_name, ENDIANNESS);
324 elf_hwcap = list->elf_hwcap; 324 elf_hwcap = list->elf_hwcap;
325#ifndef CONFIG_ARM_THUMB
326 elf_hwcap &= ~HWCAP_THUMB;
327#endif
328#ifndef CONFIG_VFP
329 elf_hwcap &= ~HWCAP_VFP;
330#endif
325 331
326 cpu_proc_init(); 332 cpu_proc_init();
327} 333}
diff --git a/arch/arm/mach-omap1/devices.c b/arch/arm/mach-omap1/devices.c
index 876c38da14f7..847329cafc5c 100644
--- a/arch/arm/mach-omap1/devices.c
+++ b/arch/arm/mach-omap1/devices.c
@@ -25,10 +25,6 @@
25#include <asm/arch/mux.h> 25#include <asm/arch/mux.h>
26#include <asm/arch/gpio.h> 26#include <asm/arch/gpio.h>
27 27
28extern void omap_nop_release(struct device *dev);
29
30/*-------------------------------------------------------------------------*/
31
32#if defined(CONFIG_OMAP1610_IR) || defined(CONFIG_OMAP161O_IR_MODULE) 28#if defined(CONFIG_OMAP1610_IR) || defined(CONFIG_OMAP161O_IR_MODULE)
33 29
34static u64 irda_dmamask = 0xffffffff; 30static u64 irda_dmamask = 0xffffffff;
@@ -37,7 +33,6 @@ static struct platform_device omap1610ir_device = {
37 .name = "omap1610-ir", 33 .name = "omap1610-ir",
38 .id = -1, 34 .id = -1,
39 .dev = { 35 .dev = {
40 .release = omap_nop_release,
41 .dma_mask = &irda_dmamask, 36 .dma_mask = &irda_dmamask,
42 }, 37 },
43}; 38};
@@ -84,9 +79,6 @@ static struct resource rtc_resources[] = {
84static struct platform_device omap_rtc_device = { 79static struct platform_device omap_rtc_device = {
85 .name = "omap_rtc", 80 .name = "omap_rtc",
86 .id = -1, 81 .id = -1,
87 .dev = {
88 .release = omap_nop_release,
89 },
90 .num_resources = ARRAY_SIZE(rtc_resources), 82 .num_resources = ARRAY_SIZE(rtc_resources),
91 .resource = rtc_resources, 83 .resource = rtc_resources,
92}; 84};
@@ -124,9 +116,6 @@ static struct resource sti_resources[] = {
124static struct platform_device sti_device = { 116static struct platform_device sti_device = {
125 .name = "sti", 117 .name = "sti",
126 .id = -1, 118 .id = -1,
127 .dev = {
128 .release = omap_nop_release,
129 },
130 .num_resources = ARRAY_SIZE(sti_resources), 119 .num_resources = ARRAY_SIZE(sti_resources),
131 .resource = sti_resources, 120 .resource = sti_resources,
132}; 121};
diff --git a/arch/arm/mach-omap2/devices.c b/arch/arm/mach-omap2/devices.c
index def9e5370edf..fb7f91da1aad 100644
--- a/arch/arm/mach-omap2/devices.c
+++ b/arch/arm/mach-omap2/devices.c
@@ -25,10 +25,6 @@
25#include <asm/arch/mux.h> 25#include <asm/arch/mux.h>
26#include <asm/arch/gpio.h> 26#include <asm/arch/gpio.h>
27 27
28extern void omap_nop_release(struct device *dev);
29
30/*-------------------------------------------------------------------------*/
31
32#if defined(CONFIG_I2C_OMAP) || defined(CONFIG_I2C_OMAP_MODULE) 28#if defined(CONFIG_I2C_OMAP) || defined(CONFIG_I2C_OMAP_MODULE)
33 29
34#define OMAP2_I2C_BASE2 0x48072000 30#define OMAP2_I2C_BASE2 0x48072000
@@ -49,9 +45,6 @@ static struct resource i2c_resources2[] = {
49static struct platform_device omap_i2c_device2 = { 45static struct platform_device omap_i2c_device2 = {
50 .name = "i2c_omap", 46 .name = "i2c_omap",
51 .id = 2, 47 .id = 2,
52 .dev = {
53 .release = omap_nop_release,
54 },
55 .num_resources = ARRAY_SIZE(i2c_resources2), 48 .num_resources = ARRAY_SIZE(i2c_resources2),
56 .resource = i2c_resources2, 49 .resource = i2c_resources2,
57}; 50};
@@ -100,9 +93,6 @@ static struct resource sti_resources[] = {
100static struct platform_device sti_device = { 93static struct platform_device sti_device = {
101 .name = "sti", 94 .name = "sti",
102 .id = -1, 95 .id = -1,
103 .dev = {
104 .release = omap_nop_release,
105 },
106 .num_resources = ARRAY_SIZE(sti_resources), 96 .num_resources = ARRAY_SIZE(sti_resources),
107 .resource = sti_resources, 97 .resource = sti_resources,
108}; 98};
diff --git a/arch/arm/mach-s3c2410/clock.c b/arch/arm/mach-s3c2410/clock.c
index b7f85e6d6b76..6de713ad319a 100644
--- a/arch/arm/mach-s3c2410/clock.c
+++ b/arch/arm/mach-s3c2410/clock.c
@@ -367,6 +367,8 @@ static int s3c24xx_clkout_setparent(struct clk *clk, struct clk *parent)
367 source = S3C2410_MISCCR_CLK0_UPLL; 367 source = S3C2410_MISCCR_CLK0_UPLL;
368 else if (parent == &clk_f) 368 else if (parent == &clk_f)
369 source = S3C2410_MISCCR_CLK0_FCLK; 369 source = S3C2410_MISCCR_CLK0_FCLK;
370 else if (parent == &clk_h)
371 source = S3C2410_MISCCR_CLK0_HCLK;
370 else if (parent == &clk_p) 372 else if (parent == &clk_p)
371 source = S3C2410_MISCCR_CLK0_PCLK; 373 source = S3C2410_MISCCR_CLK0_PCLK;
372 else if (clk == &s3c24xx_clkout0 && parent == &s3c24xx_dclk0) 374 else if (clk == &s3c24xx_clkout0 && parent == &s3c24xx_dclk0)
@@ -376,6 +378,8 @@ static int s3c24xx_clkout_setparent(struct clk *clk, struct clk *parent)
376 else 378 else
377 return -EINVAL; 379 return -EINVAL;
378 380
381 clk->parent = parent;
382
379 if (clk == &s3c24xx_dclk0) 383 if (clk == &s3c24xx_dclk0)
380 mask = S3C2410_MISCCR_CLK0_MASK; 384 mask = S3C2410_MISCCR_CLK0_MASK;
381 else { 385 else {
diff --git a/arch/arm/mach-s3c2410/common-smdk.c b/arch/arm/mach-s3c2410/common-smdk.c
index 36b8291b5e03..f372fbda124e 100644
--- a/arch/arm/mach-s3c2410/common-smdk.c
+++ b/arch/arm/mach-s3c2410/common-smdk.c
@@ -37,6 +37,7 @@
37 37
38#include <asm/arch/nand.h> 38#include <asm/arch/nand.h>
39 39
40#include "common-smdk.h"
40#include "devs.h" 41#include "devs.h"
41#include "pm.h" 42#include "pm.h"
42 43
diff --git a/arch/arm/mm/cache-v4wb.S b/arch/arm/mm/cache-v4wb.S
index 5c4055b62d97..54e3c5bb5186 100644
--- a/arch/arm/mm/cache-v4wb.S
+++ b/arch/arm/mm/cache-v4wb.S
@@ -10,7 +10,7 @@
10#include <linux/config.h> 10#include <linux/config.h>
11#include <linux/linkage.h> 11#include <linux/linkage.h>
12#include <linux/init.h> 12#include <linux/init.h>
13#include <asm/hardware.h> 13#include <asm/memory.h>
14#include <asm/page.h> 14#include <asm/page.h>
15#include "proc-macros.S" 15#include "proc-macros.S"
16 16
@@ -46,6 +46,11 @@
46 */ 46 */
47#define CACHE_DLIMIT (CACHE_DSIZE * 4) 47#define CACHE_DLIMIT (CACHE_DSIZE * 4)
48 48
49 .data
50flush_base:
51 .long FLUSH_BASE
52 .text
53
49/* 54/*
50 * flush_user_cache_all() 55 * flush_user_cache_all()
51 * 56 *
@@ -63,11 +68,21 @@ ENTRY(v4wb_flush_kern_cache_all)
63 mov ip, #0 68 mov ip, #0
64 mcr p15, 0, ip, c7, c5, 0 @ invalidate I cache 69 mcr p15, 0, ip, c7, c5, 0 @ invalidate I cache
65__flush_whole_cache: 70__flush_whole_cache:
66 mov r0, #FLUSH_BASE 71 ldr r3, =flush_base
67 add r1, r0, #CACHE_DSIZE 72 ldr r1, [r3, #0]
681: ldr r2, [r0], #32 73 eor r1, r1, #CACHE_DSIZE
69 cmp r0, r1 74 str r1, [r3, #0]
75 add r2, r1, #CACHE_DSIZE
761: ldr r3, [r1], #32
77 cmp r1, r2
78 blo 1b
79#ifdef FLUSH_BASE_MINICACHE
80 add r2, r2, #FLUSH_BASE_MINICACHE - FLUSH_BASE
81 sub r1, r2, #512 @ only 512 bytes
821: ldr r3, [r1], #32
83 cmp r1, r2
70 blo 1b 84 blo 1b
85#endif
71 mcr p15, 0, ip, c7, c10, 4 @ drain write buffer 86 mcr p15, 0, ip, c7, c10, 4 @ drain write buffer
72 mov pc, lr 87 mov pc, lr
73 88
@@ -82,6 +97,7 @@ __flush_whole_cache:
82 * - flags - vma_area_struct flags describing address space 97 * - flags - vma_area_struct flags describing address space
83 */ 98 */
84ENTRY(v4wb_flush_user_cache_range) 99ENTRY(v4wb_flush_user_cache_range)
100 mov ip, #0
85 sub r3, r1, r0 @ calculate total size 101 sub r3, r1, r0 @ calculate total size
86 tst r2, #VM_EXEC @ executable region? 102 tst r2, #VM_EXEC @ executable region?
87 mcrne p15, 0, ip, c7, c5, 0 @ invalidate I cache 103 mcrne p15, 0, ip, c7, c5, 0 @ invalidate I cache
diff --git a/arch/arm/mm/init.c b/arch/arm/mm/init.c
index 88279124317a..9ea1f87a7079 100644
--- a/arch/arm/mm/init.c
+++ b/arch/arm/mm/init.c
@@ -20,6 +20,7 @@
20 20
21#include <asm/mach-types.h> 21#include <asm/mach-types.h>
22#include <asm/setup.h> 22#include <asm/setup.h>
23#include <asm/sizes.h>
23#include <asm/tlb.h> 24#include <asm/tlb.h>
24 25
25#include <asm/mach/arch.h> 26#include <asm/mach/arch.h>
@@ -455,14 +456,14 @@ static void __init devicemaps_init(struct machine_desc *mdesc)
455#ifdef FLUSH_BASE 456#ifdef FLUSH_BASE
456 map.pfn = __phys_to_pfn(FLUSH_BASE_PHYS); 457 map.pfn = __phys_to_pfn(FLUSH_BASE_PHYS);
457 map.virtual = FLUSH_BASE; 458 map.virtual = FLUSH_BASE;
458 map.length = PGDIR_SIZE; 459 map.length = SZ_1M;
459 map.type = MT_CACHECLEAN; 460 map.type = MT_CACHECLEAN;
460 create_mapping(&map); 461 create_mapping(&map);
461#endif 462#endif
462#ifdef FLUSH_BASE_MINICACHE 463#ifdef FLUSH_BASE_MINICACHE
463 map.pfn = __phys_to_pfn(FLUSH_BASE_PHYS + PGDIR_SIZE); 464 map.pfn = __phys_to_pfn(FLUSH_BASE_PHYS + SZ_1M);
464 map.virtual = FLUSH_BASE_MINICACHE; 465 map.virtual = FLUSH_BASE_MINICACHE;
465 map.length = PGDIR_SIZE; 466 map.length = SZ_1M;
466 map.type = MT_MINICLEAN; 467 map.type = MT_MINICLEAN;
467 create_mapping(&map); 468 create_mapping(&map);
468#endif 469#endif
diff --git a/arch/arm/mm/proc-sa110.S b/arch/arm/mm/proc-sa110.S
index c916a6cae404..a2dd5ae1077d 100644
--- a/arch/arm/mm/proc-sa110.S
+++ b/arch/arm/mm/proc-sa110.S
@@ -26,22 +26,7 @@
26 * the cache line size of the I and D cache 26 * the cache line size of the I and D cache
27 */ 27 */
28#define DCACHELINESIZE 32 28#define DCACHELINESIZE 32
29#define FLUSH_OFFSET 32768
30 29
31 .macro flush_110_dcache rd, ra, re
32 ldr \rd, =flush_base
33 ldr \ra, [\rd]
34 eor \ra, \ra, #FLUSH_OFFSET
35 str \ra, [\rd]
36 add \re, \ra, #16384 @ only necessary for 16k
371001: ldr \rd, [\ra], #DCACHELINESIZE
38 teq \re, \ra
39 bne 1001b
40 .endm
41
42 .data
43flush_base:
44 .long FLUSH_BASE
45 .text 30 .text
46 31
47/* 32/*
@@ -145,13 +130,11 @@ ENTRY(cpu_sa110_dcache_clean_area)
145 */ 130 */
146 .align 5 131 .align 5
147ENTRY(cpu_sa110_switch_mm) 132ENTRY(cpu_sa110_switch_mm)
148 flush_110_dcache r3, ip, r1 133 str lr, [sp, #-4]!
149 mov r1, #0 134 bl v4wb_flush_kern_cache_all @ clears IP
150 mcr p15, 0, r1, c7, c5, 0 @ invalidate I cache
151 mcr p15, 0, r1, c7, c10, 4 @ drain WB
152 mcr p15, 0, r0, c2, c0, 0 @ load page table pointer 135 mcr p15, 0, r0, c2, c0, 0 @ load page table pointer
153 mcr p15, 0, r1, c8, c7, 0 @ invalidate I & D TLBs 136 mcr p15, 0, ip, c8, c7, 0 @ invalidate I & D TLBs
154 mov pc, lr 137 ldr pc, [sp], #4
155 138
156/* 139/*
157 * cpu_sa110_set_pte(ptep, pte) 140 * cpu_sa110_set_pte(ptep, pte)
diff --git a/arch/arm/mm/proc-sa1100.S b/arch/arm/mm/proc-sa1100.S
index 41f21f2dd8ff..777ad99c1439 100644
--- a/arch/arm/mm/proc-sa1100.S
+++ b/arch/arm/mm/proc-sa1100.S
@@ -30,30 +30,6 @@
30 * the cache line size of the I and D cache 30 * the cache line size of the I and D cache
31 */ 31 */
32#define DCACHELINESIZE 32 32#define DCACHELINESIZE 32
33#define FLUSH_OFFSET 32768
34
35 .macro flush_1100_dcache rd, ra, re
36 ldr \rd, =flush_base
37 ldr \ra, [\rd]
38 eor \ra, \ra, #FLUSH_OFFSET
39 str \ra, [\rd]
40 add \re, \ra, #8192 @ only necessary for 8k
411001: ldr \rd, [\ra], #DCACHELINESIZE
42 teq \re, \ra
43 bne 1001b
44#ifdef FLUSH_BASE_MINICACHE
45 add \ra, \ra, #FLUSH_BASE_MINICACHE - FLUSH_BASE
46 add \re, \ra, #512 @ only 512 bytes
471002: ldr \rd, [\ra], #DCACHELINESIZE
48 teq \re, \ra
49 bne 1002b
50#endif
51 .endm
52
53 .data
54flush_base:
55 .long FLUSH_BASE
56 .text
57 33
58 __INIT 34 __INIT
59 35
@@ -79,9 +55,8 @@ ENTRY(cpu_sa1100_proc_fin)
79 stmfd sp!, {lr} 55 stmfd sp!, {lr}
80 mov ip, #PSR_F_BIT | PSR_I_BIT | SVC_MODE 56 mov ip, #PSR_F_BIT | PSR_I_BIT | SVC_MODE
81 msr cpsr_c, ip 57 msr cpsr_c, ip
82 flush_1100_dcache r0, r1, r2 @ clean caches 58 bl v4wb_flush_kern_cache_all
83 mov r0, #0 59 mcr p15, 0, ip, c15, c2, 2 @ Disable clock switching
84 mcr p15, 0, r0, c15, c2, 2 @ Disable clock switching
85 mrc p15, 0, r0, c1, c0, 0 @ ctrl register 60 mrc p15, 0, r0, c1, c0, 0 @ ctrl register
86 bic r0, r0, #0x1000 @ ...i............ 61 bic r0, r0, #0x1000 @ ...i............
87 bic r0, r0, #0x000e @ ............wca. 62 bic r0, r0, #0x000e @ ............wca.
@@ -167,14 +142,12 @@ ENTRY(cpu_sa1100_dcache_clean_area)
167 */ 142 */
168 .align 5 143 .align 5
169ENTRY(cpu_sa1100_switch_mm) 144ENTRY(cpu_sa1100_switch_mm)
170 flush_1100_dcache r3, ip, r1 145 str lr, [sp, #-4]!
171 mov ip, #0 146 bl v4wb_flush_kern_cache_all @ clears IP
172 mcr p15, 0, ip, c7, c5, 0 @ invalidate I cache
173 mcr p15, 0, ip, c9, c0, 0 @ invalidate RB 147 mcr p15, 0, ip, c9, c0, 0 @ invalidate RB
174 mcr p15, 0, ip, c7, c10, 4 @ drain WB
175 mcr p15, 0, r0, c2, c0, 0 @ load page table pointer 148 mcr p15, 0, r0, c2, c0, 0 @ load page table pointer
176 mcr p15, 0, ip, c8, c7, 0 @ invalidate I & D TLBs 149 mcr p15, 0, ip, c8, c7, 0 @ invalidate I & D TLBs
177 mov pc, lr 150 ldr pc, [sp], #4
178 151
179/* 152/*
180 * cpu_sa1100_set_pte(ptep, pte) 153 * cpu_sa1100_set_pte(ptep, pte)
diff --git a/arch/arm/plat-omap/clock.c b/arch/arm/plat-omap/clock.c
index 06485c193ee3..32ec04c58bcd 100644
--- a/arch/arm/plat-omap/clock.c
+++ b/arch/arm/plat-omap/clock.c
@@ -58,7 +58,7 @@ struct clk * clk_get(struct device *dev, const char *id)
58 if (p->id == idno && 58 if (p->id == idno &&
59 strcmp(id, p->name) == 0 && try_module_get(p->owner)) { 59 strcmp(id, p->name) == 0 && try_module_get(p->owner)) {
60 clk = p; 60 clk = p;
61 break; 61 goto found;
62 } 62 }
63 } 63 }
64 64
@@ -69,6 +69,7 @@ struct clk * clk_get(struct device *dev, const char *id)
69 } 69 }
70 } 70 }
71 71
72found:
72 mutex_unlock(&clocks_mutex); 73 mutex_unlock(&clocks_mutex);
73 74
74 return clk; 75 return clk;
diff --git a/arch/arm/plat-omap/devices.c b/arch/arm/plat-omap/devices.c
index 079b67deac0f..5d5d6eb222dd 100644
--- a/arch/arm/plat-omap/devices.c
+++ b/arch/arm/plat-omap/devices.c
@@ -26,14 +26,6 @@
26#include <asm/arch/gpio.h> 26#include <asm/arch/gpio.h>
27#include <asm/arch/menelaus.h> 27#include <asm/arch/menelaus.h>
28 28
29
30void omap_nop_release(struct device *dev)
31{
32 /* Nothing */
33}
34
35/*-------------------------------------------------------------------------*/
36
37#if defined(CONFIG_I2C_OMAP) || defined(CONFIG_I2C_OMAP_MODULE) 29#if defined(CONFIG_I2C_OMAP) || defined(CONFIG_I2C_OMAP_MODULE)
38 30
39#define OMAP1_I2C_BASE 0xfffb3800 31#define OMAP1_I2C_BASE 0xfffb3800
@@ -59,9 +51,6 @@ static struct resource i2c_resources1[] = {
59static struct platform_device omap_i2c_device1 = { 51static struct platform_device omap_i2c_device1 = {
60 .name = "i2c_omap", 52 .name = "i2c_omap",
61 .id = 1, 53 .id = 1,
62 .dev = {
63 .release = omap_nop_release,
64 },
65 .num_resources = ARRAY_SIZE(i2c_resources1), 54 .num_resources = ARRAY_SIZE(i2c_resources1),
66 .resource = i2c_resources1, 55 .resource = i2c_resources1,
67}; 56};
@@ -187,7 +176,6 @@ static struct platform_device mmc_omap_device1 = {
187 .name = "mmci-omap", 176 .name = "mmci-omap",
188 .id = 1, 177 .id = 1,
189 .dev = { 178 .dev = {
190 .release = omap_nop_release,
191 .dma_mask = &mmc1_dmamask, 179 .dma_mask = &mmc1_dmamask,
192 .platform_data = &mmc1_conf, 180 .platform_data = &mmc1_conf,
193 }, 181 },
@@ -217,7 +205,6 @@ static struct platform_device mmc_omap_device2 = {
217 .name = "mmci-omap", 205 .name = "mmci-omap",
218 .id = 2, 206 .id = 2,
219 .dev = { 207 .dev = {
220 .release = omap_nop_release,
221 .dma_mask = &mmc2_dmamask, 208 .dma_mask = &mmc2_dmamask,
222 .platform_data = &mmc2_conf, 209 .platform_data = &mmc2_conf,
223 }, 210 },
@@ -321,9 +308,6 @@ static struct resource uwire_resources[] = {
321static struct platform_device omap_uwire_device = { 308static struct platform_device omap_uwire_device = {
322 .name = "omap_uwire", 309 .name = "omap_uwire",
323 .id = -1, 310 .id = -1,
324 .dev = {
325 .release = omap_nop_release,
326 },
327 .num_resources = ARRAY_SIZE(uwire_resources), 311 .num_resources = ARRAY_SIZE(uwire_resources),
328 .resource = uwire_resources, 312 .resource = uwire_resources,
329}; 313};
@@ -365,9 +349,6 @@ static struct resource wdt_resources[] = {
365static struct platform_device omap_wdt_device = { 349static struct platform_device omap_wdt_device = {
366 .name = "omap_wdt", 350 .name = "omap_wdt",
367 .id = -1, 351 .id = -1,
368 .dev = {
369 .release = omap_nop_release,
370 },
371 .num_resources = ARRAY_SIZE(wdt_resources), 352 .num_resources = ARRAY_SIZE(wdt_resources),
372 .resource = wdt_resources, 353 .resource = wdt_resources,
373}; 354};
@@ -401,9 +382,6 @@ static struct resource rng_resources[] = {
401static struct platform_device omap_rng_device = { 382static struct platform_device omap_rng_device = {
402 .name = "omap_rng", 383 .name = "omap_rng",
403 .id = -1, 384 .id = -1,
404 .dev = {
405 .release = omap_nop_release,
406 },
407 .num_resources = ARRAY_SIZE(rng_resources), 385 .num_resources = ARRAY_SIZE(rng_resources),
408 .resource = rng_resources, 386 .resource = rng_resources,
409}; 387};
diff --git a/arch/arm/vfp/vfpdouble.c b/arch/arm/vfp/vfpdouble.c
index 9b367a65cb4d..febd115dba28 100644
--- a/arch/arm/vfp/vfpdouble.c
+++ b/arch/arm/vfp/vfpdouble.c
@@ -588,6 +588,7 @@ static u32 vfp_double_ftosi(int sd, int unused, int dm, u32 fpscr)
588 struct vfp_double vdm; 588 struct vfp_double vdm;
589 u32 d, exceptions = 0; 589 u32 d, exceptions = 0;
590 int rmode = fpscr & FPSCR_RMODE_MASK; 590 int rmode = fpscr & FPSCR_RMODE_MASK;
591 int tm;
591 592
592 vfp_double_unpack(&vdm, vfp_get_double(dm)); 593 vfp_double_unpack(&vdm, vfp_get_double(dm));
593 vfp_double_dump("VDM", &vdm); 594 vfp_double_dump("VDM", &vdm);
@@ -595,10 +596,14 @@ static u32 vfp_double_ftosi(int sd, int unused, int dm, u32 fpscr)
595 /* 596 /*
596 * Do we have denormalised number? 597 * Do we have denormalised number?
597 */ 598 */
598 if (vfp_double_type(&vdm) & VFP_DENORMAL) 599 tm = vfp_double_type(&vdm);
600 if (tm & VFP_DENORMAL)
599 exceptions |= FPSCR_IDC; 601 exceptions |= FPSCR_IDC;
600 602
601 if (vdm.exponent >= 1023 + 32) { 603 if (tm & VFP_NAN) {
604 d = 0;
605 exceptions |= FPSCR_IOC;
606 } else if (vdm.exponent >= 1023 + 32) {
602 d = 0x7fffffff; 607 d = 0x7fffffff;
603 if (vdm.sign) 608 if (vdm.sign)
604 d = ~d; 609 d = ~d;
@@ -1122,9 +1127,9 @@ u32 vfp_double_cpdo(u32 inst, u32 fpscr)
1122{ 1127{
1123 u32 op = inst & FOP_MASK; 1128 u32 op = inst & FOP_MASK;
1124 u32 exceptions = 0; 1129 u32 exceptions = 0;
1125 unsigned int dd = vfp_get_sd(inst); 1130 unsigned int dd = vfp_get_dd(inst);
1126 unsigned int dn = vfp_get_sn(inst); 1131 unsigned int dn = vfp_get_dn(inst);
1127 unsigned int dm = vfp_get_sm(inst); 1132 unsigned int dm = vfp_get_dm(inst);
1128 unsigned int vecitr, veclen, vecstride; 1133 unsigned int vecitr, veclen, vecstride;
1129 u32 (*fop)(int, int, s32, u32); 1134 u32 (*fop)(int, int, s32, u32);
1130 1135
@@ -1141,7 +1146,7 @@ u32 vfp_double_cpdo(u32 inst, u32 fpscr)
1141 pr_debug("VFP: vecstride=%u veclen=%u\n", vecstride, 1146 pr_debug("VFP: vecstride=%u veclen=%u\n", vecstride,
1142 (veclen >> FPSCR_LENGTH_BIT) + 1); 1147 (veclen >> FPSCR_LENGTH_BIT) + 1);
1143 1148
1144 fop = (op == FOP_EXT) ? fop_extfns[dn] : fop_fns[FOP_TO_IDX(op)]; 1149 fop = (op == FOP_EXT) ? fop_extfns[FEXT_TO_IDX(inst)] : fop_fns[FOP_TO_IDX(op)];
1145 if (!fop) 1150 if (!fop)
1146 goto invalid; 1151 goto invalid;
1147 1152
@@ -1149,17 +1154,13 @@ u32 vfp_double_cpdo(u32 inst, u32 fpscr)
1149 u32 except; 1154 u32 except;
1150 1155
1151 if (op == FOP_EXT) 1156 if (op == FOP_EXT)
1152 pr_debug("VFP: itr%d (d%u.%u) = op[%u] (d%u.%u)\n", 1157 pr_debug("VFP: itr%d (d%u) = op[%u] (d%u)\n",
1153 vecitr >> FPSCR_LENGTH_BIT, 1158 vecitr >> FPSCR_LENGTH_BIT,
1154 dd >> 1, dd & 1, dn, 1159 dd, dn, dm);
1155 dm >> 1, dm & 1);
1156 else 1160 else
1157 pr_debug("VFP: itr%d (d%u.%u) = (d%u.%u) op[%u] (d%u.%u)\n", 1161 pr_debug("VFP: itr%d (d%u) = (d%u) op[%u] (d%u)\n",
1158 vecitr >> FPSCR_LENGTH_BIT, 1162 vecitr >> FPSCR_LENGTH_BIT,
1159 dd >> 1, dd & 1, 1163 dd, dn, FOP_TO_IDX(op), dm);
1160 dn >> 1, dn & 1,
1161 FOP_TO_IDX(op),
1162 dm >> 1, dm & 1);
1163 1164
1164 except = fop(dd, dn, dm, fpscr); 1165 except = fop(dd, dn, dm, fpscr);
1165 pr_debug("VFP: itr%d: exceptions=%08x\n", 1166 pr_debug("VFP: itr%d: exceptions=%08x\n",
diff --git a/arch/arm/vfp/vfphw.S b/arch/arm/vfp/vfphw.S
index b7ed57e00cd4..a3f65b47aea9 100644
--- a/arch/arm/vfp/vfphw.S
+++ b/arch/arm/vfp/vfphw.S
@@ -189,11 +189,10 @@ vfp_put_float:
189 189
190 .globl vfp_get_double 190 .globl vfp_get_double
191vfp_get_double: 191vfp_get_double:
192 mov r0, r0, lsr #1
193 add pc, pc, r0, lsl #3 192 add pc, pc, r0, lsl #3
194 mov r0, r0 193 mov r0, r0
195 .irp dr,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15 194 .irp dr,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15
196 mrrc p10, 1, r0, r1, c\dr @ fmrrd r0, r1, d\dr 195 mrrc p11, 1, r0, r1, c\dr @ fmrrd r0, r1, d\dr
197 mov pc, lr 196 mov pc, lr
198 .endr 197 .endr
199 198
@@ -204,10 +203,9 @@ vfp_get_double:
204 203
205 .globl vfp_put_double 204 .globl vfp_put_double
206vfp_put_double: 205vfp_put_double:
207 mov r0, r0, lsr #1
208 add pc, pc, r0, lsl #3 206 add pc, pc, r0, lsl #3
209 mov r0, r0 207 mov r0, r0
210 .irp dr,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15 208 .irp dr,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15
211 mcrr p10, 1, r1, r2, c\dr @ fmrrd r1, r2, d\dr 209 mcrr p11, 1, r1, r2, c\dr @ fmdrr r1, r2, d\dr
212 mov pc, lr 210 mov pc, lr
213 .endr 211 .endr
diff --git a/arch/arm/vfp/vfpsingle.c b/arch/arm/vfp/vfpsingle.c
index 14dd696ddeb1..4ac27f193934 100644
--- a/arch/arm/vfp/vfpsingle.c
+++ b/arch/arm/vfp/vfpsingle.c
@@ -632,6 +632,7 @@ static u32 vfp_single_ftosi(int sd, int unused, s32 m, u32 fpscr)
632 struct vfp_single vsm; 632 struct vfp_single vsm;
633 u32 d, exceptions = 0; 633 u32 d, exceptions = 0;
634 int rmode = fpscr & FPSCR_RMODE_MASK; 634 int rmode = fpscr & FPSCR_RMODE_MASK;
635 int tm;
635 636
636 vfp_single_unpack(&vsm, m); 637 vfp_single_unpack(&vsm, m);
637 vfp_single_dump("VSM", &vsm); 638 vfp_single_dump("VSM", &vsm);
@@ -639,10 +640,14 @@ static u32 vfp_single_ftosi(int sd, int unused, s32 m, u32 fpscr)
639 /* 640 /*
640 * Do we have a denormalised number? 641 * Do we have a denormalised number?
641 */ 642 */
643 tm = vfp_single_type(&vsm);
642 if (vfp_single_type(&vsm) & VFP_DENORMAL) 644 if (vfp_single_type(&vsm) & VFP_DENORMAL)
643 exceptions |= FPSCR_IDC; 645 exceptions |= FPSCR_IDC;
644 646
645 if (vsm.exponent >= 127 + 32) { 647 if (tm & VFP_NAN) {
648 d = 0;
649 exceptions |= FPSCR_IOC;
650 } else if (vsm.exponent >= 127 + 32) {
646 /* 651 /*
647 * m >= 2^31-2^7: invalid 652 * m >= 2^31-2^7: invalid
648 */ 653 */
@@ -1188,7 +1193,7 @@ u32 vfp_single_cpdo(u32 inst, u32 fpscr)
1188 pr_debug("VFP: vecstride=%u veclen=%u\n", vecstride, 1193 pr_debug("VFP: vecstride=%u veclen=%u\n", vecstride,
1189 (veclen >> FPSCR_LENGTH_BIT) + 1); 1194 (veclen >> FPSCR_LENGTH_BIT) + 1);
1190 1195
1191 fop = (op == FOP_EXT) ? fop_extfns[sn] : fop_fns[FOP_TO_IDX(op)]; 1196 fop = (op == FOP_EXT) ? fop_extfns[FEXT_TO_IDX(inst)] : fop_fns[FOP_TO_IDX(op)];
1192 if (!fop) 1197 if (!fop)
1193 goto invalid; 1198 goto invalid;
1194 1199