diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-09-05 18:28:17 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-09-05 18:28:17 -0400 |
commit | b14662cae0f765355d43357180f4c34916610269 (patch) | |
tree | e7e7132783fb76186829fc38f2639ae41bc28330 | |
parent | cc998ff8811530be521f6b316f37ab7676a07938 (diff) | |
parent | dc76f9ca71ea597dbb0e9c77d1072ddca651f4f3 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc
Pull sparc changes from David Miller:
"Several bug fixes (from Kirill Tkhai, Geery Uytterhoeven, and Alexey
Dobriyan) and some support for Fujitsu sparc64x chips (from Allen
Pais)"
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc:
sparc64: Export flush_ptrace_access() (needed by lustre)
sparc: fix PCI device proc file mmap(2)
sparc64: Remove RWSEM export leftovers
sparc64: Fix off by one in trampoline TLB mapping installation loop.
sparc64: Fix ITLB handler of null page
esp_scsi: Fix tag state corruption when autosensing.
sparc64: Fix not SRA'ed %o5 in 32-bit traced syscall
sparc64: cleanup: Rename ret_from_syscall to ret_from_fork
sparc32: Fix exit flag passed from traced sys_sigreturn
sparc64: Fix wrong syscall return value passed to trace_sys_exit()
support sparc64x chip type in cpumap.c
cpu hw caps support for sparc64x
-rw-r--r-- | arch/sparc/include/asm/switch_to_64.h | 4 | ||||
-rw-r--r-- | arch/sparc/kernel/cpumap.c | 1 | ||||
-rw-r--r-- | arch/sparc/kernel/entry.S | 2 | ||||
-rw-r--r-- | arch/sparc/kernel/kgdb_64.c | 4 | ||||
-rw-r--r-- | arch/sparc/kernel/ktlb.S | 3 | ||||
-rw-r--r-- | arch/sparc/kernel/ptrace_64.c | 4 | ||||
-rw-r--r-- | arch/sparc/kernel/setup_64.c | 12 | ||||
-rw-r--r-- | arch/sparc/kernel/syscalls.S | 12 | ||||
-rw-r--r-- | arch/sparc/kernel/trampoline_64.S | 2 | ||||
-rw-r--r-- | arch/sparc/lib/ksyms.c | 9 | ||||
-rw-r--r-- | drivers/scsi/esp_scsi.c | 14 | ||||
-rw-r--r-- | drivers/scsi/esp_scsi.h | 1 | ||||
-rw-r--r-- | fs/proc/inode.c | 16 |
13 files changed, 49 insertions, 35 deletions
diff --git a/arch/sparc/include/asm/switch_to_64.h b/arch/sparc/include/asm/switch_to_64.h index c7de3323819c..8d284801f232 100644 --- a/arch/sparc/include/asm/switch_to_64.h +++ b/arch/sparc/include/asm/switch_to_64.h | |||
@@ -48,8 +48,8 @@ do { save_and_clear_fpu(); \ | |||
48 | "wrpr %%g0, 14, %%pil\n\t" \ | 48 | "wrpr %%g0, 14, %%pil\n\t" \ |
49 | "brz,pt %%o7, switch_to_pc\n\t" \ | 49 | "brz,pt %%o7, switch_to_pc\n\t" \ |
50 | " mov %%g7, %0\n\t" \ | 50 | " mov %%g7, %0\n\t" \ |
51 | "sethi %%hi(ret_from_syscall), %%g1\n\t" \ | 51 | "sethi %%hi(ret_from_fork), %%g1\n\t" \ |
52 | "jmpl %%g1 + %%lo(ret_from_syscall), %%g0\n\t" \ | 52 | "jmpl %%g1 + %%lo(ret_from_fork), %%g0\n\t" \ |
53 | " nop\n\t" \ | 53 | " nop\n\t" \ |
54 | ".globl switch_to_pc\n\t" \ | 54 | ".globl switch_to_pc\n\t" \ |
55 | "switch_to_pc:\n\t" \ | 55 | "switch_to_pc:\n\t" \ |
diff --git a/arch/sparc/kernel/cpumap.c b/arch/sparc/kernel/cpumap.c index e4de74c2c9b0..cb5d272d658a 100644 --- a/arch/sparc/kernel/cpumap.c +++ b/arch/sparc/kernel/cpumap.c | |||
@@ -327,6 +327,7 @@ static int iterate_cpu(struct cpuinfo_tree *t, unsigned int root_index) | |||
327 | case SUN4V_CHIP_NIAGARA3: | 327 | case SUN4V_CHIP_NIAGARA3: |
328 | case SUN4V_CHIP_NIAGARA4: | 328 | case SUN4V_CHIP_NIAGARA4: |
329 | case SUN4V_CHIP_NIAGARA5: | 329 | case SUN4V_CHIP_NIAGARA5: |
330 | case SUN4V_CHIP_SPARC64X: | ||
330 | rover_inc_table = niagara_iterate_method; | 331 | rover_inc_table = niagara_iterate_method; |
331 | break; | 332 | break; |
332 | default: | 333 | default: |
diff --git a/arch/sparc/kernel/entry.S b/arch/sparc/kernel/entry.S index e2a030045089..33c02b15f478 100644 --- a/arch/sparc/kernel/entry.S +++ b/arch/sparc/kernel/entry.S | |||
@@ -839,7 +839,7 @@ sys_sigreturn: | |||
839 | nop | 839 | nop |
840 | 840 | ||
841 | call syscall_trace | 841 | call syscall_trace |
842 | nop | 842 | mov 1, %o1 |
843 | 843 | ||
844 | 1: | 844 | 1: |
845 | /* We don't want to muck with user registers like a | 845 | /* We don't want to muck with user registers like a |
diff --git a/arch/sparc/kernel/kgdb_64.c b/arch/sparc/kernel/kgdb_64.c index c8759550799f..53c0a82e6030 100644 --- a/arch/sparc/kernel/kgdb_64.c +++ b/arch/sparc/kernel/kgdb_64.c | |||
@@ -42,7 +42,7 @@ void sleeping_thread_to_gdb_regs(unsigned long *gdb_regs, struct task_struct *p) | |||
42 | { | 42 | { |
43 | struct thread_info *t = task_thread_info(p); | 43 | struct thread_info *t = task_thread_info(p); |
44 | extern unsigned int switch_to_pc; | 44 | extern unsigned int switch_to_pc; |
45 | extern unsigned int ret_from_syscall; | 45 | extern unsigned int ret_from_fork; |
46 | struct reg_window *win; | 46 | struct reg_window *win; |
47 | unsigned long pc, cwp; | 47 | unsigned long pc, cwp; |
48 | int i; | 48 | int i; |
@@ -66,7 +66,7 @@ void sleeping_thread_to_gdb_regs(unsigned long *gdb_regs, struct task_struct *p) | |||
66 | gdb_regs[i] = 0; | 66 | gdb_regs[i] = 0; |
67 | 67 | ||
68 | if (t->new_child) | 68 | if (t->new_child) |
69 | pc = (unsigned long) &ret_from_syscall; | 69 | pc = (unsigned long) &ret_from_fork; |
70 | else | 70 | else |
71 | pc = (unsigned long) &switch_to_pc; | 71 | pc = (unsigned long) &switch_to_pc; |
72 | 72 | ||
diff --git a/arch/sparc/kernel/ktlb.S b/arch/sparc/kernel/ktlb.S index 0746e5e32b37..fde5a419cf27 100644 --- a/arch/sparc/kernel/ktlb.S +++ b/arch/sparc/kernel/ktlb.S | |||
@@ -25,11 +25,10 @@ kvmap_itlb: | |||
25 | */ | 25 | */ |
26 | kvmap_itlb_4v: | 26 | kvmap_itlb_4v: |
27 | 27 | ||
28 | kvmap_itlb_nonlinear: | ||
29 | /* Catch kernel NULL pointer calls. */ | 28 | /* Catch kernel NULL pointer calls. */ |
30 | sethi %hi(PAGE_SIZE), %g5 | 29 | sethi %hi(PAGE_SIZE), %g5 |
31 | cmp %g4, %g5 | 30 | cmp %g4, %g5 |
32 | bleu,pn %xcc, kvmap_dtlb_longpath | 31 | blu,pn %xcc, kvmap_itlb_longpath |
33 | nop | 32 | nop |
34 | 33 | ||
35 | KERN_TSB_LOOKUP_TL1(%g4, %g6, %g5, %g1, %g2, %g3, kvmap_itlb_load) | 34 | KERN_TSB_LOOKUP_TL1(%g4, %g6, %g5, %g1, %g2, %g3, kvmap_itlb_load) |
diff --git a/arch/sparc/kernel/ptrace_64.c b/arch/sparc/kernel/ptrace_64.c index 7ff45e4ba681..773c1f2983ce 100644 --- a/arch/sparc/kernel/ptrace_64.c +++ b/arch/sparc/kernel/ptrace_64.c | |||
@@ -14,6 +14,7 @@ | |||
14 | #include <linux/sched.h> | 14 | #include <linux/sched.h> |
15 | #include <linux/mm.h> | 15 | #include <linux/mm.h> |
16 | #include <linux/errno.h> | 16 | #include <linux/errno.h> |
17 | #include <linux/export.h> | ||
17 | #include <linux/ptrace.h> | 18 | #include <linux/ptrace.h> |
18 | #include <linux/user.h> | 19 | #include <linux/user.h> |
19 | #include <linux/smp.h> | 20 | #include <linux/smp.h> |
@@ -116,6 +117,7 @@ void flush_ptrace_access(struct vm_area_struct *vma, struct page *page, | |||
116 | 117 | ||
117 | preempt_enable(); | 118 | preempt_enable(); |
118 | } | 119 | } |
120 | EXPORT_SYMBOL_GPL(flush_ptrace_access); | ||
119 | 121 | ||
120 | static int get_from_target(struct task_struct *target, unsigned long uaddr, | 122 | static int get_from_target(struct task_struct *target, unsigned long uaddr, |
121 | void *kbuf, int len) | 123 | void *kbuf, int len) |
@@ -1087,7 +1089,7 @@ asmlinkage void syscall_trace_leave(struct pt_regs *regs) | |||
1087 | audit_syscall_exit(regs); | 1089 | audit_syscall_exit(regs); |
1088 | 1090 | ||
1089 | if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT))) | 1091 | if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT))) |
1090 | trace_sys_exit(regs, regs->u_regs[UREG_G1]); | 1092 | trace_sys_exit(regs, regs->u_regs[UREG_I0]); |
1091 | 1093 | ||
1092 | if (test_thread_flag(TIF_SYSCALL_TRACE)) | 1094 | if (test_thread_flag(TIF_SYSCALL_TRACE)) |
1093 | tracehook_report_syscall_exit(regs, 0); | 1095 | tracehook_report_syscall_exit(regs, 0); |
diff --git a/arch/sparc/kernel/setup_64.c b/arch/sparc/kernel/setup_64.c index 13785547e435..3fdb455e3318 100644 --- a/arch/sparc/kernel/setup_64.c +++ b/arch/sparc/kernel/setup_64.c | |||
@@ -499,12 +499,14 @@ static void __init init_sparc64_elf_hwcap(void) | |||
499 | sun4v_chip_type == SUN4V_CHIP_NIAGARA2 || | 499 | sun4v_chip_type == SUN4V_CHIP_NIAGARA2 || |
500 | sun4v_chip_type == SUN4V_CHIP_NIAGARA3 || | 500 | sun4v_chip_type == SUN4V_CHIP_NIAGARA3 || |
501 | sun4v_chip_type == SUN4V_CHIP_NIAGARA4 || | 501 | sun4v_chip_type == SUN4V_CHIP_NIAGARA4 || |
502 | sun4v_chip_type == SUN4V_CHIP_NIAGARA5) | 502 | sun4v_chip_type == SUN4V_CHIP_NIAGARA5 || |
503 | sun4v_chip_type == SUN4V_CHIP_SPARC64X) | ||
503 | cap |= HWCAP_SPARC_BLKINIT; | 504 | cap |= HWCAP_SPARC_BLKINIT; |
504 | if (sun4v_chip_type == SUN4V_CHIP_NIAGARA2 || | 505 | if (sun4v_chip_type == SUN4V_CHIP_NIAGARA2 || |
505 | sun4v_chip_type == SUN4V_CHIP_NIAGARA3 || | 506 | sun4v_chip_type == SUN4V_CHIP_NIAGARA3 || |
506 | sun4v_chip_type == SUN4V_CHIP_NIAGARA4 || | 507 | sun4v_chip_type == SUN4V_CHIP_NIAGARA4 || |
507 | sun4v_chip_type == SUN4V_CHIP_NIAGARA5) | 508 | sun4v_chip_type == SUN4V_CHIP_NIAGARA5 || |
509 | sun4v_chip_type == SUN4V_CHIP_SPARC64X) | ||
508 | cap |= HWCAP_SPARC_N2; | 510 | cap |= HWCAP_SPARC_N2; |
509 | } | 511 | } |
510 | 512 | ||
@@ -530,13 +532,15 @@ static void __init init_sparc64_elf_hwcap(void) | |||
530 | if (sun4v_chip_type == SUN4V_CHIP_NIAGARA2 || | 532 | if (sun4v_chip_type == SUN4V_CHIP_NIAGARA2 || |
531 | sun4v_chip_type == SUN4V_CHIP_NIAGARA3 || | 533 | sun4v_chip_type == SUN4V_CHIP_NIAGARA3 || |
532 | sun4v_chip_type == SUN4V_CHIP_NIAGARA4 || | 534 | sun4v_chip_type == SUN4V_CHIP_NIAGARA4 || |
533 | sun4v_chip_type == SUN4V_CHIP_NIAGARA5) | 535 | sun4v_chip_type == SUN4V_CHIP_NIAGARA5 || |
536 | sun4v_chip_type == SUN4V_CHIP_SPARC64X) | ||
534 | cap |= (AV_SPARC_VIS | AV_SPARC_VIS2 | | 537 | cap |= (AV_SPARC_VIS | AV_SPARC_VIS2 | |
535 | AV_SPARC_ASI_BLK_INIT | | 538 | AV_SPARC_ASI_BLK_INIT | |
536 | AV_SPARC_POPC); | 539 | AV_SPARC_POPC); |
537 | if (sun4v_chip_type == SUN4V_CHIP_NIAGARA3 || | 540 | if (sun4v_chip_type == SUN4V_CHIP_NIAGARA3 || |
538 | sun4v_chip_type == SUN4V_CHIP_NIAGARA4 || | 541 | sun4v_chip_type == SUN4V_CHIP_NIAGARA4 || |
539 | sun4v_chip_type == SUN4V_CHIP_NIAGARA5) | 542 | sun4v_chip_type == SUN4V_CHIP_NIAGARA5 || |
543 | sun4v_chip_type == SUN4V_CHIP_SPARC64X) | ||
540 | cap |= (AV_SPARC_VIS3 | AV_SPARC_HPC | | 544 | cap |= (AV_SPARC_VIS3 | AV_SPARC_HPC | |
541 | AV_SPARC_FMAF); | 545 | AV_SPARC_FMAF); |
542 | } | 546 | } |
diff --git a/arch/sparc/kernel/syscalls.S b/arch/sparc/kernel/syscalls.S index 22a1098961f5..d950197a17e1 100644 --- a/arch/sparc/kernel/syscalls.S +++ b/arch/sparc/kernel/syscalls.S | |||
@@ -98,8 +98,8 @@ sys_clone: | |||
98 | ba,pt %xcc, sparc_do_fork | 98 | ba,pt %xcc, sparc_do_fork |
99 | add %sp, PTREGS_OFF, %o2 | 99 | add %sp, PTREGS_OFF, %o2 |
100 | 100 | ||
101 | .globl ret_from_syscall | 101 | .globl ret_from_fork |
102 | ret_from_syscall: | 102 | ret_from_fork: |
103 | /* Clear current_thread_info()->new_child. */ | 103 | /* Clear current_thread_info()->new_child. */ |
104 | stb %g0, [%g6 + TI_NEW_CHILD] | 104 | stb %g0, [%g6 + TI_NEW_CHILD] |
105 | call schedule_tail | 105 | call schedule_tail |
@@ -152,7 +152,7 @@ linux_syscall_trace32: | |||
152 | srl %i4, 0, %o4 | 152 | srl %i4, 0, %o4 |
153 | srl %i1, 0, %o1 | 153 | srl %i1, 0, %o1 |
154 | srl %i2, 0, %o2 | 154 | srl %i2, 0, %o2 |
155 | ba,pt %xcc, 2f | 155 | ba,pt %xcc, 5f |
156 | srl %i3, 0, %o3 | 156 | srl %i3, 0, %o3 |
157 | 157 | ||
158 | linux_syscall_trace: | 158 | linux_syscall_trace: |
@@ -182,13 +182,13 @@ linux_sparc_syscall32: | |||
182 | srl %i1, 0, %o1 ! IEU0 Group | 182 | srl %i1, 0, %o1 ! IEU0 Group |
183 | ldx [%g6 + TI_FLAGS], %l0 ! Load | 183 | ldx [%g6 + TI_FLAGS], %l0 ! Load |
184 | 184 | ||
185 | srl %i5, 0, %o5 ! IEU1 | 185 | srl %i3, 0, %o3 ! IEU0 |
186 | srl %i2, 0, %o2 ! IEU0 Group | 186 | srl %i2, 0, %o2 ! IEU0 Group |
187 | andcc %l0, (_TIF_SYSCALL_TRACE|_TIF_SECCOMP|_TIF_SYSCALL_AUDIT|_TIF_SYSCALL_TRACEPOINT), %g0 | 187 | andcc %l0, (_TIF_SYSCALL_TRACE|_TIF_SECCOMP|_TIF_SYSCALL_AUDIT|_TIF_SYSCALL_TRACEPOINT), %g0 |
188 | bne,pn %icc, linux_syscall_trace32 ! CTI | 188 | bne,pn %icc, linux_syscall_trace32 ! CTI |
189 | mov %i0, %l5 ! IEU1 | 189 | mov %i0, %l5 ! IEU1 |
190 | call %l7 ! CTI Group brk forced | 190 | 5: call %l7 ! CTI Group brk forced |
191 | srl %i3, 0, %o3 ! IEU0 | 191 | srl %i5, 0, %o5 ! IEU1 |
192 | ba,a,pt %xcc, 3f | 192 | ba,a,pt %xcc, 3f |
193 | 193 | ||
194 | /* Linux native system calls enter here... */ | 194 | /* Linux native system calls enter here... */ |
diff --git a/arch/sparc/kernel/trampoline_64.S b/arch/sparc/kernel/trampoline_64.S index e0b1e13a0736..ad4bde3bb61e 100644 --- a/arch/sparc/kernel/trampoline_64.S +++ b/arch/sparc/kernel/trampoline_64.S | |||
@@ -129,7 +129,6 @@ startup_continue: | |||
129 | clr %l5 | 129 | clr %l5 |
130 | sethi %hi(num_kernel_image_mappings), %l6 | 130 | sethi %hi(num_kernel_image_mappings), %l6 |
131 | lduw [%l6 + %lo(num_kernel_image_mappings)], %l6 | 131 | lduw [%l6 + %lo(num_kernel_image_mappings)], %l6 |
132 | add %l6, 1, %l6 | ||
133 | 132 | ||
134 | mov 15, %l7 | 133 | mov 15, %l7 |
135 | BRANCH_IF_ANY_CHEETAH(g1,g5,2f) | 134 | BRANCH_IF_ANY_CHEETAH(g1,g5,2f) |
@@ -222,7 +221,6 @@ niagara_lock_tlb: | |||
222 | clr %l5 | 221 | clr %l5 |
223 | sethi %hi(num_kernel_image_mappings), %l6 | 222 | sethi %hi(num_kernel_image_mappings), %l6 |
224 | lduw [%l6 + %lo(num_kernel_image_mappings)], %l6 | 223 | lduw [%l6 + %lo(num_kernel_image_mappings)], %l6 |
225 | add %l6, 1, %l6 | ||
226 | 224 | ||
227 | 1: | 225 | 1: |
228 | mov HV_FAST_MMU_MAP_PERM_ADDR, %o5 | 226 | mov HV_FAST_MMU_MAP_PERM_ADDR, %o5 |
diff --git a/arch/sparc/lib/ksyms.c b/arch/sparc/lib/ksyms.c index 0c4e35e522fa..323335b9cd2b 100644 --- a/arch/sparc/lib/ksyms.c +++ b/arch/sparc/lib/ksyms.c | |||
@@ -98,15 +98,6 @@ EXPORT_SYMBOL(___copy_from_user); | |||
98 | EXPORT_SYMBOL(___copy_in_user); | 98 | EXPORT_SYMBOL(___copy_in_user); |
99 | EXPORT_SYMBOL(__clear_user); | 99 | EXPORT_SYMBOL(__clear_user); |
100 | 100 | ||
101 | /* RW semaphores */ | ||
102 | EXPORT_SYMBOL(__down_read); | ||
103 | EXPORT_SYMBOL(__down_read_trylock); | ||
104 | EXPORT_SYMBOL(__down_write); | ||
105 | EXPORT_SYMBOL(__down_write_trylock); | ||
106 | EXPORT_SYMBOL(__up_read); | ||
107 | EXPORT_SYMBOL(__up_write); | ||
108 | EXPORT_SYMBOL(__downgrade_write); | ||
109 | |||
110 | /* Atomic counter implementation. */ | 101 | /* Atomic counter implementation. */ |
111 | EXPORT_SYMBOL(atomic_add); | 102 | EXPORT_SYMBOL(atomic_add); |
112 | EXPORT_SYMBOL(atomic_add_ret); | 103 | EXPORT_SYMBOL(atomic_add_ret); |
diff --git a/drivers/scsi/esp_scsi.c b/drivers/scsi/esp_scsi.c index 34552bf1c023..55548dc5cec3 100644 --- a/drivers/scsi/esp_scsi.c +++ b/drivers/scsi/esp_scsi.c | |||
@@ -530,7 +530,7 @@ static int esp_need_to_nego_sync(struct esp_target_data *tp) | |||
530 | static int esp_alloc_lun_tag(struct esp_cmd_entry *ent, | 530 | static int esp_alloc_lun_tag(struct esp_cmd_entry *ent, |
531 | struct esp_lun_data *lp) | 531 | struct esp_lun_data *lp) |
532 | { | 532 | { |
533 | if (!ent->tag[0]) { | 533 | if (!ent->orig_tag[0]) { |
534 | /* Non-tagged, slot already taken? */ | 534 | /* Non-tagged, slot already taken? */ |
535 | if (lp->non_tagged_cmd) | 535 | if (lp->non_tagged_cmd) |
536 | return -EBUSY; | 536 | return -EBUSY; |
@@ -564,9 +564,9 @@ static int esp_alloc_lun_tag(struct esp_cmd_entry *ent, | |||
564 | return -EBUSY; | 564 | return -EBUSY; |
565 | } | 565 | } |
566 | 566 | ||
567 | BUG_ON(lp->tagged_cmds[ent->tag[1]]); | 567 | BUG_ON(lp->tagged_cmds[ent->orig_tag[1]]); |
568 | 568 | ||
569 | lp->tagged_cmds[ent->tag[1]] = ent; | 569 | lp->tagged_cmds[ent->orig_tag[1]] = ent; |
570 | lp->num_tagged++; | 570 | lp->num_tagged++; |
571 | 571 | ||
572 | return 0; | 572 | return 0; |
@@ -575,9 +575,9 @@ static int esp_alloc_lun_tag(struct esp_cmd_entry *ent, | |||
575 | static void esp_free_lun_tag(struct esp_cmd_entry *ent, | 575 | static void esp_free_lun_tag(struct esp_cmd_entry *ent, |
576 | struct esp_lun_data *lp) | 576 | struct esp_lun_data *lp) |
577 | { | 577 | { |
578 | if (ent->tag[0]) { | 578 | if (ent->orig_tag[0]) { |
579 | BUG_ON(lp->tagged_cmds[ent->tag[1]] != ent); | 579 | BUG_ON(lp->tagged_cmds[ent->orig_tag[1]] != ent); |
580 | lp->tagged_cmds[ent->tag[1]] = NULL; | 580 | lp->tagged_cmds[ent->orig_tag[1]] = NULL; |
581 | lp->num_tagged--; | 581 | lp->num_tagged--; |
582 | } else { | 582 | } else { |
583 | BUG_ON(lp->non_tagged_cmd != ent); | 583 | BUG_ON(lp->non_tagged_cmd != ent); |
@@ -667,6 +667,8 @@ static struct esp_cmd_entry *find_and_prep_issuable_command(struct esp *esp) | |||
667 | ent->tag[0] = 0; | 667 | ent->tag[0] = 0; |
668 | ent->tag[1] = 0; | 668 | ent->tag[1] = 0; |
669 | } | 669 | } |
670 | ent->orig_tag[0] = ent->tag[0]; | ||
671 | ent->orig_tag[1] = ent->tag[1]; | ||
670 | 672 | ||
671 | if (esp_alloc_lun_tag(ent, lp) < 0) | 673 | if (esp_alloc_lun_tag(ent, lp) < 0) |
672 | continue; | 674 | continue; |
diff --git a/drivers/scsi/esp_scsi.h b/drivers/scsi/esp_scsi.h index 28e22acf87ea..cd68805e8d78 100644 --- a/drivers/scsi/esp_scsi.h +++ b/drivers/scsi/esp_scsi.h | |||
@@ -271,6 +271,7 @@ struct esp_cmd_entry { | |||
271 | #define ESP_CMD_FLAG_AUTOSENSE 0x04 /* Doing automatic REQUEST_SENSE */ | 271 | #define ESP_CMD_FLAG_AUTOSENSE 0x04 /* Doing automatic REQUEST_SENSE */ |
272 | 272 | ||
273 | u8 tag[2]; | 273 | u8 tag[2]; |
274 | u8 orig_tag[2]; | ||
274 | 275 | ||
275 | u8 status; | 276 | u8 status; |
276 | u8 message; | 277 | u8 message; |
diff --git a/fs/proc/inode.c b/fs/proc/inode.c index 073aea60cf8f..9f8ef9b7674d 100644 --- a/fs/proc/inode.c +++ b/fs/proc/inode.c | |||
@@ -285,6 +285,20 @@ static int proc_reg_mmap(struct file *file, struct vm_area_struct *vma) | |||
285 | return rv; | 285 | return rv; |
286 | } | 286 | } |
287 | 287 | ||
288 | static unsigned long proc_reg_get_unmapped_area(struct file *file, unsigned long orig_addr, unsigned long len, unsigned long pgoff, unsigned long flags) | ||
289 | { | ||
290 | struct proc_dir_entry *pde = PDE(file_inode(file)); | ||
291 | int rv = -EIO; | ||
292 | unsigned long (*get_unmapped_area)(struct file *, unsigned long, unsigned long, unsigned long, unsigned long); | ||
293 | if (use_pde(pde)) { | ||
294 | get_unmapped_area = pde->proc_fops->get_unmapped_area; | ||
295 | if (get_unmapped_area) | ||
296 | rv = get_unmapped_area(file, orig_addr, len, pgoff, flags); | ||
297 | unuse_pde(pde); | ||
298 | } | ||
299 | return rv; | ||
300 | } | ||
301 | |||
288 | static int proc_reg_open(struct inode *inode, struct file *file) | 302 | static int proc_reg_open(struct inode *inode, struct file *file) |
289 | { | 303 | { |
290 | struct proc_dir_entry *pde = PDE(inode); | 304 | struct proc_dir_entry *pde = PDE(inode); |
@@ -356,6 +370,7 @@ static const struct file_operations proc_reg_file_ops = { | |||
356 | .compat_ioctl = proc_reg_compat_ioctl, | 370 | .compat_ioctl = proc_reg_compat_ioctl, |
357 | #endif | 371 | #endif |
358 | .mmap = proc_reg_mmap, | 372 | .mmap = proc_reg_mmap, |
373 | .get_unmapped_area = proc_reg_get_unmapped_area, | ||
359 | .open = proc_reg_open, | 374 | .open = proc_reg_open, |
360 | .release = proc_reg_release, | 375 | .release = proc_reg_release, |
361 | }; | 376 | }; |
@@ -368,6 +383,7 @@ static const struct file_operations proc_reg_file_ops_no_compat = { | |||
368 | .poll = proc_reg_poll, | 383 | .poll = proc_reg_poll, |
369 | .unlocked_ioctl = proc_reg_unlocked_ioctl, | 384 | .unlocked_ioctl = proc_reg_unlocked_ioctl, |
370 | .mmap = proc_reg_mmap, | 385 | .mmap = proc_reg_mmap, |
386 | .get_unmapped_area = proc_reg_get_unmapped_area, | ||
371 | .open = proc_reg_open, | 387 | .open = proc_reg_open, |
372 | .release = proc_reg_release, | 388 | .release = proc_reg_release, |
373 | }; | 389 | }; |