Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/vapier/blackfin

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/vapier/blackfin: (21 commits)
Blackfin: define HARDIRQ_BITS again for now
arch/blackfin: Add kmalloc NULL tests
Blackfin: add CPLB entries for Core B on-chip L1 SRAM regions
Blackfin: work around anomaly 05000189
Blackfin: drop per-cpu loops_per_jiffy tracking
Blackfin: fix bugs in GPIO resume code
Blackfin: bf537-stamp: fix irq decl for AD7142
Blackfin: fix handling of IPEND in interrupt context save
Blackfin: drop duplicate runtime checking of anomaly 05000448
Blackfin: fix incomplete renaming of the bfin-twi-lcd driver
Blackfin: fix wrong CTS inversion
Blackfin: update handling of anomaly 364 (wrong rev id in BF527-0.1)
Blackfin: fix early_dma_memcpy() handling of busy channels
Blackfin: handle BF561 Core B memory regions better when SMP=n
Blackfin: fix miscompilation in lshrdi3
Blackfin: fix silent crash when no uClinux MTD filesystem exists
Blackfin: restore exception banner when dumping crash info
Blackfin: work around anomaly 05000281
Blackfin: update anomaly lists to match latest sheets/usage
Blackfin: drop dead flash_probe call
...

+143 -113
+4 -3
arch/blackfin/include/asm/context.S
··· 223 [--sp] = RETN; 224 [--sp] = RETE; 225 [--sp] = SEQSTAT; 226 - #ifdef CONFIG_KGDB 227 - r1.l = lo(IPEND); 228 - r1.h = hi(IPEND); 229 [--sp] = r1; 230 #else 231 [--sp] = r0; /* Skip IPEND as well. */
··· 223 [--sp] = RETN; 224 [--sp] = RETE; 225 [--sp] = SEQSTAT; 226 + #ifdef CONFIG_DEBUG_KERNEL 227 + p1.l = lo(IPEND); 228 + p1.h = hi(IPEND); 229 + r1 = [p1]; 230 [--sp] = r1; 231 #else 232 [--sp] = r0; /* Skip IPEND as well. */
-1
arch/blackfin/include/asm/cpu.h
··· 32 struct task_struct *idle; 33 unsigned int imemctl; 34 unsigned int dmemctl; 35 - unsigned long loops_per_jiffy; 36 unsigned long dcache_invld_count; 37 unsigned long icache_invld_count; 38 };
··· 32 struct task_struct *idle; 33 unsigned int imemctl; 34 unsigned int dmemctl; 35 unsigned long dcache_invld_count; 36 unsigned long icache_invld_count; 37 };
+3
arch/blackfin/include/asm/hardirq.h
··· 6 extern void ack_bad_irq(unsigned int irq); 7 #define ack_bad_irq ack_bad_irq 8 9 #include <asm-generic/hardirq.h> 10 11 #endif
··· 6 extern void ack_bad_irq(unsigned int irq); 7 #define ack_bad_irq ack_bad_irq 8 9 + /* Define until common code gets sane defaults */ 10 + #define HARDIRQ_BITS 9 11 + 12 #include <asm-generic/hardirq.h> 13 14 #endif
+7 -14
arch/blackfin/include/asm/processor.h
··· 105 /* Always use CHIPID, to work around ANOMALY_05000234 */ 106 uint32_t revid = (bfin_read_CHIPID() & CHIPID_VERSION) >> 28; 107 108 - #ifdef CONFIG_BF52x 109 - /* ANOMALY_05000357 110 * Incorrect Revision Number in DSPID Register 111 */ 112 - if (revid == 0) 113 - switch (bfin_read16(_BOOTROM_GET_DXE_ADDRESS_TWI)) { 114 - case 0x0010: 115 - revid = 0; 116 - break; 117 - case 0x2796: 118 - revid = 1; 119 - break; 120 - default: 121 - revid = 0xFFFF; 122 - break; 123 - } 124 #endif 125 return revid; 126 } 127
··· 105 /* Always use CHIPID, to work around ANOMALY_05000234 */ 106 uint32_t revid = (bfin_read_CHIPID() & CHIPID_VERSION) >> 28; 107 108 + #ifdef _BOOTROM_GET_DXE_ADDRESS_TWI 109 + /* 110 + * ANOMALY_05000364 111 * Incorrect Revision Number in DSPID Register 112 */ 113 + if (ANOMALY_05000364 && 114 + bfin_read16(_BOOTROM_GET_DXE_ADDRESS_TWI) == 0x2796) 115 + revid = 1; 116 #endif 117 + 118 return revid; 119 } 120
+19 -20
arch/blackfin/kernel/bfin_dma_5xx.c
··· 253 BUG_ON(src % 4); 254 BUG_ON(size % 4); 255 256 /* Force a sync in case a previous config reset on this channel 257 * occurred. This is needed so subsequent writes to DMA registers 258 * are not spuriously lost/corrupted. 259 */ 260 __builtin_bfin_ssync(); 261 - 262 - src_ch = 0; 263 - /* Find an avalible memDMA channel */ 264 - while (1) { 265 - if (!src_ch || src_ch == (struct dma_register *)MDMA_S1_NEXT_DESC_PTR) { 266 - dst_ch = (struct dma_register *)MDMA_D0_NEXT_DESC_PTR; 267 - src_ch = (struct dma_register *)MDMA_S0_NEXT_DESC_PTR; 268 - } else { 269 - dst_ch = (struct dma_register *)MDMA_D1_NEXT_DESC_PTR; 270 - src_ch = (struct dma_register *)MDMA_S1_NEXT_DESC_PTR; 271 - } 272 - 273 - if (!bfin_read16(&src_ch->cfg)) { 274 - break; 275 - } else { 276 - if (bfin_read16(&src_ch->irq_status) & DMA_DONE) 277 - bfin_write16(&src_ch->cfg, 0); 278 - } 279 - 280 - } 281 282 /* Destination */ 283 bfin_write32(&dst_ch->start_addr, dst);
··· 253 BUG_ON(src % 4); 254 BUG_ON(size % 4); 255 256 + src_ch = 0; 257 + /* Find an avalible memDMA channel */ 258 + while (1) { 259 + if (src_ch == (struct dma_register *)MDMA_S0_NEXT_DESC_PTR) { 260 + dst_ch = (struct dma_register *)MDMA_D1_NEXT_DESC_PTR; 261 + src_ch = (struct dma_register *)MDMA_S1_NEXT_DESC_PTR; 262 + } else { 263 + dst_ch = (struct dma_register *)MDMA_D0_NEXT_DESC_PTR; 264 + src_ch = (struct dma_register *)MDMA_S0_NEXT_DESC_PTR; 265 + } 266 + 267 + if (!bfin_read16(&src_ch->cfg)) 268 + break; 269 + else if (bfin_read16(&dst_ch->irq_status) & DMA_DONE) { 270 + bfin_write16(&src_ch->cfg, 0); 271 + break; 272 + } 273 + } 274 + 275 /* Force a sync in case a previous config reset on this channel 276 * occurred. This is needed so subsequent writes to DMA registers 277 * are not spuriously lost/corrupted. 278 */ 279 __builtin_bfin_ssync(); 280 281 /* Destination */ 282 bfin_write32(&dst_ch->start_addr, dst);
+2 -4
arch/blackfin/kernel/bfin_gpio.c
··· 686 *port_fer[bank] = gpio_bank_saved[bank].fer; 687 #endif 688 gpio_array[bank]->inen = gpio_bank_saved[bank].inen; 689 gpio_array[bank]->dir = gpio_bank_saved[bank].dir; 690 gpio_array[bank]->polar = gpio_bank_saved[bank].polar; 691 gpio_array[bank]->edge = gpio_bank_saved[bank].edge; 692 gpio_array[bank]->both = gpio_bank_saved[bank].both; 693 - 694 - gpio_array[bank]->data_set = gpio_bank_saved[bank].data 695 - | gpio_bank_saved[bank].dir; 696 - 697 gpio_array[bank]->maska = gpio_bank_saved[bank].maska; 698 } 699 AWA_DUMMY_READ(maska);
··· 686 *port_fer[bank] = gpio_bank_saved[bank].fer; 687 #endif 688 gpio_array[bank]->inen = gpio_bank_saved[bank].inen; 689 + gpio_array[bank]->data_set = gpio_bank_saved[bank].data 690 + & gpio_bank_saved[bank].dir; 691 gpio_array[bank]->dir = gpio_bank_saved[bank].dir; 692 gpio_array[bank]->polar = gpio_bank_saved[bank].polar; 693 gpio_array[bank]->edge = gpio_bank_saved[bank].edge; 694 gpio_array[bank]->both = gpio_bank_saved[bank].both; 695 gpio_array[bank]->maska = gpio_bank_saved[bank].maska; 696 } 697 AWA_DUMMY_READ(maska);
+17 -6
arch/blackfin/kernel/cplb-nompu/cplbinit.c
··· 72 } 73 74 /* Cover L1 memory. One 4M area for code and data each is enough. */ 75 - if (L1_DATA_A_LENGTH || L1_DATA_B_LENGTH) { 76 - d_tbl[i_d].addr = L1_DATA_A_START; 77 - d_tbl[i_d++].data = L1_DMEMORY | PAGE_SIZE_4MB; 78 } 79 - i_tbl[i_i].addr = L1_CODE_START; 80 - i_tbl[i_i++].data = L1_IMEMORY | PAGE_SIZE_4MB; 81 - 82 first_switched_dcplb = i_d; 83 first_switched_icplb = i_i; 84
··· 72 } 73 74 /* Cover L1 memory. One 4M area for code and data each is enough. */ 75 + if (cpu == 0) { 76 + if (L1_DATA_A_LENGTH || L1_DATA_B_LENGTH) { 77 + d_tbl[i_d].addr = L1_DATA_A_START; 78 + d_tbl[i_d++].data = L1_DMEMORY | PAGE_SIZE_4MB; 79 + } 80 + i_tbl[i_i].addr = L1_CODE_START; 81 + i_tbl[i_i++].data = L1_IMEMORY | PAGE_SIZE_4MB; 82 } 83 + #ifdef CONFIG_SMP 84 + else { 85 + if (L1_DATA_A_LENGTH || L1_DATA_B_LENGTH) { 86 + d_tbl[i_d].addr = COREB_L1_DATA_A_START; 87 + d_tbl[i_d++].data = L1_DMEMORY | PAGE_SIZE_4MB; 88 + } 89 + i_tbl[i_i].addr = COREB_L1_CODE_START; 90 + i_tbl[i_i++].data = L1_IMEMORY | PAGE_SIZE_4MB; 91 + } 92 + #endif 93 first_switched_dcplb = i_d; 94 first_switched_icplb = i_i; 95
+7 -7
arch/blackfin/kernel/process.c
··· 361 int in_mem_const(unsigned long addr, unsigned long size, 362 unsigned long const_addr, unsigned long const_size) 363 { 364 - return in_mem_const_off(addr, 0, size, const_addr, const_size); 365 } 366 #define IN_ASYNC(bnum, bctlnum) \ 367 ({ \ ··· 390 if (in_mem_const(addr, size, L1_DATA_B_START, L1_DATA_B_LENGTH)) 391 return cpu == 0 ? BFIN_MEM_ACCESS_CORE : BFIN_MEM_ACCESS_IDMA; 392 #ifdef COREB_L1_CODE_START 393 - if (in_mem_const(addr, size, COREB_L1_CODE_START, L1_CODE_LENGTH)) 394 return cpu == 1 ? BFIN_MEM_ACCESS_ITEST : BFIN_MEM_ACCESS_IDMA; 395 if (in_mem_const(addr, size, COREB_L1_SCRATCH_START, L1_SCRATCH_LENGTH)) 396 return cpu == 1 ? BFIN_MEM_ACCESS_CORE_ONLY : -EFAULT; 397 - if (in_mem_const(addr, size, COREB_L1_DATA_A_START, L1_DATA_A_LENGTH)) 398 return cpu == 1 ? BFIN_MEM_ACCESS_CORE : BFIN_MEM_ACCESS_IDMA; 399 - if (in_mem_const(addr, size, COREB_L1_DATA_B_START, L1_DATA_B_LENGTH)) 400 return cpu == 1 ? BFIN_MEM_ACCESS_CORE : BFIN_MEM_ACCESS_IDMA; 401 #endif 402 if (in_mem_const(addr, size, L2_START, L2_LENGTH)) ··· 472 if (in_mem_const_off(addr, size, _ebss_b_l1 - _sdata_b_l1, L1_DATA_B_START, L1_DATA_B_LENGTH)) 473 return 1; 474 #ifdef COREB_L1_CODE_START 475 - if (in_mem_const(addr, size, COREB_L1_CODE_START, L1_CODE_LENGTH)) 476 return 1; 477 if (in_mem_const(addr, size, COREB_L1_SCRATCH_START, L1_SCRATCH_LENGTH)) 478 return 1; 479 - if (in_mem_const(addr, size, COREB_L1_DATA_A_START, L1_DATA_A_LENGTH)) 480 return 1; 481 - if (in_mem_const(addr, size, COREB_L1_DATA_B_START, L1_DATA_B_LENGTH)) 482 return 1; 483 #endif 484 if (in_mem_const_off(addr, size, _ebss_l2 - _stext_l2, L2_START, L2_LENGTH))
··· 361 int in_mem_const(unsigned long addr, unsigned long size, 362 unsigned long const_addr, unsigned long const_size) 363 { 364 + return in_mem_const_off(addr, size, 0, const_addr, const_size); 365 } 366 #define IN_ASYNC(bnum, bctlnum) \ 367 ({ \ ··· 390 if (in_mem_const(addr, size, L1_DATA_B_START, L1_DATA_B_LENGTH)) 391 return cpu == 0 ? BFIN_MEM_ACCESS_CORE : BFIN_MEM_ACCESS_IDMA; 392 #ifdef COREB_L1_CODE_START 393 + if (in_mem_const(addr, size, COREB_L1_CODE_START, COREB_L1_CODE_LENGTH)) 394 return cpu == 1 ? BFIN_MEM_ACCESS_ITEST : BFIN_MEM_ACCESS_IDMA; 395 if (in_mem_const(addr, size, COREB_L1_SCRATCH_START, L1_SCRATCH_LENGTH)) 396 return cpu == 1 ? BFIN_MEM_ACCESS_CORE_ONLY : -EFAULT; 397 + if (in_mem_const(addr, size, COREB_L1_DATA_A_START, COREB_L1_DATA_A_LENGTH)) 398 return cpu == 1 ? BFIN_MEM_ACCESS_CORE : BFIN_MEM_ACCESS_IDMA; 399 + if (in_mem_const(addr, size, COREB_L1_DATA_B_START, COREB_L1_DATA_B_LENGTH)) 400 return cpu == 1 ? BFIN_MEM_ACCESS_CORE : BFIN_MEM_ACCESS_IDMA; 401 #endif 402 if (in_mem_const(addr, size, L2_START, L2_LENGTH)) ··· 472 if (in_mem_const_off(addr, size, _ebss_b_l1 - _sdata_b_l1, L1_DATA_B_START, L1_DATA_B_LENGTH)) 473 return 1; 474 #ifdef COREB_L1_CODE_START 475 + if (in_mem_const(addr, size, COREB_L1_CODE_START, COREB_L1_CODE_LENGTH)) 476 return 1; 477 if (in_mem_const(addr, size, COREB_L1_SCRATCH_START, L1_SCRATCH_LENGTH)) 478 return 1; 479 + if (in_mem_const(addr, size, COREB_L1_DATA_A_START, COREB_L1_DATA_A_LENGTH)) 480 return 1; 481 + if (in_mem_const(addr, size, COREB_L1_DATA_B_START, COREB_L1_DATA_B_LENGTH)) 482 return 1; 483 #endif 484 if (in_mem_const_off(addr, size, _ebss_l2 - _stext_l2, L2_START, L2_LENGTH))
+18 -24
arch/blackfin/kernel/setup.c
··· 168 struct blackfin_cpudata *cpudata = &per_cpu(cpu_data, cpu); 169 170 cpudata->idle = current; 171 - cpudata->loops_per_jiffy = loops_per_jiffy; 172 cpudata->imemctl = bfin_read_IMEM_CONTROL(); 173 cpudata->dmemctl = bfin_read_DMEM_CONTROL(); 174 } ··· 567 # endif /* ANOMALY_05000263 */ 568 # endif /* CONFIG_ROMFS_FS */ 569 570 - memory_end -= mtd_size; 571 572 - if (mtd_size == 0) { 573 - console_init(); 574 - panic("Don't boot kernel without rootfs attached."); 575 } 576 - 577 - /* Relocate MTD image to the top of memory after the uncached memory area */ 578 - uclinux_ram_map.phys = memory_mtd_start = memory_end; 579 - uclinux_ram_map.size = mtd_size; 580 - dma_memcpy((void *)uclinux_ram_map.phys, _end, uclinux_ram_map.size); 581 #endif /* CONFIG_MTD_UCLINUX */ 582 583 #if (defined(CONFIG_BFIN_EXTMEM_ICACHEABLE) && ANOMALY_05000263) ··· 873 else 874 printk(KERN_CONT "and Disabled\n"); 875 876 - #if defined(CONFIG_CHR_DEV_FLASH) || defined(CONFIG_BLK_DEV_FLASH) 877 - /* we need to initialize the Flashrom device here since we might 878 - * do things with flash early on in the boot 879 - */ 880 - flash_probe(); 881 - #endif 882 - 883 printk(KERN_INFO "Boot Mode: %i\n", bfin_read_SYSCR() & 0xF); 884 885 /* Newer parts mirror SWRST bits in SYSCR */ ··· 935 printk(KERN_ERR "Warning: Unsupported Chip Revision ADSP-%s Rev 0.%d detected\n", 936 CPU, bfin_revid()); 937 } 938 - 939 - /* We can't run on BF548-0.1 due to ANOMALY 05000448 */ 940 - if (bfin_cpuid() == 0x27de && bfin_revid() == 1) 941 - panic("You can't run on this processor due to 05000448"); 942 943 printk(KERN_INFO "Blackfin Linux support by http://blackfin.uclinux.org/\n"); 944 ··· 1158 sclk/1000000, sclk%1000000); 1159 seq_printf(m, "bogomips\t: %lu.%02lu\n" 1160 "Calibration\t: %lu loops\n", 1161 - (cpudata->loops_per_jiffy * HZ) / 500000, 1162 - ((cpudata->loops_per_jiffy * HZ) / 5000) % 100, 1163 - (cpudata->loops_per_jiffy * HZ)); 1164 1165 /* Check Cache configutation */ 1166 switch (cpudata->dmemctl & (1 << DMC0_P | 1 << DMC1_P)) {
··· 168 struct blackfin_cpudata *cpudata = &per_cpu(cpu_data, cpu); 169 170 cpudata->idle = current; 171 cpudata->imemctl = bfin_read_IMEM_CONTROL(); 172 cpudata->dmemctl = bfin_read_DMEM_CONTROL(); 173 } ··· 568 # endif /* ANOMALY_05000263 */ 569 # endif /* CONFIG_ROMFS_FS */ 570 571 + /* Since the default MTD_UCLINUX has no magic number, we just blindly 572 + * read 8 past the end of the kernel's image, and look at it. 573 + * When no image is attached, mtd_size is set to a random number 574 + * Do some basic sanity checks before operating on things 575 + */ 576 + if (mtd_size == 0 || memory_end <= mtd_size) { 577 + pr_emerg("Could not find valid ram mtd attached.\n"); 578 + } else { 579 + memory_end -= mtd_size; 580 581 + /* Relocate MTD image to the top of memory after the uncached memory area */ 582 + uclinux_ram_map.phys = memory_mtd_start = memory_end; 583 + uclinux_ram_map.size = mtd_size; 584 + pr_info("Found mtd parition at 0x%p, (len=0x%lx), moving to 0x%p\n", 585 + _end, mtd_size, (void *)memory_mtd_start); 586 + dma_memcpy((void *)uclinux_ram_map.phys, _end, uclinux_ram_map.size); 587 } 588 #endif /* CONFIG_MTD_UCLINUX */ 589 590 #if (defined(CONFIG_BFIN_EXTMEM_ICACHEABLE) && ANOMALY_05000263) ··· 868 else 869 printk(KERN_CONT "and Disabled\n"); 870 871 printk(KERN_INFO "Boot Mode: %i\n", bfin_read_SYSCR() & 0xF); 872 873 /* Newer parts mirror SWRST bits in SYSCR */ ··· 937 printk(KERN_ERR "Warning: Unsupported Chip Revision ADSP-%s Rev 0.%d detected\n", 938 CPU, bfin_revid()); 939 } 940 941 printk(KERN_INFO "Blackfin Linux support by http://blackfin.uclinux.org/\n"); 942 ··· 1164 sclk/1000000, sclk%1000000); 1165 seq_printf(m, "bogomips\t: %lu.%02lu\n" 1166 "Calibration\t: %lu loops\n", 1167 + (loops_per_jiffy * HZ) / 500000, 1168 + ((loops_per_jiffy * HZ) / 5000) % 100, 1169 + (loops_per_jiffy * HZ)); 1170 1171 /* Check Cache configutation */ 1172 switch (cpudata->dmemctl & (1 << DMC0_P | 1 << DMC1_P)) {
+6 -3
arch/blackfin/kernel/traps.c
··· 570 if (kernel_mode_regs(fp) || (current && !current->mm)) { 571 console_verbose(); 572 oops_in_progress = 1; 573 - if (strerror) 574 - verbose_printk(strerror); 575 } 576 577 if (sig != SIGTRAP) { 578 dump_bfin_process(fp); 579 dump_bfin_mem(fp); 580 show_regs(fp); ··· 620 force_sig_info(sig, &info, current); 621 } 622 623 - if (ANOMALY_05000461 && trapnr == VEC_HWERR && !access_ok(VERIFY_READ, fp->pc, 8)) 624 fp->pc = SAFE_USER_INSTRUCTION; 625 626 traps_done:
··· 570 if (kernel_mode_regs(fp) || (current && !current->mm)) { 571 console_verbose(); 572 oops_in_progress = 1; 573 } 574 575 if (sig != SIGTRAP) { 576 + if (strerror) 577 + verbose_printk(strerror); 578 + 579 dump_bfin_process(fp); 580 dump_bfin_mem(fp); 581 show_regs(fp); ··· 619 force_sig_info(sig, &info, current); 620 } 621 622 + if ((ANOMALY_05000461 && trapnr == VEC_HWERR && !access_ok(VERIFY_READ, fp->pc, 8)) || 623 + (ANOMALY_05000281 && trapnr == VEC_HWERR) || 624 + (ANOMALY_05000189 && (trapnr == VEC_CPLB_I_VL || trapnr == VEC_CPLB_VL))) 625 fp->pc = SAFE_USER_INSTRUCTION; 626 627 traps_done:
+1 -15
arch/blackfin/lib/lshrdi3.c
··· 27 * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 28 */ 29 30 - #define BITS_PER_UNIT 8 31 - 32 - typedef int SItype __attribute__ ((mode(SI))); 33 - typedef unsigned int USItype __attribute__ ((mode(SI))); 34 - typedef int DItype __attribute__ ((mode(DI))); 35 - typedef int word_type __attribute__ ((mode(__word__))); 36 - 37 - struct DIstruct { 38 - SItype high, low; 39 - }; 40 - 41 - typedef union { 42 - struct DIstruct s; 43 - DItype ll; 44 - } DIunion; 45 46 #ifdef CONFIG_ARITHMETIC_OPS_L1 47 DItype __lshrdi3(DItype u, word_type b)__attribute__((l1_text));
··· 27 * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 28 */ 29 30 + #include "gcclib.h" 31 32 #ifdef CONFIG_ARITHMETIC_OPS_L1 33 DItype __lshrdi3(DItype u, word_type b)__attribute__((l1_text));
+1 -1
arch/blackfin/mach-bf518/boards/ezbrd.c
··· 534 #endif 535 536 static struct i2c_board_info __initdata bfin_i2c_board_info[] = { 537 - #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_TWI_LCD_MODULE) 538 { 539 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 540 },
··· 534 #endif 535 536 static struct i2c_board_info __initdata bfin_i2c_board_info[] = { 537 + #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_BFIN_TWI_LCD_MODULE) 538 { 539 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 540 },
+2
arch/blackfin/mach-bf518/include/mach/anomaly.h
··· 82 #define ANOMALY_05000179 (0) 83 #define ANOMALY_05000182 (0) 84 #define ANOMALY_05000183 (0) 85 #define ANOMALY_05000198 (0) 86 #define ANOMALY_05000202 (0) 87 #define ANOMALY_05000215 (0) ··· 118 #define ANOMALY_05000357 (0) 119 #define ANOMALY_05000362 (1) 120 #define ANOMALY_05000363 (0) 121 #define ANOMALY_05000371 (0) 122 #define ANOMALY_05000380 (0) 123 #define ANOMALY_05000386 (0)
··· 82 #define ANOMALY_05000179 (0) 83 #define ANOMALY_05000182 (0) 84 #define ANOMALY_05000183 (0) 85 + #define ANOMALY_05000189 (0) 86 #define ANOMALY_05000198 (0) 87 #define ANOMALY_05000202 (0) 88 #define ANOMALY_05000215 (0) ··· 117 #define ANOMALY_05000357 (0) 118 #define ANOMALY_05000362 (1) 119 #define ANOMALY_05000363 (0) 120 + #define ANOMALY_05000364 (0) 121 #define ANOMALY_05000371 (0) 122 #define ANOMALY_05000380 (0) 123 #define ANOMALY_05000386 (0)
+1 -1
arch/blackfin/mach-bf527/boards/cm_bf527.c
··· 793 #endif 794 795 static struct i2c_board_info __initdata bfin_i2c_board_info[] = { 796 - #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_TWI_LCD_MODULE) 797 { 798 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 799 .type = "pcf8574_lcd",
··· 793 #endif 794 795 static struct i2c_board_info __initdata bfin_i2c_board_info[] = { 796 + #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_BFIN_TWI_LCD_MODULE) 797 { 798 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 799 .type = "pcf8574_lcd",
+1 -1
arch/blackfin/mach-bf527/boards/ezbrd.c
··· 591 #endif 592 593 static struct i2c_board_info __initdata bfin_i2c_board_info[] = { 594 - #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_TWI_LCD_MODULE) 595 { 596 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 597 },
··· 591 #endif 592 593 static struct i2c_board_info __initdata bfin_i2c_board_info[] = { 594 + #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_BFIN_TWI_LCD_MODULE) 595 { 596 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 597 },
+1 -1
arch/blackfin/mach-bf527/boards/ezkit.c
··· 858 #endif 859 860 static struct i2c_board_info __initdata bfin_i2c_board_info[] = { 861 - #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_TWI_LCD_MODULE) 862 { 863 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 864 },
··· 858 #endif 859 860 static struct i2c_board_info __initdata bfin_i2c_board_info[] = { 861 + #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_BFIN_TWI_LCD_MODULE) 862 { 863 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 864 },
+3 -1
arch/blackfin/mach-bf527/include/mach/anomaly.h
··· 176 #define ANOMALY_05000443 (1) 177 /* The WURESET Bit in the SYSCR Register is not Functional */ 178 #define ANOMALY_05000445 (1) 179 /* BCODE_QUICKBOOT, BCODE_ALLBOOT, and BCODE_FULLBOOT Settings in SYSCR Register Not Functional */ 180 #define ANOMALY_05000451 (1) 181 /* Incorrect Default Hysteresis Setting for RESET, NMI, and BMODE Signals */ ··· 203 #define ANOMALY_05000179 (0) 204 #define ANOMALY_05000182 (0) 205 #define ANOMALY_05000183 (0) 206 #define ANOMALY_05000198 (0) 207 #define ANOMALY_05000202 (0) 208 #define ANOMALY_05000215 (0) ··· 241 #define ANOMALY_05000412 (0) 242 #define ANOMALY_05000447 (0) 243 #define ANOMALY_05000448 (0) 244 - #define ANOMALY_05000450 (0) 245 246 #endif
··· 176 #define ANOMALY_05000443 (1) 177 /* The WURESET Bit in the SYSCR Register is not Functional */ 178 #define ANOMALY_05000445 (1) 179 + /* USB DMA Short Packet Data Corruption */ 180 + #define ANOMALY_05000450 (1) 181 /* BCODE_QUICKBOOT, BCODE_ALLBOOT, and BCODE_FULLBOOT Settings in SYSCR Register Not Functional */ 182 #define ANOMALY_05000451 (1) 183 /* Incorrect Default Hysteresis Setting for RESET, NMI, and BMODE Signals */ ··· 201 #define ANOMALY_05000179 (0) 202 #define ANOMALY_05000182 (0) 203 #define ANOMALY_05000183 (0) 204 + #define ANOMALY_05000189 (0) 205 #define ANOMALY_05000198 (0) 206 #define ANOMALY_05000202 (0) 207 #define ANOMALY_05000215 (0) ··· 238 #define ANOMALY_05000412 (0) 239 #define ANOMALY_05000447 (0) 240 #define ANOMALY_05000448 (0) 241 242 #endif
+1 -1
arch/blackfin/mach-bf533/boards/stamp.c
··· 453 .irq = 39, 454 }, 455 #endif 456 - #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_TWI_LCD_MODULE) 457 { 458 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 459 },
··· 453 .irq = 39, 454 }, 455 #endif 456 + #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_BFIN_TWI_LCD_MODULE) 457 { 458 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 459 },
+1
arch/blackfin/mach-bf533/include/mach/anomaly.h
··· 335 #define ANOMALY_05000323 (0) 336 #define ANOMALY_05000353 (1) 337 #define ANOMALY_05000362 (1) 338 #define ANOMALY_05000380 (0) 339 #define ANOMALY_05000386 (1) 340 #define ANOMALY_05000389 (0)
··· 335 #define ANOMALY_05000323 (0) 336 #define ANOMALY_05000353 (1) 337 #define ANOMALY_05000362 (1) 338 + #define ANOMALY_05000364 (0) 339 #define ANOMALY_05000380 (0) 340 #define ANOMALY_05000386 (1) 341 #define ANOMALY_05000389 (0)
+2 -2
arch/blackfin/mach-bf537/boards/stamp.c
··· 1313 #if defined(CONFIG_JOYSTICK_AD7142) || defined(CONFIG_JOYSTICK_AD7142_MODULE) 1314 { 1315 I2C_BOARD_INFO("ad7142_joystick", 0x2C), 1316 - .irq = IRQ_PF5, 1317 }, 1318 #endif 1319 - #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_TWI_LCD_MODULE) 1320 { 1321 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 1322 },
··· 1313 #if defined(CONFIG_JOYSTICK_AD7142) || defined(CONFIG_JOYSTICK_AD7142_MODULE) 1314 { 1315 I2C_BOARD_INFO("ad7142_joystick", 0x2C), 1316 + .irq = IRQ_PG5, 1317 }, 1318 #endif 1319 + #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_BFIN_TWI_LCD_MODULE) 1320 { 1321 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 1322 },
+2
arch/blackfin/mach-bf537/include/mach/anomaly.h
··· 167 #define ANOMALY_05000179 (0) 168 #define ANOMALY_05000182 (0) 169 #define ANOMALY_05000183 (0) 170 #define ANOMALY_05000198 (0) 171 #define ANOMALY_05000202 (0) 172 #define ANOMALY_05000215 (0) ··· 187 #define ANOMALY_05000353 (1) 188 #define ANOMALY_05000362 (1) 189 #define ANOMALY_05000363 (0) 190 #define ANOMALY_05000380 (0) 191 #define ANOMALY_05000386 (1) 192 #define ANOMALY_05000389 (0)
··· 167 #define ANOMALY_05000179 (0) 168 #define ANOMALY_05000182 (0) 169 #define ANOMALY_05000183 (0) 170 + #define ANOMALY_05000189 (0) 171 #define ANOMALY_05000198 (0) 172 #define ANOMALY_05000202 (0) 173 #define ANOMALY_05000215 (0) ··· 186 #define ANOMALY_05000353 (1) 187 #define ANOMALY_05000362 (1) 188 #define ANOMALY_05000363 (0) 189 + #define ANOMALY_05000364 (0) 190 #define ANOMALY_05000380 (0) 191 #define ANOMALY_05000386 (1) 192 #define ANOMALY_05000389 (0)
+2
arch/blackfin/mach-bf538/include/mach/anomaly.h
··· 137 #define ANOMALY_05000158 (0) 138 #define ANOMALY_05000171 (0) 139 #define ANOMALY_05000182 (0) 140 #define ANOMALY_05000198 (0) 141 #define ANOMALY_05000202 (0) 142 #define ANOMALY_05000215 (0) ··· 161 #define ANOMALY_05000353 (1) 162 #define ANOMALY_05000362 (1) 163 #define ANOMALY_05000363 (0) 164 #define ANOMALY_05000380 (0) 165 #define ANOMALY_05000386 (1) 166 #define ANOMALY_05000389 (0)
··· 137 #define ANOMALY_05000158 (0) 138 #define ANOMALY_05000171 (0) 139 #define ANOMALY_05000182 (0) 140 + #define ANOMALY_05000189 (0) 141 #define ANOMALY_05000198 (0) 142 #define ANOMALY_05000202 (0) 143 #define ANOMALY_05000215 (0) ··· 160 #define ANOMALY_05000353 (1) 161 #define ANOMALY_05000362 (1) 162 #define ANOMALY_05000363 (0) 163 + #define ANOMALY_05000364 (0) 164 #define ANOMALY_05000380 (0) 165 #define ANOMALY_05000386 (1) 166 #define ANOMALY_05000389 (0)
+1 -1
arch/blackfin/mach-bf548/boards/ezkit.c
··· 864 865 #if !defined(CONFIG_BF542) /* The BF542 only has 1 TWI */ 866 static struct i2c_board_info __initdata bfin_i2c_board_info1[] = { 867 - #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_TWI_LCD_MODULE) 868 { 869 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 870 },
··· 864 865 #if !defined(CONFIG_BF542) /* The BF542 only has 1 TWI */ 866 static struct i2c_board_info __initdata bfin_i2c_board_info1[] = { 867 + #if defined(CONFIG_BFIN_TWI_LCD) || defined(CONFIG_BFIN_TWI_LCD_MODULE) 868 { 869 I2C_BOARD_INFO("pcf8574_lcd", 0x22), 870 },
+2
arch/blackfin/mach-bf548/include/mach/anomaly.h
··· 195 #define ANOMALY_05000179 (0) 196 #define ANOMALY_05000182 (0) 197 #define ANOMALY_05000183 (0) 198 #define ANOMALY_05000198 (0) 199 #define ANOMALY_05000202 (0) 200 #define ANOMALY_05000215 (0) ··· 227 #define ANOMALY_05000323 (0) 228 #define ANOMALY_05000362 (1) 229 #define ANOMALY_05000363 (0) 230 #define ANOMALY_05000380 (0) 231 #define ANOMALY_05000400 (0) 232 #define ANOMALY_05000412 (0)
··· 195 #define ANOMALY_05000179 (0) 196 #define ANOMALY_05000182 (0) 197 #define ANOMALY_05000183 (0) 198 + #define ANOMALY_05000189 (0) 199 #define ANOMALY_05000198 (0) 200 #define ANOMALY_05000202 (0) 201 #define ANOMALY_05000215 (0) ··· 226 #define ANOMALY_05000323 (0) 227 #define ANOMALY_05000362 (1) 228 #define ANOMALY_05000363 (0) 229 + #define ANOMALY_05000364 (0) 230 #define ANOMALY_05000380 (0) 231 #define ANOMALY_05000400 (0) 232 #define ANOMALY_05000412 (0)
+1
arch/blackfin/mach-bf561/include/mach/anomaly.h
··· 288 #define ANOMALY_05000273 (0) 289 #define ANOMALY_05000311 (0) 290 #define ANOMALY_05000353 (1) 291 #define ANOMALY_05000380 (0) 292 #define ANOMALY_05000386 (1) 293 #define ANOMALY_05000389 (0)
··· 288 #define ANOMALY_05000273 (0) 289 #define ANOMALY_05000311 (0) 290 #define ANOMALY_05000353 (1) 291 + #define ANOMALY_05000364 (0) 292 #define ANOMALY_05000380 (0) 293 #define ANOMALY_05000386 (1) 294 #define ANOMALY_05000389 (0)
+22 -1
arch/blackfin/mach-bf561/include/mach/mem_map.h
··· 37 38 /* Memory Map for ADSP-BF561 processors */ 39 40 - #ifdef CONFIG_BF561 41 #define COREA_L1_CODE_START 0xFFA00000 42 #define COREA_L1_DATA_A_START 0xFF800000 43 #define COREA_L1_DATA_B_START 0xFF900000 ··· 73 #define BFIN_DCACHESIZE (0*1024) 74 #define BFIN_DSUPBANKS 0 75 #endif /*CONFIG_BFIN_DCACHE*/ 76 #endif 77 78 /* Level 2 Memory */
··· 37 38 /* Memory Map for ADSP-BF561 processors */ 39 40 #define COREA_L1_CODE_START 0xFFA00000 41 #define COREA_L1_DATA_A_START 0xFF800000 42 #define COREA_L1_DATA_B_START 0xFF900000 ··· 74 #define BFIN_DCACHESIZE (0*1024) 75 #define BFIN_DSUPBANKS 0 76 #endif /*CONFIG_BFIN_DCACHE*/ 77 + 78 + /* 79 + * If we are in SMP mode, then the cache settings of Core B will match 80 + * the settings of Core A. If we aren't, then we assume Core B is not 81 + * using any cache. This allows the rest of the kernel to work with 82 + * the core in either mode as we are only loading user code into it and 83 + * it is the user's problem to make sure they aren't doing something 84 + * stupid there. 85 + * 86 + * Note that we treat the L1 code region as a contiguous blob to make 87 + * the rest of the kernel simpler. Easier to check one region than a 88 + * bunch of small ones. Again, possible misbehavior here is the fault 89 + * of the user -- don't try to use memory that doesn't exist. 90 + */ 91 + #ifdef CONFIG_SMP 92 + # define COREB_L1_CODE_LENGTH L1_CODE_LENGTH 93 + # define COREB_L1_DATA_A_LENGTH L1_DATA_A_LENGTH 94 + # define COREB_L1_DATA_B_LENGTH L1_DATA_B_LENGTH 95 + #else 96 + # define COREB_L1_CODE_LENGTH 0x14000 97 + # define COREB_L1_DATA_A_LENGTH 0x8000 98 + # define COREB_L1_DATA_B_LENGTH 0x8000 99 #endif 100 101 /* Level 2 Memory */
+7 -5
arch/blackfin/mach-common/entry.S
··· 218 /* Single stepping only a single instruction, so clear the trace 219 * bit here. */ 220 r7 = syscfg; 221 - bitclr (r7, 0); 222 syscfg = R7; 223 jump _ex_trap_c; 224 ··· 251 if !cc jump _bfin_return_from_exception; 252 253 r7 = syscfg; 254 - bitclr (r7, 0); 255 syscfg = R7; 256 257 /* Fall through to _bfin_return_from_exception. */ ··· 342 r6 = retx; 343 [p5 + PDA_RETX] = r6; 344 #endif 345 r6 = SYSCFG; 346 [p5 + PDA_SYSCFG] = r6; 347 - BITCLR(r6, 0); 348 SYSCFG = r6; 349 350 /* Disable all interrupts, but make sure level 5 is enabled so ··· 369 * exception. This is a unrecoverable event, so crash. 370 * Note: this cannot be ENTRY() as we jump here with "if cc jump" ... 371 */ 372 - _double_fault: 373 /* Turn caches & protection off, to ensure we don't get any more 374 * double exceptions 375 */ ··· 874 raise 15; /* raise evt15 to do signal or reschedule */ 875 4: 876 r0 = syscfg; 877 - bitclr(r0, 0); 878 syscfg = r0; 879 5: 880 rts;
··· 218 /* Single stepping only a single instruction, so clear the trace 219 * bit here. */ 220 r7 = syscfg; 221 + bitclr (r7, SYSCFG_SSSTEP_P); 222 syscfg = R7; 223 jump _ex_trap_c; 224 ··· 251 if !cc jump _bfin_return_from_exception; 252 253 r7 = syscfg; 254 + bitclr (r7, SYSCFG_SSSTEP_P); /* Turn off single step */ 255 syscfg = R7; 256 257 /* Fall through to _bfin_return_from_exception. */ ··· 342 r6 = retx; 343 [p5 + PDA_RETX] = r6; 344 #endif 345 + /* Save the state of single stepping */ 346 r6 = SYSCFG; 347 [p5 + PDA_SYSCFG] = r6; 348 + /* Clear it while we handle the exception in IRQ5 mode */ 349 + BITCLR(r6, SYSCFG_SSSTEP_P); 350 SYSCFG = r6; 351 352 /* Disable all interrupts, but make sure level 5 is enabled so ··· 367 * exception. This is a unrecoverable event, so crash. 368 * Note: this cannot be ENTRY() as we jump here with "if cc jump" ... 369 */ 370 + ENTRY(_double_fault) 371 /* Turn caches & protection off, to ensure we don't get any more 372 * double exceptions 373 */ ··· 872 raise 15; /* raise evt15 to do signal or reschedule */ 873 4: 874 r0 = syscfg; 875 + bitclr(r0, SYSCFG_SSSTEP_P); /* Turn off single step */ 876 syscfg = r0; 877 5: 878 rts;
+9 -1
arch/blackfin/mach-common/smp.c
··· 211 return 0; 212 213 msg = kmalloc(sizeof(*msg), GFP_ATOMIC); 214 INIT_LIST_HEAD(&msg->list); 215 msg->call_struct.func = func; 216 msg->call_struct.info = info; ··· 254 cpu_set(cpu, callmap); 255 256 msg = kmalloc(sizeof(*msg), GFP_ATOMIC); 257 INIT_LIST_HEAD(&msg->list); 258 msg->call_struct.func = func; 259 msg->call_struct.info = info; ··· 291 return; 292 293 msg = kmalloc(sizeof(*msg), GFP_ATOMIC); 294 memset(msg, 0, sizeof(msg)); 295 INIT_LIST_HEAD(&msg->list); 296 msg->type = BFIN_IPI_RESCHEDULE; ··· 320 return; 321 322 msg = kmalloc(sizeof(*msg), GFP_ATOMIC); 323 memset(msg, 0, sizeof(msg)); 324 INIT_LIST_HEAD(&msg->list); 325 msg->type = BFIN_IPI_CPU_STOP; ··· 458 unsigned int cpu; 459 460 for_each_online_cpu(cpu) 461 - bogosum += per_cpu(cpu_data, cpu).loops_per_jiffy; 462 463 printk(KERN_INFO "SMP: Total of %d processors activated " 464 "(%lu.%02lu BogoMIPS).\n",
··· 211 return 0; 212 213 msg = kmalloc(sizeof(*msg), GFP_ATOMIC); 214 + if (!msg) 215 + return -ENOMEM; 216 INIT_LIST_HEAD(&msg->list); 217 msg->call_struct.func = func; 218 msg->call_struct.info = info; ··· 252 cpu_set(cpu, callmap); 253 254 msg = kmalloc(sizeof(*msg), GFP_ATOMIC); 255 + if (!msg) 256 + return -ENOMEM; 257 INIT_LIST_HEAD(&msg->list); 258 msg->call_struct.func = func; 259 msg->call_struct.info = info; ··· 287 return; 288 289 msg = kmalloc(sizeof(*msg), GFP_ATOMIC); 290 + if (!msg) 291 + return; 292 memset(msg, 0, sizeof(msg)); 293 INIT_LIST_HEAD(&msg->list); 294 msg->type = BFIN_IPI_RESCHEDULE; ··· 314 return; 315 316 msg = kmalloc(sizeof(*msg), GFP_ATOMIC); 317 + if (!msg) 318 + return; 319 memset(msg, 0, sizeof(msg)); 320 INIT_LIST_HEAD(&msg->list); 321 msg->type = BFIN_IPI_CPU_STOP; ··· 450 unsigned int cpu; 451 452 for_each_online_cpu(cpu) 453 + bogosum += loops_per_jiffy; 454 455 printk(KERN_INFO "SMP: Total of %d processors activated " 456 "(%lu.%02lu BogoMIPS).\n",