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

Configure Feed

Select the types of activity you want to include in your feed.

docs: remove :c:func: from refcount-vs-atomic.rst

As of 5.3, the automarkup extension will do the right thing with function()
notation, so we don't need to clutter the text with :c:func: invocations.
So remove them.

Looking at the generated output reveals that we lack kerneldoc coverage for
much of this API, but that's a separate problem.

Acked-by: Paul E. McKenney <paulmck@kernel.org>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>

+18 -18
+18 -18
Documentation/core-api/refcount-vs-atomic.rst
··· 35 35 program order (po) relation (on the same CPU). It guarantees that 36 36 each ``atomic_*()`` and ``refcount_*()`` operation is atomic and instructions 37 37 are executed in program order on a single CPU. 38 - This is implemented using :c:func:`READ_ONCE`/:c:func:`WRITE_ONCE` and 38 + This is implemented using READ_ONCE()/WRITE_ONCE() and 39 39 compare-and-swap primitives. 40 40 41 41 A strong (full) memory ordering guarantees that all prior loads and ··· 44 44 It also guarantees that all po-earlier stores on the same CPU 45 45 and all propagated stores from other CPUs must propagate to all 46 46 other CPUs before any po-later instruction is executed on the original 47 - CPU (A-cumulative property). This is implemented using :c:func:`smp_mb`. 47 + CPU (A-cumulative property). This is implemented using smp_mb(). 48 48 49 49 A RELEASE memory ordering guarantees that all prior loads and 50 50 stores (all po-earlier instructions) on the same CPU are completed ··· 52 52 stores on the same CPU and all propagated stores from other CPUs 53 53 must propagate to all other CPUs before the release operation 54 54 (A-cumulative property). This is implemented using 55 - :c:func:`smp_store_release`. 55 + smp_store_release(). 56 56 57 57 An ACQUIRE memory ordering guarantees that all post loads and 58 58 stores (all po-later instructions) on the same CPU are 59 59 completed after the acquire operation. It also guarantees that all 60 60 po-later stores on the same CPU must propagate to all other CPUs 61 61 after the acquire operation executes. This is implemented using 62 - :c:func:`smp_acquire__after_ctrl_dep`. 62 + smp_acquire__after_ctrl_dep(). 63 63 64 64 A control dependency (on success) for refcounters guarantees that 65 65 if a reference for an object was successfully obtained (reference ··· 78 78 79 79 Function changes: 80 80 81 - * :c:func:`atomic_set` --> :c:func:`refcount_set` 82 - * :c:func:`atomic_read` --> :c:func:`refcount_read` 81 + * atomic_set() --> refcount_set() 82 + * atomic_read() --> refcount_read() 83 83 84 84 Memory ordering guarantee changes: 85 85 ··· 91 91 92 92 Function changes: 93 93 94 - * :c:func:`atomic_inc` --> :c:func:`refcount_inc` 95 - * :c:func:`atomic_add` --> :c:func:`refcount_add` 94 + * atomic_inc() --> refcount_inc() 95 + * atomic_add() --> refcount_add() 96 96 97 97 Memory ordering guarantee changes: 98 98 ··· 103 103 104 104 Function changes: 105 105 106 - * :c:func:`atomic_dec` --> :c:func:`refcount_dec` 106 + * atomic_dec() --> refcount_dec() 107 107 108 108 Memory ordering guarantee changes: 109 109 ··· 115 115 116 116 Function changes: 117 117 118 - * :c:func:`atomic_inc_not_zero` --> :c:func:`refcount_inc_not_zero` 119 - * no atomic counterpart --> :c:func:`refcount_add_not_zero` 118 + * atomic_inc_not_zero() --> refcount_inc_not_zero() 119 + * no atomic counterpart --> refcount_add_not_zero() 120 120 121 121 Memory ordering guarantees changes: 122 122 ··· 131 131 132 132 Function changes: 133 133 134 - * :c:func:`atomic_dec_and_test` --> :c:func:`refcount_dec_and_test` 135 - * :c:func:`atomic_sub_and_test` --> :c:func:`refcount_sub_and_test` 134 + * atomic_dec_and_test() --> refcount_dec_and_test() 135 + * atomic_sub_and_test() --> refcount_sub_and_test() 136 136 137 137 Memory ordering guarantees changes: 138 138 ··· 144 144 145 145 Function changes: 146 146 147 - * no atomic counterpart --> :c:func:`refcount_dec_if_one` 147 + * no atomic counterpart --> refcount_dec_if_one() 148 148 * ``atomic_add_unless(&var, -1, 1)`` --> ``refcount_dec_not_one(&var)`` 149 149 150 150 Memory ordering guarantees changes: 151 151 152 152 * fully ordered --> RELEASE ordering + control dependency 153 153 154 - .. note:: :c:func:`atomic_add_unless` only provides full order on success. 154 + .. note:: atomic_add_unless() only provides full order on success. 155 155 156 156 157 157 case 7) - lock-based RMW ··· 159 159 160 160 Function changes: 161 161 162 - * :c:func:`atomic_dec_and_lock` --> :c:func:`refcount_dec_and_lock` 163 - * :c:func:`atomic_dec_and_mutex_lock` --> :c:func:`refcount_dec_and_mutex_lock` 162 + * atomic_dec_and_lock() --> refcount_dec_and_lock() 163 + * atomic_dec_and_mutex_lock() --> refcount_dec_and_mutex_lock() 164 164 165 165 Memory ordering guarantees changes: 166 166 167 167 * fully ordered --> RELEASE ordering + control dependency + hold 168 - :c:func:`spin_lock` on success 168 + spin_lock() on success