/linux-4.4.14/net/ipv6/ |
D | protocol.c | 34 return !cmpxchg((const struct inet6_protocol **)&inet6_protos[protocol], in inet6_add_protocol() 43 ret = (cmpxchg((const struct inet6_protocol **)&inet6_protos[protocol], in inet6_del_protocol() 58 return !cmpxchg((const struct net_offload **)&inet6_offloads[protocol], in inet6_add_offload() 67 ret = (cmpxchg((const struct net_offload **)&inet6_offloads[protocol], in inet6_del_offload()
|
D | ip6_icmp.c | 15 return (cmpxchg((ip6_icmp_send_t **)&ip6_icmp_send, NULL, fn) == NULL) ? in inet6_register_icmp_sender() 24 ret = (cmpxchg((ip6_icmp_send_t **)&ip6_icmp_send, fn, NULL) == fn) ? in inet6_unregister_icmp_sender()
|
D | route.c | 1018 prev = cmpxchg(p, NULL, pcpu_rt); in rt6_make_pcpu_route()
|
/linux-4.4.14/net/ipv4/ |
D | protocol.c | 43 return !cmpxchg((const struct net_protocol **)&inet_protos[protocol], in inet_add_protocol() 50 return !cmpxchg((const struct net_offload **)&inet_offloads[protocol], in inet_add_offload() 59 ret = (cmpxchg((const struct net_protocol **)&inet_protos[protocol], in inet_del_protocol() 72 ret = (cmpxchg((const struct net_offload **)&inet_offloads[protocol], in inet_del_offload()
|
D | gre_demux.c | 40 return (cmpxchg((const struct gre_protocol **)&gre_proto[version], NULL, proto) == NULL) ? in gre_add_protocol() 52 ret = (cmpxchg((const struct gre_protocol **)&gre_proto[version], proto, NULL) == proto) ? in gre_del_protocol()
|
D | ip_tunnel.c | 530 return !cmpxchg((const struct ip_tunnel_encap_ops **) in ip_tunnel_encap_add_ops() 544 ret = (cmpxchg((const struct ip_tunnel_encap_ops **) in ip_tunnel_encap_del_ops()
|
D | route.c | 481 if (old != now && cmpxchg(p_tstamp, old, now) == old) in ip_idents_reserve() 1327 prev = cmpxchg(p, orig, rt); in rt_cache_route()
|
D | tcp_output.c | 804 } while (cmpxchg(&tp->tsq_flags, flags, nflags) != flags); in tcp_release_cb()
|
/linux-4.4.14/arch/s390/include/asm/ |
D | cmpxchg.h | 14 #define cmpxchg(ptr, o, n) \ macro 21 #define cmpxchg64 cmpxchg 22 #define cmpxchg_local cmpxchg 23 #define cmpxchg64_local cmpxchg
|
D | percpu.h | 37 prev__ = cmpxchg(ptr__, old__, new__); \ 140 ret__ = cmpxchg(ptr__, oval, nval); \
|
/linux-4.4.14/include/linux/ |
D | atomic.h | 359 #define cmpxchg_relaxed cmpxchg 360 #define cmpxchg_acquire cmpxchg 361 #define cmpxchg_release cmpxchg 367 __atomic_op_acquire(cmpxchg, __VA_ARGS__) 372 __atomic_op_release(cmpxchg, __VA_ARGS__) 375 #ifndef cmpxchg 376 #define cmpxchg(...) \ macro 377 __atomic_op_fence(cmpxchg, __VA_ARGS__)
|
D | bitops.h | 224 } while (cmpxchg(ptr, old, new) != old); \
|
D | kvm_host.h | 289 return cmpxchg(&vcpu->mode, IN_GUEST_MODE, EXITING_GUEST_MODE); in kvm_vcpu_exiting_guest_mode()
|
/linux-4.4.14/kernel/locking/ |
D | qspinlock_paravirt.h | 105 if (!cmpxchg(&he->lock, NULL, lock)) { in pv_hash() 194 cmpxchg(&pn->state, vcpu_halted, vcpu_running); in pv_wait_node() 230 if (cmpxchg(&pn->state, vcpu_halted, vcpu_hashed) != vcpu_halted) in pv_kick_node() 283 if (!cmpxchg(&l->locked, _Q_LOCKED_VAL, _Q_SLOW_VAL)) { in pv_wait_head() 325 locked = cmpxchg(&l->locked, _Q_LOCKED_VAL, 0); in __pv_queued_spin_unlock()
|
D | osq_lock.c | 140 cmpxchg(&prev->next, node, NULL) == node) in osq_lock()
|
/linux-4.4.14/kernel/ |
D | task_work.c | 36 } while (cmpxchg(&task->task_works, head, work) != head); in task_work_add() 71 else if (cmpxchg(pprev, work, work->next) == work) in task_work_cancel() 101 } while (cmpxchg(&task->task_works, work, head) != work); in task_work_run()
|
D | irq_work.c | 40 oflags = cmpxchg(&work->flags, flags, nflags); in irq_work_claim() 161 (void)cmpxchg(&work->flags, flags, flags & ~IRQ_WORK_BUSY); in irq_work_run_list()
|
D | acct.c | 174 cmpxchg(&acct->ns->bacct, pin, NULL); in acct_pin_kill()
|
D | watchdog.c | 901 } while (cmpxchg(&watchdog_enabled, old, new) != old); in proc_watchdog_common()
|
D | pid.c | 150 last_write = cmpxchg(&pid_ns->last_pid, prev, pid); in set_last_pid()
|
D | exit.c | 1014 if (cmpxchg(&p->exit_state, EXIT_ZOMBIE, state) != EXIT_ZOMBIE) in wait_task_zombie()
|
/linux-4.4.14/arch/tile/include/asm/ |
D | cmpxchg.h | 51 #define cmpxchg(ptr, o, n) \ macro 102 #define cmpxchg(ptr, o, n) \ macro 126 #define cmpxchg64 cmpxchg
|
D | bitops_64.h | 43 oldval = cmpxchg(addr, guess, guess ^ mask); in change_bit() 88 oldval = cmpxchg(addr, guess, guess ^ mask); in test_and_change_bit()
|
D | atomic_64.h | 56 oldval = cmpxchg(&v->counter, guess, guess + a); in __atomic_add_unless() 109 oldval = cmpxchg(&v->counter, guess, guess + a); in atomic64_add_unless()
|
D | atomic.h | 139 return cmpxchg(&v->counter, o, n); in atomic_cmpxchg()
|
/linux-4.4.14/arch/frv/include/asm/ |
D | cmpxchg.h | 84 #define cmpxchg(ptr, test, new) \ macro 124 #define cmpxchg(ptr, test, new) \ macro 155 return cmpxchg((unsigned long *)ptr, old, new); in __cmpxchg_local()
|
D | atomic.h | 164 #define atomic_cmpxchg(v, old, new) (cmpxchg(&(v)->counter, old, new))
|
/linux-4.4.14/lib/ |
D | llist.c | 45 } while (cmpxchg(&head->first, first, new_first) != first); in llist_add_batch() 75 entry = cmpxchg(&head->first, old_entry, next); in llist_del_first()
|
D | genalloc.c | 54 } while ((nval = cmpxchg(addr, val, val | mask_to_set)) != val); in set_bits_ll() 69 } while ((nval = cmpxchg(addr, val, val & ~mask_to_clear)) != val); in clear_bits_ll()
|
D | lru_cache.c | 71 val = cmpxchg(&lc->flags, 0, LC_LOCKED); in lc_try_lock() 82 val = cmpxchg(&lc->flags, old, new); in lc_try_lock()
|
/linux-4.4.14/include/asm-generic/ |
D | atomic.h | 48 while ((old = cmpxchg(&v->counter, c, c c_op i)) != c) \ 58 while ((old = cmpxchg(&v->counter, c, c c_op i)) != c) \ 177 #define atomic_cmpxchg(v, old, new) (cmpxchg(&((v)->counter), (old), (new)))
|
D | cputime_jiffies.h | 6 #define cmpxchg_cputime(ptr, old, new) cmpxchg(ptr, old, new)
|
D | cmpxchg.h | 105 #define cmpxchg(ptr, o, n) cmpxchg_local((ptr), (o), (n)) macro
|
/linux-4.4.14/drivers/gpu/drm/ |
D | drm_lock.c | 193 prev = cmpxchg(lock, old, new); in drm_lock_take() 236 prev = cmpxchg(lock, old, new); in drm_lock_transfer() 269 prev = cmpxchg(lock, old, new); in drm_legacy_lock_free() 323 prev = cmpxchg(lock, old, DRM_KERNEL_CONTEXT); in drm_legacy_idlelock_release()
|
/linux-4.4.14/arch/arc/include/asm/ |
D | cmpxchg.h | 69 #define cmpxchg(ptr, o, n) ((typeof(*(ptr)))__cmpxchg((ptr), \ macro 81 #define atomic_cmpxchg(v, o, n) ((int)cmpxchg(&((v)->counter), (o), (n)))
|
/linux-4.4.14/arch/alpha/include/asm/ |
D | cmpxchg.h | 52 #define cmpxchg(ptr, o, n) \ macro 63 cmpxchg((ptr), (o), (n)); \
|
D | rwsem.h | 61 res = cmpxchg(&sem->count, old, new); in __down_read_trylock() 95 long ret = cmpxchg(&sem->count, RWSEM_UNLOCKED_VALUE, in __down_write_trylock()
|
D | atomic.h | 131 #define atomic64_cmpxchg(v, old, new) (cmpxchg(&((v)->counter), old, new)) in ATOMIC_OPS() 134 #define atomic_cmpxchg(v, old, new) (cmpxchg(&((v)->counter), old, new)) in ATOMIC_OPS()
|
/linux-4.4.14/arch/xtensa/include/asm/ |
D | rwsem.h | 43 if (tmp == cmpxchg(&sem->count, tmp, in __down_read_trylock() 71 tmp = cmpxchg(&sem->count, RWSEM_UNLOCKED_VALUE, in __down_write_trylock()
|
D | cmpxchg.h | 65 #define cmpxchg(ptr,o,n) \ macro
|
D | atomic.h | 230 #define atomic_cmpxchg(v, o, n) ((int)cmpxchg(&((v)->counter), (o), (n))) in ATOMIC_OPS()
|
/linux-4.4.14/arch/sparc/include/asm/ |
D | rwsem.h | 37 if (tmp == cmpxchg(&sem->count, tmp, in __down_read_trylock() 67 tmp = cmpxchg(&sem->count, RWSEM_UNLOCKED_VALUE, in __down_write_trylock()
|
D | atomic_64.h | 76 #define atomic_cmpxchg(v, o, n) (cmpxchg(&((v)->counter), (o), (n))) in ATOMIC_OPS() 95 ((__typeof__((v)->counter))cmpxchg(&((v)->counter), (o), (n)))
|
D | cmpxchg_32.h | 57 #define cmpxchg(ptr, o, n) \ macro
|
D | cmpxchg_64.h | 107 #define cmpxchg(ptr,o,n) \ macro
|
/linux-4.4.14/arch/sh/include/asm/ |
D | rwsem.h | 38 if (tmp == cmpxchg(&sem->count, tmp, in __down_read_trylock() 66 tmp = cmpxchg(&sem->count, RWSEM_UNLOCKED_VALUE, in __down_write_trylock()
|
D | cmpxchg.h | 60 #define cmpxchg(ptr,o,n) \ macro
|
D | atomic.h | 39 #define atomic_cmpxchg(v, o, n) (cmpxchg(&((v)->counter), (o), (n)))
|
/linux-4.4.14/arch/blackfin/include/asm/ |
D | cmpxchg.h | 68 #define cmpxchg(ptr, o, n) \ macro 125 #define cmpxchg(ptr, o, n) cmpxchg_local((ptr), (o), (n)) macro
|
/linux-4.4.14/arch/tile/gxio/ |
D | dma_queue.c | 81 cmpxchg(&dma_queue->hw_complete_count, in __gxio_dma_queue_update_credits() 107 if (cmpxchg(&dma_queue->hw_complete_count, in __gxio_dma_queue_update_credits()
|
/linux-4.4.14/arch/ia64/include/uapi/asm/ |
D | cmpxchg.h | 129 #define cmpxchg(ptr, o, n) cmpxchg_acq((ptr), (o), (n)) macro 132 #define cmpxchg_local cmpxchg
|
D | Kbuild | 10 header-y += cmpxchg.h
|
/linux-4.4.14/Documentation/virtual/kvm/ |
D | locking.txt | 26 On fast page fault path, we will use cmpxchg to atomically set the spte W 28 is safe because whenever changing these bits can be detected by cmpxchg. 33 is not changed during cmpxchg. This is a ABA problem, for example, below case 55 if (cmpxchg(spte, old_spte, old_spte+W) 62 to gfn. For indirect sp, before we do cmpxchg, we call gfn_to_pfn_atomic()
|
/linux-4.4.14/arch/x86/include/asm/ |
D | cmpxchg_64.h | 12 cmpxchg((ptr), (o), (n)); \
|
D | spinlock.h | 84 cmpxchg(&lock->head_tail, old.head_tail, new.head_tail); in __ticket_check_and_clear_slowpath() 143 return cmpxchg(&lock->head_tail, old.head_tail, new.head_tail) == old.head_tail; in arch_spin_trylock()
|
D | atomic.h | 177 return cmpxchg(&v->counter, old, new); in atomic_cmpxchg()
|
D | atomic64_64.h | 166 return cmpxchg(&v->counter, old, new); in atomic64_cmpxchg()
|
D | cmpxchg.h | 146 #define cmpxchg(ptr, old, new) \ macro
|
/linux-4.4.14/arch/mips/include/asm/ |
D | cmpxchg.h | 227 #define cmpxchg(ptr, old, new) __cmpxchg(ptr, old, new, smp_mb__before_llsc(), smp_llsc_mb()) macro 240 cmpxchg((ptr), (o), (n)); \
|
D | atomic.h | 215 #define atomic_cmpxchg(v, o, n) (cmpxchg(&((v)->counter), (o), (n))) 500 ((__typeof__((v)->counter))cmpxchg(&((v)->counter), (o), (n)))
|
/linux-4.4.14/arch/powerpc/include/asm/ |
D | cmpxchg.h | 274 #define cmpxchg(ptr, o, n) \ macro 295 cmpxchg((ptr), (o), (n)); \
|
D | atomic.h | 158 #define atomic_cmpxchg(v, o, n) (cmpxchg(&((v)->counter), (o), (n))) 422 #define atomic64_cmpxchg(v, o, n) (cmpxchg(&((v)->counter), (o), (n)))
|
D | cputime.h | 35 #define cmpxchg_cputime(ptr, old, new) cmpxchg(ptr, old, new)
|
/linux-4.4.14/arch/powerpc/kvm/ |
D | book3s_hv_builtin.c | 250 } while (cmpxchg(&vc->entry_exit_map, ee, ee | me) != ee); in kvmhv_commence_exit() 280 } while (cmpxchg(&vc->entry_exit_map, ee, in kvmhv_commence_exit()
|
D | booke.c | 611 } while (cmpxchg(&vcpu->arch.tsr, tsr, new_tsr) != tsr); in kvmppc_watchdog_func()
|
/linux-4.4.14/arch/openrisc/include/asm/ |
D | Kbuild | 13 generic-y += cmpxchg-local.h 14 generic-y += cmpxchg.h
|
/linux-4.4.14/arch/arm/include/asm/ |
D | sync_bitops.h | 23 #define sync_cmpxchg cmpxchg
|
/linux-4.4.14/arch/hexagon/include/asm/ |
D | cmpxchg.h | 68 #define cmpxchg(ptr, old, new) \ macro
|
/linux-4.4.14/arch/arm64/include/asm/ |
D | sync_bitops.h | 24 #define sync_cmpxchg cmpxchg
|
D | cmpxchg.h | 162 #define cmpxchg(...) __cmpxchg_wrapper( _mb, __VA_ARGS__) macro 169 #define cmpxchg64 cmpxchg
|
D | atomic.h | 90 #define atomic_cmpxchg(v, old, new) cmpxchg(&((v)->counter), (old), (new))
|
/linux-4.4.14/arch/score/include/asm/ |
D | cmpxchg.h | 40 #define cmpxchg(ptr, o, n) \ macro
|
/linux-4.4.14/net/core/ |
D | lwtunnel.c | 49 return !cmpxchg((const struct lwtunnel_encap_ops **) in lwtunnel_encap_add_ops() 64 ret = (cmpxchg((const struct lwtunnel_encap_ops **) in lwtunnel_encap_del_ops()
|
D | dst.c | 327 prev = cmpxchg(&dst->_metrics, old, new); in dst_cow_metrics_generic() 346 prev = cmpxchg(&dst->_metrics, old, new); in __dst_destroy_metrics_generic()
|
/linux-4.4.14/arch/metag/include/asm/ |
D | cmpxchg.h | 54 #define cmpxchg(ptr, o, n) \ macro
|
/linux-4.4.14/arch/tile/kernel/ |
D | pmc.c | 41 return cmpxchg(&perf_irq, NULL, new_perf_irq); in reserve_pmc_hardware()
|
/linux-4.4.14/Documentation/features/locking/cmpxchg-local/ |
D | arch-support.txt | 2 # Feature name: cmpxchg-local
|
/linux-4.4.14/arch/mn10300/include/asm/ |
D | cmpxchg.h | 110 #define cmpxchg(ptr, o, n) \ macro
|
D | atomic.h | 132 #define atomic_cmpxchg(v, old, new) (cmpxchg(&((v)->counter), (old), (new)))
|
/linux-4.4.14/fs/f2fs/ |
D | crypto_key.c | 109 prev = cmpxchg(&fi->i_crypt_info, ci, NULL); in f2fs_free_encryption_info() 234 if (cmpxchg(&fi->i_crypt_info, NULL, crypt_info) != NULL) { in _f2fs_get_encryption_info()
|
/linux-4.4.14/arch/ia64/include/asm/ |
D | atomic.h | 134 #define atomic_cmpxchg(v, old, new) (cmpxchg(&((v)->counter), old, new)) 138 (cmpxchg(&((v)->counter), old, new))
|
D | pgtable.h | 445 } while (cmpxchg((unsigned long *) ptep, old, new) != old); in ptep_set_wrprotect()
|
/linux-4.4.14/arch/parisc/include/asm/ |
D | atomic.h | 74 #define atomic_cmpxchg(v, o, n) (cmpxchg(&((v)->counter), (o), (n))) 231 ((__typeof__((v)->counter))cmpxchg(&((v)->counter), (o), (n)))
|
D | cmpxchg.h | 73 #define cmpxchg(ptr, o, n) \ macro
|
/linux-4.4.14/arch/x86/kernel/cpu/ |
D | perf_event_amd.c | 250 if (cmpxchg(nb->owners + i, event, NULL) == event) in __amd_put_nb_event_constraints() 319 old = cmpxchg(nb->owners + idx, NULL, event); in __amd_get_nb_event_constraints() 331 cmpxchg(nb->owners + new, event, NULL); in __amd_get_nb_event_constraints()
|
D | perf_event_amd_uncore.c | 138 if (cmpxchg(&uncore->events[i], NULL, event) == NULL) { in amd_uncore_add() 168 if (cmpxchg(&uncore->events[i], event, NULL) == event) in amd_uncore_del()
|
/linux-4.4.14/arch/avr32/include/asm/ |
D | cmpxchg.h | 87 #define cmpxchg(ptr, old, new) \ macro
|
D | atomic.h | 182 #define atomic_cmpxchg(v, o, n) (cmpxchg(&((v)->counter), (o), (n)))
|
/linux-4.4.14/arch/tile/lib/ |
D | spinlock_64.c | 60 return cmpxchg(&lock->lock, val, (val + 1) & ~__ARCH_SPIN_NEXT_OVERFLOW) in arch_spin_trylock()
|
/linux-4.4.14/fs/ext4/ |
D | crypto_key.c | 107 prev = cmpxchg(&ei->i_crypt_info, ci, NULL); in ext4_free_encryption_info() 257 if (cmpxchg(&ei->i_crypt_info, NULL, crypt_info) != NULL) { in _ext4_get_encryption_info()
|
D | inode.c | 685 cmpxchg(&bh->b_state, old_state, new_state) != old_state)); in ext4_update_bh_state() 4103 } while (cmpxchg(&ei->i_flags, old_fl, new_fl) != old_fl); in ext4_get_inode_flags()
|
/linux-4.4.14/mm/ |
D | mmzone.c | 110 } while (unlikely(cmpxchg(&page->flags, old_flags, flags) != old_flags)); in page_cpupid_xchg_last()
|
D | cleancache.c | 54 if (cmpxchg(&cleancache_ops, NULL, ops)) in cleancache_register_ops()
|
D | frontswap.c | 140 } while (cmpxchg(&frontswap_ops, ops->next, ops) != ops->next); in frontswap_register_ops()
|
D | kmemleak.c | 1812 if (cmpxchg(&kmemleak_error, 0, 1)) in kmemleak_disable()
|
D | memcontrol.c | 919 (void)cmpxchg(&iter->position, pos, NULL); in mem_cgroup_iter() 971 (void)cmpxchg(&iter->position, pos, memcg); in mem_cgroup_iter() 1019 cmpxchg(&iter->position, in invalidate_reclaim_iterators()
|
D | huge_memory.c | 191 if (cmpxchg(&huge_zero_page, NULL, zero_page)) { in get_huge_zero_page()
|
D | page_alloc.c | 6509 old_word = cmpxchg(&bitmap[word_bitidx], word, (word & ~mask) | flags); in set_pfnblock_flags_mask()
|
/linux-4.4.14/Documentation/trace/ |
D | ring-buffer-design.txt | 38 cmpxchg - hardware-assisted atomic transaction that performs the following: 42 R = cmpxchg(A, C, B) is saying that we replace A with B if and only if 432 When the tail page meets the head pointer, it will use cmpxchg to 460 will also use cmpxchg. If the flag bit in the pointer to the 496 It does a cmpxchg with the pointer to the previous head page to make it 569 performs a cmpxchg to convert the pointer to the head page from the HEADER 676 is not the next page, the tail page is simply updated with a cmpxchg. 683 cmpxchg(tail_page, temp_page, next_page) 712 The above would fail the cmpxchg, but since the tail page has already 910 Since the cmpxchg returns the old value of the pointer the first writer
|
/linux-4.4.14/arch/m68k/include/asm/ |
D | cmpxchg.h | 120 #define cmpxchg(ptr, o, n) \ macro
|
D | atomic.h | 124 #define atomic_cmpxchg(v, o, n) ((int)cmpxchg(&((v)->counter), (o), (n)))
|
/linux-4.4.14/drivers/gpu/drm/i810/ |
D | i810_dma.c | 60 used = cmpxchg(buf_priv->in_use, I810_BUF_FREE, in i810_freelist_get() 78 used = cmpxchg(buf_priv->in_use, I810_BUF_CLIENT, I810_BUF_FREE); in i810_freelist_put() 772 (void)cmpxchg(buf_priv->in_use, I810_BUF_CLIENT, in i810_dma_dispatch_vertex() 871 int used = cmpxchg(buf_priv->in_use, I810_BUF_HARDWARE, in i810_flush_queue() 904 int used = cmpxchg(buf_priv->in_use, I810_BUF_CLIENT, in i810_driver_reclaim_buffers() 1042 u = cmpxchg(buf_priv->in_use, I810_BUF_CLIENT, I810_BUF_HARDWARE); in i810_dma_dispatch_mc()
|
/linux-4.4.14/arch/cris/include/asm/ |
D | Kbuild | 6 generic-y += cmpxchg.h
|
/linux-4.4.14/arch/m32r/include/asm/ |
D | cmpxchg.h | 190 #define cmpxchg(ptr, o, n) \ macro
|
D | atomic.h | 219 #define atomic_cmpxchg(v, o, n) ((int)cmpxchg(&((v)->counter), (o), (n)))
|
/linux-4.4.14/net/netfilter/ |
D | nf_conntrack_labels.c | 60 } while (cmpxchg(address, old, tmp) != old); in replace_u32()
|
D | xt_connlimit.c | 375 cmpxchg(&connlimit_rnd, 0, rand); in connlimit_mt_check()
|
D | nf_conntrack_core.c | 811 cmpxchg(&nf_conntrack_hash_rnd, 0, rand); in init_nf_conntrack_hash_rnd()
|
/linux-4.4.14/arch/s390/kvm/ |
D | gaccess.c | 286 } while (cmpxchg(&ic->val, old.val, new.val) != old.val); in ipte_lock_simple() 304 } while (cmpxchg(&ic->val, old.val, new.val) != old.val); in ipte_unlock_simple() 324 } while (cmpxchg(&ic->val, old.val, new.val) != old.val); in ipte_lock_siif() 338 } while (cmpxchg(&ic->val, old.val, new.val) != old.val); in ipte_unlock_siif()
|
D | interrupt.c | 1013 if (cmpxchg(sigp_ctrl, old_val, new_val) != old_val) { in __inject_extcall_sigpif()
|
/linux-4.4.14/arch/arc/kernel/ |
D | smp.c | 234 } while (cmpxchg(ipi_data_ptr, old, new) != old); in ipi_send_msg_one()
|
/linux-4.4.14/drivers/staging/speakup/ |
D | selection.c | 178 if (cmpxchg(&speakup_paste_work.tty, NULL, tty) != NULL) in speakup_paste_selection()
|
/linux-4.4.14/arch/x86/xen/ |
D | spinlock.c | 96 ret = cmpxchg(&zero_stats, old, 0); in check_zero()
|
D | p2m.c | 578 old_mfn = cmpxchg(top_mfn_p, missing_mfn, mid_mfn_mfn); in xen_alloc_p2m_entry()
|
/linux-4.4.14/arch/ia64/kernel/ |
D | time.c | 344 ret = cmpxchg(&itc_jitter_data.itc_lastcycle, lcycle, now); in itc_get_cycles()
|
D | setup.c | 1028 if (cmpxchg(&ia64_ctx.max_ctx, old, max_ctx) == old) in cpu_init()
|
/linux-4.4.14/drivers/phy/ |
D | phy-rcar-gen2.c | 84 if (cmpxchg(&channel->selected_phy, -1, phy->number) != -1) in rcar_gen2_phy_init()
|
/linux-4.4.14/drivers/xen/ |
D | mcelog.c | 170 } while (cmpxchg(&xen_mcelog.flags, flags, 0) != flags); in xen_mce_chrdev_ioctl()
|
/linux-4.4.14/Documentation/locking/ |
D | rt-mutex.txt | 42 without waiters. The optimized fastpath operations require cmpxchg
|
D | rt-mutex-design.txt | 325 cmpxchg Tricks 328 Some architectures implement an atomic cmpxchg (Compare and Exchange). This 332 cmpxchg is basically the following function performed atomically: 342 #define cmpxchg(a,b,c) _cmpxchg(&a,&b,&c)
|
/linux-4.4.14/drivers/net/ethernet/sfc/ |
D | net_driver.h | 504 prev = cmpxchg(&channel->busy_poll_state, old, in efx_channel_lock_napi() 527 return cmpxchg(&channel->busy_poll_state, EFX_CHANNEL_STATE_IDLE, in efx_channel_try_lock_poll()
|
D | mcdi.c | 409 return cmpxchg(&mcdi->state, in efx_mcdi_acquire_async() 420 cmpxchg(&mcdi->state, in efx_mcdi_acquire_sync() 452 if (cmpxchg(&mcdi->state, in efx_mcdi_complete_sync() 504 if (cmpxchg(&mcdi->state, in efx_mcdi_complete_async()
|
D | ptp.c | 1718 (void) cmpxchg(&channel->sync_events_state, SYNC_EVENTS_REQUESTED, in efx_time_sync_event()
|
/linux-4.4.14/kernel/rcu/ |
D | tree_plugin.h | 2658 newoldstate = cmpxchg(&full_sysidle_state, in rcu_sysidle_force_exit() 2813 (void)cmpxchg(&full_sysidle_state, in rcu_sysidle() 2824 (void)cmpxchg(&full_sysidle_state, in rcu_sysidle() 2938 rss = cmpxchg(&full_sysidle_state, in rcu_sys_is_idle()
|
/linux-4.4.14/drivers/misc/sgi-xp/ |
D | xpc_sn2.c | 1726 cmpxchg(¬ify->type, notify_type, 0) != notify_type) { in xpc_notify_senders_sn2() 1998 if (cmpxchg(&ch_sn2->w_local_GP.get, get, get + 1) == get) { in xpc_get_deliverable_payload_sn2() 2117 if (cmpxchg(&ch_sn2->w_local_GP.put, put, put + 1) == in xpc_allocate_msg_sn2() 2224 if (cmpxchg(¬ify->type, notify_type, 0) == in xpc_send_payload_sn2()
|
D | xpc_uv.c | 1371 if (func != NULL && cmpxchg(&msg_slot->func, func, NULL) == func) { in xpc_notify_sender_uv() 1599 if (cmpxchg(&msg_slot->func, func, NULL) != func) { in xpc_send_payload_uv()
|
D | xpc_main.c | 1102 if (cmpxchg(&xpc_die_disconnecting, 0, 1)) in xpc_die_deactivate()
|
/linux-4.4.14/kernel/trace/ |
D | trace_functions.c | 395 new_count = cmpxchg(count, old_count, new_count); in ftrace_stacktrace_count()
|
D | ring_buffer.c | 904 ret = cmpxchg((unsigned long *)&list->next, in rb_head_page_set() 997 ret = cmpxchg(ptr, val, (unsigned long)&new->list); in rb_head_page_replace() 1064 old_tail = cmpxchg(&cpu_buffer->tail_page, in rb_tail_page_update() 1584 r = cmpxchg(&prev_page->next, head_page_with_bit, first_page); in rb_insert_pages()
|
D | blktrace.c | 522 if (cmpxchg(&q->blk_trace, NULL, bt)) in do_blk_trace_setup() 1499 if (cmpxchg(&q->blk_trace, NULL, bt)) in blk_trace_setup_queue()
|
/linux-4.4.14/arch/x86/kernel/acpi/ |
D | boot.c | 1686 val = cmpxchg(lock, old, new); in __acpi_acquire_global_lock() 1697 val = cmpxchg(lock, old, new); in __acpi_release_global_lock()
|
/linux-4.4.14/drivers/misc/genwqe/ |
D | card_ddcb.c | 310 icrc_hsi_shi = cmpxchg(&prev_ddcb->icrc_hsi_shi_32, old, new); in enqueue_ddcb() 657 icrc_hsi_shi = cmpxchg(&pddcb->icrc_hsi_shi_32, in __genwqe_purge_ddcb()
|
/linux-4.4.14/arch/x86/kvm/ |
D | paging_tmpl.h | 48 #define CMPXCHG cmpxchg 67 #define CMPXCHG cmpxchg
|
D | vmx.c | 2032 } while (cmpxchg(&pi_desc->control, old.control, in vmx_vcpu_pi_load() 10653 } while (cmpxchg(&pi_desc->control, old.control, in vmx_pre_block() 10685 } while (cmpxchg(&pi_desc->control, old.control, in vmx_post_block()
|
D | x86.c | 4507 (cmpxchg((t *)(ptr), *(t *)(old), *(t *)(new)) == *(t *)(old))
|
/linux-4.4.14/arch/x86/kernel/cpu/mcheck/ |
D | mce.c | 190 if (cmpxchg(&mcelog.next, entry, next) == entry) in mce_log() 1868 next = cmpxchg(&mcelog.next, prev, 0); in mce_chrdev_read() 1928 } while (cmpxchg(&mcelog.flags, flags, 0) != flags); in mce_chrdev_ioctl()
|
/linux-4.4.14/sound/soc/xtensa/ |
D | xtfpga-i2s.c | 172 cmpxchg(&i2s->tx_ptr, tx_ptr, new_tx_ptr); in xtfpga_pcm_push_tx()
|
/linux-4.4.14/Documentation/ |
D | atomic_ops.txt | 541 The routines xchg() and cmpxchg() must provide the same exact 545 Note: If someone wants to use xchg(), cmpxchg() and their variants, 546 linux/atomic.h should be included rather than asm/cmpxchg.h, unless
|
D | this_cpu_ops.txt | 24 RMW (Read Modify Write) instructions like inc/dec/cmpxchg without the
|
D | memory-barriers.txt | 2345 cmpxchg();
|
/linux-4.4.14/arch/x86/kernel/ |
D | kvm.c | 647 ret = cmpxchg(&zero_stats, old, 0); in check_zero()
|
/linux-4.4.14/drivers/char/ |
D | random.c | 673 if (cmpxchg(&r->entropy_count, orig, entropy_count) != orig) in credit_entropy_bits() 1071 if (cmpxchg(&r->entropy_count, orig, entropy_count) != orig) in account()
|
/linux-4.4.14/fs/nfs/flexfilelayout/ |
D | flexfilelayoutdev.c | 353 if (cmpxchg(&mirror->cred, NULL, cred)) in ff_layout_update_mirror_cred()
|
/linux-4.4.14/drivers/gpu/drm/vmwgfx/ |
D | vmwgfx_fifo.c | 171 if (cmpxchg(fifo_mem + SVGA_FIFO_BUSY, 0, 1) == 0) in vmw_fifo_ping_host()
|
/linux-4.4.14/drivers/block/ |
D | ataflop.c | 655 wait_event(fdc_wait, cmpxchg(&fdc_busy, 0, 1) == 0); in do_format() 1501 wait_event(fdc_wait, cmpxchg(&fdc_busy, 0, 1) == 0); in do_fd_request()
|
/linux-4.4.14/drivers/md/ |
D | dm-bufio.c | 339 (void)cmpxchg(&dm_bufio_cache_size, 0, in __cache_size_refresh() 677 (void)cmpxchg(&c->async_write_error, 0, error); in write_endio()
|
D | raid5-cache.c | 779 } while (cmpxchg(&log->reclaim_target, target, new) != target); in r5l_wake_reclaim()
|
D | dm.c | 292 (void)cmpxchg(module_param, param, modified_param); in __dm_get_module_param()
|
/linux-4.4.14/drivers/staging/rdma/ipath/ |
D | ipath_ruc.c | 389 (u64) cmpxchg((u64 *) qp->r_sge.sge.vaddr, in ipath_ruc_loopback()
|
D | ipath_rc.c | 1911 (u64) cmpxchg((u64 *) qp->r_sge.sge.vaddr, in ipath_rc_rcv()
|
/linux-4.4.14/arch/x86/mm/ |
D | pat.c | 132 } while (cmpxchg(&pg->flags, old_flags, new_flags) != old_flags); in set_page_memtype()
|
/linux-4.4.14/net/rds/ |
D | ib_recv.c | 494 old = cmpxchg(&cache->xfer, NULL, chpfirst); in rds_ib_recv_cache_put()
|
/linux-4.4.14/drivers/infiniband/hw/qib/ |
D | qib_ruc.c | 503 (u64) cmpxchg((u64 *) qp->r_sge.sge.vaddr, in qib_ruc_loopback()
|
D | qib_rc.c | 2208 (u64) cmpxchg((u64 *) qp->r_sge.sge.vaddr, in qib_rc_rcv()
|
/linux-4.4.14/drivers/acpi/apei/ |
D | ghes.c | 637 if (slot != -1 && cmpxchg(ghes_estatus_caches + slot, in ghes_estatus_cache_add()
|
/linux-4.4.14/fs/ |
D | direct-io.c | 556 old = cmpxchg(&sb->s_dio_done_wq, NULL, wq); in sb_init_dio_done_wq()
|
D | aio.c | 565 cancel = cmpxchg(&kiocb->ki_cancel, old, KIOCB_CANCELLED); in kiocb_cancel()
|
D | exec.c | 1707 } while (cmpxchg(&mm->flags, old, new) != old); in set_dumpable()
|
D | inode.c | 2027 } while (unlikely(cmpxchg(&inode->i_flags, old_flags, in inode_set_flags()
|
D | fs-writeback.c | 255 if (unlikely(cmpxchg(&inode->i_wb, NULL, wb))) in __inode_attach_wb()
|
D | locks.c | 228 if (cmpxchg(&inode->i_flctx, NULL, ctx)) { in locks_get_lock_context()
|
D | buffer.c | 1508 b_state_old = cmpxchg(&bh->b_state, b_state, in discard_buffer()
|
/linux-4.4.14/drivers/target/iscsi/ |
D | iscsi_target.c | 4255 cmpxchg(&conn->tx_thread_active, true, false)) { in iscsit_close_connection() 4261 cmpxchg(&conn->rx_thread_active, true, false)) { in iscsit_close_connection() 4557 sleep = cmpxchg(&conn->tx_thread_active, true, false); in iscsit_logout_post_handler_closesession() 4574 sleep = cmpxchg(&conn->tx_thread_active, true, false); in iscsit_logout_post_handler_samecid()
|
/linux-4.4.14/drivers/staging/rdma/hfi1/ |
D | ruc.c | 525 (u64) cmpxchg((u64 *) qp->r_sge.sge.vaddr, in ruc_loopback()
|
D | rc.c | 2298 (u64) cmpxchg((u64 *) qp->r_sge.sge.vaddr, in hfi1_rc_rcv()
|
/linux-4.4.14/drivers/net/ethernet/broadcom/bnx2x/ |
D | bnx2x.h | 656 prev = cmpxchg(&fp->busy_poll_state, old, BNX2X_STATE_FP_NAPI); in bnx2x_fp_lock_napi() 674 return cmpxchg(&fp->busy_poll_state, 0, BNX2X_STATE_FP_POLL) == 0; in bnx2x_fp_lock_poll()
|
/linux-4.4.14/arch/powerpc/xmon/ |
D | xmon.c | 358 last_speaker = cmpxchg(&xmon_speaker, 0, me); in get_output_lock() 374 prev = cmpxchg(&xmon_speaker, last_speaker, me); in get_output_lock()
|
/linux-4.4.14/arch/sparc/ |
D | Kconfig | 215 Sparc32 does not have a CAS instruction like sparc64. cmpxchg()
|
/linux-4.4.14/drivers/gpu/drm/armada/ |
D | armada_crtc.c | 219 ret = cmpxchg(&plane->work, NULL, work) ? -EBUSY : 0; in armada_drm_plane_work_queue()
|
/linux-4.4.14/drivers/net/ethernet/chelsio/cxgb3/ |
D | cxgb3_offload.c | 633 (void)cmpxchg(&t->tid_tab[tid].ctx, ctx, NULL); in cxgb3_remove_tid()
|
/linux-4.4.14/kernel/sched/ |
D | core.c | 462 __old = cmpxchg((ptr), __val, __val | (val)); \ 498 old = cmpxchg(&ti->flags, val, val | _TIF_NEED_RESCHED); in set_nr_if_polling() 533 if (cmpxchg(&node->next, NULL, WAKE_Q_TAIL)) in wake_q_add()
|
D | fair.c | 2195 if (cmpxchg(&mm->numa_next_scan, migrate, next_scan) != migrate) in task_numa_work()
|
/linux-4.4.14/net/sunrpc/auth_gss/ |
D | svcauth_gss.c | 1279 ret = cmpxchg(&sn->use_gss_proxy, -1, type); in set_gss_proxy()
|
/linux-4.4.14/net/netfilter/ipvs/ |
D | ip_vs_sync.c | 528 n = cmpxchg(&cp->sync_endtime, orig, n); in ip_vs_sync_conn_needed()
|
/linux-4.4.14/drivers/block/drbd/ |
D | drbd_worker.c | 1945 } while (cmpxchg(flags, old, new) != old); in get_work_bits()
|
/linux-4.4.14/fs/btrfs/ |
D | raid56.c | 240 x = cmpxchg(&info->stripe_hash_table, NULL, table); in btrfs_alloc_stripe_hash_table()
|
D | inode.c | 3342 if (cmpxchg(&root->orphan_cleanup_state, 0, ORPHAN_CLEANUP_STARTED)) in btrfs_orphan_cleanup()
|
/linux-4.4.14/drivers/target/ |
D | target_core_transport.c | 615 if (cmpxchg(&cmd->lun_ref_active, true, false)) in transport_lun_remove_cmd()
|
/linux-4.4.14/drivers/md/bcache/ |
D | btree.c | 841 old = cmpxchg(&c->btree_cache_alloc_lock, NULL, current); in mca_cannibalize_lock()
|
/linux-4.4.14/virt/kvm/ |
D | kvm_main.c | 199 cmpxchg(&kvm->tlbs_dirty, dirty_count, 0); in kvm_flush_remote_tlbs()
|
/linux-4.4.14/drivers/usb/gadget/function/ |
D | f_fs.c | 88 cmpxchg(&ffs->setup_state, FFS_SETUP_CANCELLED, FFS_NO_SETUP); in ffs_setup_state_clear_cancelled()
|
/linux-4.4.14/ |
D | MAINTAINERS | 2956 M: Johannes Weiner <hannes@cmpxchg.org> 2976 M: Johannes Weiner <hannes@cmpxchg.org>
|