/arch/s390/include/asm/ |
D | rwsem.h | 54 signed long old, new; in __down_read() local 62 : "=&d" (old), "=&d" (new), "=Q" (sem->count) in __down_read() 74 signed long old, new; in __down_read_trylock() local 84 : "=&d" (old), "=&d" (new), "=Q" (sem->count) in __down_read_trylock() 95 signed long old, new, tmp; in ___down_write() local 104 : "=&d" (old), "=&d" (new), "=Q" (sem->count) in ___down_write() 151 signed long old, new; in __up_read() local 159 : "=&d" (old), "=&d" (new), "=Q" (sem->count) in __up_read() 162 if (new < 0) in __up_read() 163 if ((new & RWSEM_ACTIVE_MASK) == 0) in __up_read() [all …]
|
/arch/sparc/kernel/ |
D | ftrace.c | 25 static int ftrace_modify_code(unsigned long ip, u32 old, u32 new) in ftrace_modify_code() argument 46 : [new] "0" (new), [old] "r" (old), [ip] "r" (ip) in ftrace_modify_code() 49 if (replaced != old && replaced != new) in ftrace_modify_code() 58 u32 old, new; in ftrace_make_nop() local 61 new = ftrace_nop; in ftrace_make_nop() 62 return ftrace_modify_code(ip, old, new); in ftrace_make_nop() 68 u32 old, new; in ftrace_make_call() local 71 new = ftrace_call_replace(ip, addr); in ftrace_make_call() 72 return ftrace_modify_code(ip, old, new); in ftrace_make_call() 78 u32 old, new; in ftrace_update_ftrace_func() local [all …]
|
/arch/avr32/include/asm/ |
D | cmpxchg.h | 47 unsigned long new) in __cmpxchg_u32() argument 60 : "m"(m), [old] "Ks21r"(old), [new] "r"(new) in __cmpxchg_u32() 66 volatile int * m, unsigned long old, unsigned long new); 74 unsigned long new, int size) in __cmpxchg() argument 78 return __cmpxchg_u32(ptr, old, new); in __cmpxchg() 80 return __cmpxchg_u64(ptr, old, new); in __cmpxchg() 87 #define cmpxchg(ptr, old, new) \ argument 89 (unsigned long)(new), \ 96 unsigned long new, int size) in __cmpxchg_local() argument 100 return __cmpxchg_u32(ptr, old, new); in __cmpxchg_local() [all …]
|
/arch/powerpc/include/asm/ |
D | cmpxchg.h | 135 __cmpxchg_u32(volatile unsigned int *p, unsigned long old, unsigned long new) in __cmpxchg_u32() argument 151 : "r" (p), "r" (old), "r" (new) in __cmpxchg_u32() 159 unsigned long new) in __cmpxchg_u32_local() argument 173 : "r" (p), "r" (old), "r" (new) in __cmpxchg_u32_local() 180 __cmpxchg_u32_relaxed(u32 *p, unsigned long old, unsigned long new) in __cmpxchg_u32_relaxed() argument 193 : "r" (p), "r" (old), "r" (new) in __cmpxchg_u32_relaxed() 208 __cmpxchg_u32_acquire(u32 *p, unsigned long old, unsigned long new) in __cmpxchg_u32_acquire() argument 223 : "r" (p), "r" (old), "r" (new) in __cmpxchg_u32_acquire() 231 __cmpxchg_u64(volatile unsigned long *p, unsigned long old, unsigned long new) in __cmpxchg_u64() argument 246 : "r" (p), "r" (old), "r" (new) in __cmpxchg_u64() [all …]
|
/arch/arm/kernel/ |
D | ftrace.c | 104 unsigned long new, bool validate) in ftrace_modify_code() argument 110 new = __opcode_to_mem_thumb32(new); in ftrace_modify_code() 113 new = __opcode_to_mem_arm(new); in ftrace_modify_code() 124 if (probe_kernel_write((void *)pc, &new, MCOUNT_INSN_SIZE)) in ftrace_modify_code() 135 unsigned long new; in ftrace_update_ftrace_func() local 139 new = ftrace_call_replace(pc, (unsigned long)func); in ftrace_update_ftrace_func() 141 ret = ftrace_modify_code(pc, 0, new, false); in ftrace_update_ftrace_func() 146 new = ftrace_call_replace(pc, (unsigned long)func); in ftrace_update_ftrace_func() 148 ret = ftrace_modify_code(pc, 0, new, false); in ftrace_update_ftrace_func() 157 unsigned long new, old; in ftrace_make_call() local [all …]
|
/arch/sparc/include/asm/ |
D | cmpxchg_64.h | 69 __cmpxchg_u32(volatile int *m, int old, int new) in __cmpxchg_u32() argument 72 : "=&r" (new) in __cmpxchg_u32() 73 : "0" (new), "r" (m), "r" (old) in __cmpxchg_u32() 76 return new; in __cmpxchg_u32() 80 __cmpxchg_u64(volatile long *m, unsigned long old, unsigned long new) in __cmpxchg_u64() argument 83 : "=&r" (new) in __cmpxchg_u64() 84 : "0" (new), "r" (m), "r" (old) in __cmpxchg_u64() 87 return new; in __cmpxchg_u64() 95 __cmpxchg(volatile void *ptr, unsigned long old, unsigned long new, int size) in __cmpxchg() argument 99 return __cmpxchg_u32(ptr, old, new); in __cmpxchg() [all …]
|
/arch/alpha/include/asm/ |
D | xchg.h | 137 ____cmpxchg(_u8, volatile char *m, unsigned char old, unsigned char new) in ____cmpxchg() argument 157 : "=&r" (prev), "=&r" (new), "=&r" (tmp), "=&r" (cmp), "=&r" (addr64) in ____cmpxchg() 158 : "r" ((long)m), "Ir" (old), "1" (new) : "memory"); in ____cmpxchg() 164 ____cmpxchg(_u16, volatile short *m, unsigned short old, unsigned short new) in ____cmpxchg() argument 184 : "=&r" (prev), "=&r" (new), "=&r" (tmp), "=&r" (cmp), "=&r" (addr64) in ____cmpxchg() 185 : "r" ((long)m), "Ir" (old), "1" (new) : "memory"); in ____cmpxchg() 191 ____cmpxchg(_u32, volatile int *m, int old, int new) in ____cmpxchg() argument 208 : "r"((long) old), "r"(new), "m"(*m) : "memory"); in ____cmpxchg() 214 ____cmpxchg(_u64, volatile long *m, unsigned long old, unsigned long new) in ____cmpxchg() argument 231 : "r"((long) old), "r"(new), "m"(*m) : "memory"); in ____cmpxchg() [all …]
|
/arch/ia64/include/asm/ |
D | rwsem.h | 55 long old, new; in ___down_write() local 59 new = old + RWSEM_ACTIVE_WRITE_BIAS; in ___down_write() 60 } while (atomic_long_cmpxchg_acquire(&sem->count, old, new) != old); in ___down_write() 100 long old, new; in __up_write() local 104 new = old - RWSEM_ACTIVE_WRITE_BIAS; in __up_write() 105 } while (atomic_long_cmpxchg_release(&sem->count, old, new) != old); in __up_write() 107 if (new < 0 && (new & RWSEM_ACTIVE_MASK) == 0) in __up_write() 143 long old, new; in __downgrade_write() local 147 new = old - RWSEM_WAITING_BIAS; in __downgrade_write() 148 } while (atomic_long_cmpxchg_release(&sem->count, old, new) != old); in __downgrade_write()
|
D | bitops.h | 41 __u32 bit, old, new; in set_bit() local 50 new = old | bit; in set_bit() 51 } while (cmpxchg_acq(m, old, new) != old); in set_bit() 82 __u32 mask, old, new; in clear_bit() local 91 new = old & mask; in clear_bit() 92 } while (cmpxchg_acq(m, old, new) != old); in clear_bit() 106 __u32 mask, old, new; in clear_bit_unlock() local 115 new = old & mask; in clear_bit_unlock() 116 } while (cmpxchg_rel(m, old, new) != old); in clear_bit_unlock() 131 __u32 const new = *m & ~(1 << (nr & 31)); in __clear_bit_unlock() local [all …]
|
D | acenv.h | 25 unsigned int old, new, val; in ia64_acpi_acquire_global_lock() local 28 new = (((old & ~0x3) + 2) + ((old >> 1) & 0x1)); in ia64_acpi_acquire_global_lock() 29 val = ia64_cmpxchg4_acq(lock, new, old); in ia64_acpi_acquire_global_lock() 31 return (new < 3) ? -1 : 0; in ia64_acpi_acquire_global_lock() 37 unsigned int old, new, val; in ia64_acpi_release_global_lock() local 40 new = old & ~0x3; in ia64_acpi_release_global_lock() 41 val = ia64_cmpxchg4_acq(lock, new, old); in ia64_acpi_release_global_lock()
|
/arch/arm64/kernel/ |
D | ftrace.c | 25 static int ftrace_modify_code(unsigned long pc, u32 old, u32 new, in ftrace_modify_code() argument 45 if (aarch64_insn_patch_text_nosync((void *)pc, new)) in ftrace_modify_code() 57 u32 new; in ftrace_update_ftrace_func() local 60 new = aarch64_insn_gen_branch_imm(pc, (unsigned long)func, in ftrace_update_ftrace_func() 63 return ftrace_modify_code(pc, 0, new, false); in ftrace_update_ftrace_func() 72 u32 old, new; in ftrace_make_call() local 75 new = aarch64_insn_gen_branch_imm(pc, addr, AARCH64_INSN_BRANCH_LINK); in ftrace_make_call() 77 return ftrace_modify_code(pc, old, new, true); in ftrace_make_call() 87 u32 old, new; in ftrace_make_nop() local 90 new = aarch64_insn_gen_nop(); in ftrace_make_nop() [all …]
|
/arch/x86/include/asm/ |
D | cmpxchg.h | 84 #define __raw_cmpxchg(ptr, old, new, size, lock) \ argument 88 __typeof__(*(ptr)) __new = (new); \ 132 #define __cmpxchg(ptr, old, new, size) \ argument 133 __raw_cmpxchg((ptr), (old), (new), (size), LOCK_PREFIX) 135 #define __sync_cmpxchg(ptr, old, new, size) \ argument 136 __raw_cmpxchg((ptr), (old), (new), (size), "lock; ") 138 #define __cmpxchg_local(ptr, old, new, size) \ argument 139 __raw_cmpxchg((ptr), (old), (new), (size), "") 147 #define cmpxchg(ptr, old, new) \ argument 148 __cmpxchg(ptr, old, new, sizeof(*(ptr))) [all …]
|
/arch/metag/kernel/ |
D | ftrace.c | 85 unsigned char old[MCOUNT_INSN_SIZE], *new; in ftrace_update_ftrace_func() local 89 new = ftrace_call_replace(pc, (unsigned long)func); in ftrace_update_ftrace_func() 90 ret = ftrace_modify_code(pc, old, new); in ftrace_update_ftrace_func() 98 unsigned char *new, *old; in ftrace_make_nop() local 102 new = ftrace_nop_replace(); in ftrace_make_nop() 104 return ftrace_modify_code(ip, old, new); in ftrace_make_nop() 109 unsigned char *new, *old; in ftrace_make_call() local 113 new = ftrace_call_replace(ip, addr); in ftrace_make_call() 115 return ftrace_modify_code(ip, old, new); in ftrace_make_call()
|
/arch/tile/kernel/ |
D | ftrace.c | 102 unsigned long new) in ftrace_modify_code() argument 113 if (probe_kernel_write((void *)pc_wr, &new, MCOUNT_INSN_SIZE)) in ftrace_modify_code() 127 unsigned long new; in ftrace_update_ftrace_func() local 132 new = ftrace_call_replace(pc, (unsigned long)func); in ftrace_update_ftrace_func() 134 ret = ftrace_modify_code(pc, old, new); in ftrace_update_ftrace_func() 141 unsigned long new, old; in ftrace_make_call() local 145 new = ftrace_call_replace(ip, addr); in ftrace_make_call() 147 return ftrace_modify_code(rec->ip, old, new); in ftrace_make_call() 155 unsigned long new; in ftrace_make_nop() local 159 new = ftrace_nop_replace(rec); in ftrace_make_nop() [all …]
|
/arch/xtensa/include/asm/ |
D | cmpxchg.h | 23 __cmpxchg_u32(volatile int *p, int old, int new) in __cmpxchg_u32() argument 29 : "+a" (new) in __cmpxchg_u32() 34 return new; in __cmpxchg_u32() 45 : "a" (p), "a" (old), "r" (new) in __cmpxchg_u32() 56 __cmpxchg(volatile void *ptr, unsigned long old, unsigned long new, int size) in __cmpxchg() argument 59 case 4: return __cmpxchg_u32(ptr, old, new); in __cmpxchg() 76 unsigned long new, int size) in __cmpxchg_local() argument 80 return __cmpxchg_u32(ptr, old, new); in __cmpxchg_local() 82 return __cmpxchg_local_generic(ptr, old, new, size); in __cmpxchg_local()
|
/arch/s390/kernel/ |
D | ftrace.c | 107 struct ftrace_insn orig, new, old; in ftrace_make_nop() local 114 ftrace_generate_nop_insn(&new); in ftrace_make_nop() 124 ftrace_generate_kprobe_nop_insn(&new); in ftrace_make_nop() 128 ftrace_generate_nop_insn(&new); in ftrace_make_nop() 133 s390_kernel_write((void *) rec->ip, &new, sizeof(new)); in ftrace_make_nop() 139 struct ftrace_insn orig, new, old; in ftrace_make_call() local 152 ftrace_generate_kprobe_call_insn(&new); in ftrace_make_call() 156 ftrace_generate_call_insn(&new, rec->ip); in ftrace_make_call() 161 s390_kernel_write((void *) rec->ip, &new, sizeof(new)); in ftrace_make_call()
|
D | jump_label.c | 40 struct insn *new) in jump_label_bug() argument 44 unsigned char *ipn = (unsigned char *)new; in jump_label_bug() 62 struct insn old, new; in __jump_label_transform() local 66 jump_label_make_branch(entry, &new); in __jump_label_transform() 69 jump_label_make_nop(entry, &new); in __jump_label_transform() 73 jump_label_bug(entry, &orignop, &new); in __jump_label_transform() 76 jump_label_bug(entry, &old, &new); in __jump_label_transform() 78 s390_kernel_write((void *)entry->code, &new, sizeof(new)); in __jump_label_transform()
|
/arch/sh/drivers/ |
D | heartbeat.c | 37 unsigned int new; in heartbeat_toggle_bit() local 39 new = (1 << hd->bit_pos[bit]); in heartbeat_toggle_bit() 41 new = ~new; in heartbeat_toggle_bit() 43 new &= hd->mask; in heartbeat_toggle_bit() 47 new |= ioread32(hd->base) & ~hd->mask; in heartbeat_toggle_bit() 48 iowrite32(new, hd->base); in heartbeat_toggle_bit() 51 new |= ioread16(hd->base) & ~hd->mask; in heartbeat_toggle_bit() 52 iowrite16(new, hd->base); in heartbeat_toggle_bit() 55 new |= ioread8(hd->base) & ~hd->mask; in heartbeat_toggle_bit() 56 iowrite8(new, hd->base); in heartbeat_toggle_bit()
|
/arch/arc/include/asm/ |
D | cmpxchg.h | 20 __cmpxchg(volatile void *ptr, unsigned long expected, unsigned long new) in __cmpxchg() argument 39 "r"(new) /* can't be "ir". scond can't take LIMM for "b" */ in __cmpxchg() 50 __cmpxchg(volatile void *ptr, unsigned long expected, unsigned long new) in __cmpxchg() argument 62 *p = new; in __cmpxchg() 70 __cmpxchg(volatile void *ptr, unsigned long expected, unsigned long new) in __cmpxchg() argument 84 : "+r"(new) in __cmpxchg() 90 return new; in __cmpxchg() 219 #define atomic_xchg(v, new) (xchg(&((v)->counter), new)) argument
|
/arch/powerpc/mm/ |
D | vphn.c | 41 u16 new = be16_to_cpup(field++); in vphn_unpack_associativity() local 48 cpu_to_be32(last << 16 | new); in vphn_unpack_associativity() 50 } else if (new == VPHN_FIELD_UNUSED) in vphn_unpack_associativity() 53 else if (new & VPHN_FIELD_MSB) { in vphn_unpack_associativity() 56 cpu_to_be32(new & VPHN_FIELD_MASK); in vphn_unpack_associativity() 61 last = new; in vphn_unpack_associativity()
|
/arch/x86/um/ |
D | bugs_32.c | 24 struct sigaction old, new; in arch_check_bugs() local 27 new.sa_handler = cmov_sigill_test_handler; in arch_check_bugs() 30 new.sa_flags = SA_NODEFER; in arch_check_bugs() 31 sigemptyset(&new.sa_mask); in arch_check_bugs() 32 sigaction(SIGILL, &new, &old); in arch_check_bugs() 41 sigaction(SIGILL, &old, &new); in arch_check_bugs()
|
/arch/m32r/include/asm/ |
D | cmpxchg.h | 111 __cmpxchg_u32(volatile unsigned int *p, unsigned int old, unsigned int new) in __cmpxchg_u32() argument 129 : "r" (p), "r" (old), "r" (new) in __cmpxchg_u32() 142 unsigned int new) in __cmpxchg_local_u32() argument 160 : "r" (p), "r" (old), "r" (new) in __cmpxchg_local_u32() 176 __cmpxchg(volatile void *ptr, unsigned long old, unsigned long new, int size) in __cmpxchg() argument 180 return __cmpxchg_u32(ptr, old, new); in __cmpxchg() 183 return __cmpxchg_u64(ptr, old, new); in __cmpxchg() 198 unsigned long new, int size) in __cmpxchg_local() argument 202 return __cmpxchg_local_u32(ptr, old, new); in __cmpxchg_local() 204 return __cmpxchg_local_generic(ptr, old, new, size); in __cmpxchg_local()
|
/arch/x86/kernel/ |
D | ftrace.c | 140 unsigned const char *new, *old; in ftrace_make_nop() local 144 new = ftrace_nop_replace(); in ftrace_make_nop() 155 return ftrace_modify_code_direct(rec->ip, old, new); in ftrace_make_nop() 166 unsigned const char *new, *old; in ftrace_make_call() local 170 new = ftrace_call_replace(ip, addr); in ftrace_make_call() 173 return ftrace_modify_code_direct(rec->ip, old, new); in ftrace_make_call() 231 static int update_ftrace_func(unsigned long ip, void *new) in update_ftrace_func() argument 245 ret = ftrace_modify_code(ip, old, new); in update_ftrace_func() 255 unsigned char *new; in ftrace_update_ftrace_func() local 258 new = ftrace_call_replace(ip, (unsigned long)func); in ftrace_update_ftrace_func() [all …]
|
/arch/frv/include/asm/ |
D | cmpxchg.h | 78 extern uint64_t __cmpxchg_64(uint64_t test, uint64_t new, volatile uint64_t *v); 82 #define cmpxchg(ptr, test, new) \ argument 87 __typeof__(*(ptr)) __xg_new = (new); \ 120 extern uint32_t __cmpxchg_32(uint32_t *v, uint32_t test, uint32_t new); 122 #define cmpxchg(ptr, test, new) \ argument 127 __typeof__(*(ptr)) __xg_new = (new); \ 149 unsigned long new, int size) in __cmpxchg_local() argument 153 return cmpxchg((unsigned long *)ptr, old, new); in __cmpxchg_local() 155 return __cmpxchg_local_generic(ptr, old, new, size); in __cmpxchg_local()
|
/arch/s390/mm/ |
D | pageattr.c | 57 static void pgt_set(unsigned long *old, unsigned long new, unsigned long addr, in pgt_set() argument 76 crdte(*old, new, table, dtt, addr, S390_lowcore.kernel_asce); in pgt_set() 78 cspg(old, *old, new); in pgt_set() 80 csp((unsigned int *)old + 1, *old, new); in pgt_set() 92 pte_t *ptep, new; in walk_pte_level() local 99 new = pte_wrprotect(*ptep); in walk_pte_level() 101 new = pte_mkwrite(pte_mkdirty(*ptep)); in walk_pte_level() 102 pgt_set((unsigned long *)ptep, pte_val(new), addr, CRDTE_DTT_PAGE); in walk_pte_level() 114 pmd_t new; in split_pmd_page() local 129 pmd_val(new) = __pa(pt_dir) | _SEGMENT_ENTRY; in split_pmd_page() [all …]
|