aboutsummaryrefslogtreecommitdiffstats
path: root/arch/blackfin/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'arch/blackfin/kernel')
-rw-r--r--arch/blackfin/kernel/bfin_dma_5xx.c11
-rw-r--r--arch/blackfin/kernel/bfin_gpio.c19
-rw-r--r--arch/blackfin/kernel/bfin_ksyms.c2
-rw-r--r--arch/blackfin/kernel/gptimers.c2
-rw-r--r--arch/blackfin/kernel/init_task.c1
-rw-r--r--arch/blackfin/kernel/traps.c24
6 files changed, 44 insertions, 15 deletions
diff --git a/arch/blackfin/kernel/bfin_dma_5xx.c b/arch/blackfin/kernel/bfin_dma_5xx.c
index fd5448d6107c..d54f19085f37 100644
--- a/arch/blackfin/kernel/bfin_dma_5xx.c
+++ b/arch/blackfin/kernel/bfin_dma_5xx.c
@@ -90,6 +90,17 @@ int request_dma(unsigned int channel, char *device_id)
90{ 90{
91 91
92 pr_debug("request_dma() : BEGIN \n"); 92 pr_debug("request_dma() : BEGIN \n");
93
94#if defined(CONFIG_BF561) && ANOMALY_05000182
95 if (channel >= CH_IMEM_STREAM0_DEST && channel <= CH_IMEM_STREAM1_DEST) {
96 if (get_cclk() > 500000000) {
97 printk(KERN_WARNING
98 "Request IMDMA failed due to ANOMALY 05000182\n");
99 return -EFAULT;
100 }
101 }
102#endif
103
93 mutex_lock(&(dma_ch[channel].dmalock)); 104 mutex_lock(&(dma_ch[channel].dmalock));
94 105
95 if ((dma_ch[channel].chan_status == DMA_CHANNEL_REQUESTED) 106 if ((dma_ch[channel].chan_status == DMA_CHANNEL_REQUESTED)
diff --git a/arch/blackfin/kernel/bfin_gpio.c b/arch/blackfin/kernel/bfin_gpio.c
index 7e8eaf4a31bb..b6d89d1644cc 100644
--- a/arch/blackfin/kernel/bfin_gpio.c
+++ b/arch/blackfin/kernel/bfin_gpio.c
@@ -1130,6 +1130,25 @@ void bfin_gpio_irq_prepare(unsigned gpio)
1130 1130
1131#else 1131#else
1132 1132
1133int gpio_get_value(unsigned gpio)
1134{
1135 unsigned long flags;
1136 int ret;
1137
1138 if (unlikely(get_gpio_edge(gpio))) {
1139 local_irq_save(flags);
1140 set_gpio_edge(gpio, 0);
1141 ret = get_gpio_data(gpio);
1142 set_gpio_edge(gpio, 1);
1143 local_irq_restore(flags);
1144
1145 return ret;
1146 } else
1147 return get_gpio_data(gpio);
1148}
1149EXPORT_SYMBOL(gpio_get_value);
1150
1151
1133int gpio_direction_input(unsigned gpio) 1152int gpio_direction_input(unsigned gpio)
1134{ 1153{
1135 unsigned long flags; 1154 unsigned long flags;
diff --git a/arch/blackfin/kernel/bfin_ksyms.c b/arch/blackfin/kernel/bfin_ksyms.c
index 053edff6c0d8..4367330909b2 100644
--- a/arch/blackfin/kernel/bfin_ksyms.c
+++ b/arch/blackfin/kernel/bfin_ksyms.c
@@ -90,7 +90,9 @@ EXPORT_SYMBOL(__umodsi3);
90EXPORT_SYMBOL(outsb); 90EXPORT_SYMBOL(outsb);
91EXPORT_SYMBOL(insb); 91EXPORT_SYMBOL(insb);
92EXPORT_SYMBOL(outsw); 92EXPORT_SYMBOL(outsw);
93EXPORT_SYMBOL(outsw_8);
93EXPORT_SYMBOL(insw); 94EXPORT_SYMBOL(insw);
95EXPORT_SYMBOL(insw_8);
94EXPORT_SYMBOL(outsl); 96EXPORT_SYMBOL(outsl);
95EXPORT_SYMBOL(insl); 97EXPORT_SYMBOL(insl);
96EXPORT_SYMBOL(insl_16); 98EXPORT_SYMBOL(insl_16);
diff --git a/arch/blackfin/kernel/gptimers.c b/arch/blackfin/kernel/gptimers.c
index e698554895a7..3a3e9615b002 100644
--- a/arch/blackfin/kernel/gptimers.c
+++ b/arch/blackfin/kernel/gptimers.c
@@ -10,8 +10,8 @@
10 10
11#include <linux/kernel.h> 11#include <linux/kernel.h>
12#include <linux/module.h> 12#include <linux/module.h>
13#include <linux/io.h>
13 14
14#include <asm/io.h>
15#include <asm/blackfin.h> 15#include <asm/blackfin.h>
16#include <asm/gptimers.h> 16#include <asm/gptimers.h>
17 17
diff --git a/arch/blackfin/kernel/init_task.c b/arch/blackfin/kernel/init_task.c
index c640154030e2..6bdba7b21109 100644
--- a/arch/blackfin/kernel/init_task.c
+++ b/arch/blackfin/kernel/init_task.c
@@ -34,7 +34,6 @@
34#include <linux/fs.h> 34#include <linux/fs.h>
35 35
36static struct fs_struct init_fs = INIT_FS; 36static struct fs_struct init_fs = INIT_FS;
37static struct files_struct init_files = INIT_FILES;
38static struct signal_struct init_signals = INIT_SIGNALS(init_signals); 37static struct signal_struct init_signals = INIT_SIGNALS(init_signals);
39static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand); 38static struct sighand_struct init_sighand = INIT_SIGHAND(init_sighand);
40 39
diff --git a/arch/blackfin/kernel/traps.c b/arch/blackfin/kernel/traps.c
index 5b847070dae5..f061f5181623 100644
--- a/arch/blackfin/kernel/traps.c
+++ b/arch/blackfin/kernel/traps.c
@@ -67,7 +67,7 @@ void __init trap_init(void)
67 CSYNC(); 67 CSYNC();
68} 68}
69 69
70void *saved_icplb_fault_addr, *saved_dcplb_fault_addr; 70unsigned long saved_icplb_fault_addr, saved_dcplb_fault_addr;
71 71
72int kstack_depth_to_print = 48; 72int kstack_depth_to_print = 48;
73 73
@@ -364,13 +364,13 @@ asmlinkage void trap_c(struct pt_regs *fp)
364 /* 0x27 - Data CPLB Multiple Hits - Linux Trap Zero, handled here */ 364 /* 0x27 - Data CPLB Multiple Hits - Linux Trap Zero, handled here */
365 case VEC_CPLB_MHIT: 365 case VEC_CPLB_MHIT:
366 info.si_code = ILL_CPLB_MULHIT; 366 info.si_code = ILL_CPLB_MULHIT;
367#ifdef CONFIG_DEBUG_HUNT_FOR_ZERO
368 sig = SIGSEGV; 367 sig = SIGSEGV;
369 printk(KERN_NOTICE "NULL pointer access (probably)\n"); 368#ifdef CONFIG_DEBUG_HUNT_FOR_ZERO
370#else 369 if (saved_dcplb_fault_addr < FIXED_CODE_START)
371 sig = SIGILL; 370 printk(KERN_NOTICE "NULL pointer access\n");
372 printk(KERN_NOTICE EXC_0x27(KERN_NOTICE)); 371 else
373#endif 372#endif
373 printk(KERN_NOTICE EXC_0x27(KERN_NOTICE));
374 CHK_DEBUGGER_TRAP(); 374 CHK_DEBUGGER_TRAP();
375 break; 375 break;
376 /* 0x28 - Emulation Watchpoint, handled here */ 376 /* 0x28 - Emulation Watchpoint, handled here */
@@ -419,13 +419,13 @@ asmlinkage void trap_c(struct pt_regs *fp)
419 /* 0x2D - Instruction CPLB Multiple Hits, handled here */ 419 /* 0x2D - Instruction CPLB Multiple Hits, handled here */
420 case VEC_CPLB_I_MHIT: 420 case VEC_CPLB_I_MHIT:
421 info.si_code = ILL_CPLB_MULHIT; 421 info.si_code = ILL_CPLB_MULHIT;
422#ifdef CONFIG_DEBUG_HUNT_FOR_ZERO
423 sig = SIGSEGV; 422 sig = SIGSEGV;
424 printk(KERN_NOTICE "Jump to address 0 - 0x0fff\n"); 423#ifdef CONFIG_DEBUG_HUNT_FOR_ZERO
425#else 424 if (saved_icplb_fault_addr < FIXED_CODE_START)
426 sig = SIGILL; 425 printk(KERN_NOTICE "Jump to NULL address\n");
427 printk(KERN_NOTICE EXC_0x2D(KERN_NOTICE)); 426 else
428#endif 427#endif
428 printk(KERN_NOTICE EXC_0x2D(KERN_NOTICE));
429 CHK_DEBUGGER_TRAP(); 429 CHK_DEBUGGER_TRAP();
430 break; 430 break;
431 /* 0x2E - Illegal use of Supervisor Resource, handled here */ 431 /* 0x2E - Illegal use of Supervisor Resource, handled here */
@@ -939,8 +939,6 @@ void panic_cplb_error(int cplb_panic, struct pt_regs *fp)
939 939
940 oops_in_progress = 1; 940 oops_in_progress = 1;
941 941
942 printk(KERN_EMERG "DCPLB_FAULT_ADDR=%p\n", saved_dcplb_fault_addr);
943 printk(KERN_EMERG "ICPLB_FAULT_ADDR=%p\n", saved_icplb_fault_addr);
944 dump_bfin_process(fp); 942 dump_bfin_process(fp);
945 dump_bfin_mem(fp); 943 dump_bfin_mem(fp);
946 show_regs(fp); 944 show_regs(fp);