Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge branch 'fixes' of git://ftp.arm.linux.org.uk/~rmk/linux-arm

Pull ARM fixes from Russell King:
"Another round of relatively small ARM fixes.

Thomas spotted that the strex backoff delay bit was a disable bit, so
it needed to be clear for this to work. Vladimir spotted that using a
restart block for the cache flush operation would return -EINTR, which
userspace was not expecting. Dmitry spotted that the auxiliary
control register accesses for Xscale were not correct"

* 'fixes' of git://ftp.arm.linux.org.uk/~rmk/linux-arm:
ARM: 8226/1: cacheflush: get rid of restarting block
ARM: 8222/1: mvebu: enable strex backoff delay
ARM: 8216/1: xscale: correct auxiliary register in suspend/resume

+4 -44
-11
arch/arm/include/asm/thread_info.h
··· 44 44 __u32 extra[2]; /* Xscale 'acc' register, etc */ 45 45 }; 46 46 47 - struct arm_restart_block { 48 - union { 49 - /* For user cache flushing */ 50 - struct { 51 - unsigned long start; 52 - unsigned long end; 53 - } cache; 54 - }; 55 - }; 56 - 57 47 /* 58 48 * low level task data that entry.S needs immediate access to. 59 49 * __switch_to() assumes cpu_context follows immediately after cpu_domain. ··· 69 79 unsigned long thumbee_state; /* ThumbEE Handler Base register */ 70 80 #endif 71 81 struct restart_block restart_block; 72 - struct arm_restart_block arm_restart_block; 73 82 }; 74 83 75 84 #define INIT_THREAD_INFO(tsk) \
+2 -29
arch/arm/kernel/traps.c
··· 533 533 return regs->ARM_r0; 534 534 } 535 535 536 - static long do_cache_op_restart(struct restart_block *); 537 - 538 536 static inline int 539 537 __do_cache_op(unsigned long start, unsigned long end) 540 538 { ··· 541 543 do { 542 544 unsigned long chunk = min(PAGE_SIZE, end - start); 543 545 544 - if (signal_pending(current)) { 545 - struct thread_info *ti = current_thread_info(); 546 - 547 - ti->restart_block = (struct restart_block) { 548 - .fn = do_cache_op_restart, 549 - }; 550 - 551 - ti->arm_restart_block = (struct arm_restart_block) { 552 - { 553 - .cache = { 554 - .start = start, 555 - .end = end, 556 - }, 557 - }, 558 - }; 559 - 560 - return -ERESTART_RESTARTBLOCK; 561 - } 546 + if (fatal_signal_pending(current)) 547 + return 0; 562 548 563 549 ret = flush_cache_user_range(start, start + chunk); 564 550 if (ret) ··· 553 571 } while (start < end); 554 572 555 573 return 0; 556 - } 557 - 558 - static long do_cache_op_restart(struct restart_block *unused) 559 - { 560 - struct arm_restart_block *restart_block; 561 - 562 - restart_block = &current_thread_info()->arm_restart_block; 563 - return __do_cache_op(restart_block->cache.start, 564 - restart_block->cache.end); 565 574 } 566 575 567 576 static inline int
-2
arch/arm/mm/proc-v7.S
··· 270 270 /* Auxiliary Debug Modes Control 1 Register */ 271 271 #define PJ4B_STATIC_BP (1 << 2) /* Enable Static BP */ 272 272 #define PJ4B_INTER_PARITY (1 << 8) /* Disable Internal Parity Handling */ 273 - #define PJ4B_BCK_OFF_STREX (1 << 5) /* Enable the back off of STREX instr */ 274 273 #define PJ4B_CLEAN_LINE (1 << 16) /* Disable data transfer for clean line */ 275 274 276 275 /* Auxiliary Debug Modes Control 2 Register */ ··· 292 293 /* Auxiliary Debug Modes Control 1 Register */ 293 294 mrc p15, 1, r0, c15, c1, 1 294 295 orr r0, r0, #PJ4B_CLEAN_LINE 295 - orr r0, r0, #PJ4B_BCK_OFF_STREX 296 296 orr r0, r0, #PJ4B_INTER_PARITY 297 297 bic r0, r0, #PJ4B_STATIC_BP 298 298 mcr p15, 1, r0, c15, c1, 1
+2 -2
arch/arm/mm/proc-xscale.S
··· 535 535 mrc p15, 0, r5, c15, c1, 0 @ CP access reg 536 536 mrc p15, 0, r6, c13, c0, 0 @ PID 537 537 mrc p15, 0, r7, c3, c0, 0 @ domain ID 538 - mrc p15, 0, r8, c1, c1, 0 @ auxiliary control reg 538 + mrc p15, 0, r8, c1, c0, 1 @ auxiliary control reg 539 539 mrc p15, 0, r9, c1, c0, 0 @ control reg 540 540 bic r4, r4, #2 @ clear frequency change bit 541 541 stmia r0, {r4 - r9} @ store cp regs ··· 552 552 mcr p15, 0, r6, c13, c0, 0 @ PID 553 553 mcr p15, 0, r7, c3, c0, 0 @ domain ID 554 554 mcr p15, 0, r1, c2, c0, 0 @ translation table base addr 555 - mcr p15, 0, r8, c1, c1, 0 @ auxiliary control reg 555 + mcr p15, 0, r8, c1, c0, 1 @ auxiliary control reg 556 556 mov r0, r9 @ control register 557 557 b cpu_resume_mmu 558 558 ENDPROC(cpu_xscale_do_resume)