<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/scripts/atomic/gen-atomic-instrumented.sh, branch v6.1.174</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.1.174</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.1.174'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2022-05-17T22:08:27+00:00</updated>
<entry>
<title>locking/atomic: Add generic try_cmpxchg64 support</title>
<updated>2022-05-17T22:08:27+00:00</updated>
<author>
<name>Uros Bizjak</name>
<email>ubizjak@gmail.com</email>
</author>
<published>2022-05-15T18:42:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=0aa7be05d83cc584da0782405e8007e351dfb6cc'/>
<id>urn:sha1:0aa7be05d83cc584da0782405e8007e351dfb6cc</id>
<content type='text'>
Add generic support for try_cmpxchg64{,_acquire,_release,_relaxed}
and their falbacks involving cmpxchg64.

Signed-off-by: Uros Bizjak &lt;ubizjak@gmail.com&gt;
Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Link: https://lkml.kernel.org/r/20220515184205.103089-2-ubizjak@gmail.com
</content>
</entry>
<entry>
<title>locking/atomics, kcsan: Add instrumentation for barriers</title>
<updated>2021-12-10T00:42:27+00:00</updated>
<author>
<name>Marco Elver</name>
<email>elver@google.com</email>
</author>
<published>2021-11-30T11:44:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=e87c4f6642f49627c3430cb3ee78c73fb51b48e4'/>
<id>urn:sha1:e87c4f6642f49627c3430cb3ee78c73fb51b48e4</id>
<content type='text'>
Adds the required KCSAN instrumentation for barriers of atomics.

Signed-off-by: Marco Elver &lt;elver@google.com&gt;
Signed-off-by: Paul E. McKenney &lt;paulmck@kernel.org&gt;
</content>
</entry>
<entry>
<title>locking/atomic: add arch_atomic_long*()</title>
<updated>2021-07-16T16:46:45+00:00</updated>
<author>
<name>Mark Rutland</name>
<email>mark.rutland@arm.com</email>
</author>
<published>2021-07-13T10:52:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=67d1b0de258ad066e1fc85d0ceaa75e107fb45bb'/>
<id>urn:sha1:67d1b0de258ad066e1fc85d0ceaa75e107fb45bb</id>
<content type='text'>
Now that all architectures provide arch_{atomic,atomic64}_*(), we can
build arch_atomic_long_*() atop these, which can be safely used in
noinstr code. The regular atomic_long_*() wrappers are built atop these,
as we do for {atomic,atomic64}_*() atop arch_{atomic,atomic64}_*().

We don't provide arch_* versions of the cond_read*() variants, as we
don't have arch_* versions of the underlying atomic/atomic64 functions
(nor the smp_cond_load*() helpers these are typically based on).

Note that the headers in this patch under include/linux/atomic/ are
generated by the scripts in scripts/atomic/.

Signed-off-by: Mark Rutland &lt;mark.rutland@arm.com&gt;
Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Link: https://lore.kernel.org/r/20210713105253.7615-5-mark.rutland@arm.com
</content>
</entry>
<entry>
<title>locking/atomic: centralize generated headers</title>
<updated>2021-07-16T16:46:45+00:00</updated>
<author>
<name>Mark Rutland</name>
<email>mark.rutland@arm.com</email>
</author>
<published>2021-07-13T10:52:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=e3d18cee258b898017b298b5b93f8134dd62aee3'/>
<id>urn:sha1:e3d18cee258b898017b298b5b93f8134dd62aee3</id>
<content type='text'>
The generated atomic headers are only intended to be included directly
by &lt;linux/atomic.h&gt;, but are spread across include/linux/ and
include/asm-generic/, where people mnay be encouraged to include them.

This patch centralizes them under include/linux/atomic/.

Other than the header guards and hashes, there is no change to any of
the generated headers as a result of this patch.

Signed-off-by: Mark Rutland &lt;mark.rutland@arm.com&gt;
Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Link: https://lore.kernel.org/r/20210713105253.7615-4-mark.rutland@arm.com
</content>
</entry>
<entry>
<title>locking/atomics: atomic-instrumented: simplify ifdeffery</title>
<updated>2021-05-26T11:20:52+00:00</updated>
<author>
<name>Mark Rutland</name>
<email>mark.rutland@arm.com</email>
</author>
<published>2021-05-25T14:02:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=bccf1ec369ac126b0997d01a6e1deae00e2cf6b3'/>
<id>urn:sha1:bccf1ec369ac126b0997d01a6e1deae00e2cf6b3</id>
<content type='text'>
Now that all architectures implement ARCH_ATOMIC, the fallbacks are
generated before the instrumented wrappers are generated. Due to this,
in atomic-instrumented.h we can assume that the whole set of atomic
functions has been generated. Likewise, atomic-instrumented.h doesn't
need to provide a preprocessor definition for every atomic it wraps.

This patch removes the redundant ifdeffery.

There should be no functional change as a result of this patch.

Signed-off-by: Mark Rutland &lt;mark.rutland@arm.com&gt;
Cc: Boqun Feng &lt;boqun.feng@gmail.com&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Will Deacon &lt;will@kernel.org&gt;
Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Link: https://lore.kernel.org/r/20210525140232.53872-34-mark.rutland@arm.com
</content>
</entry>
<entry>
<title>Merge branch 'linus' into perf/kprobes</title>
<updated>2020-11-07T12:20:17+00:00</updated>
<author>
<name>Ingo Molnar</name>
<email>mingo@kernel.org</email>
</author>
<published>2020-11-07T11:50:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=666fab4a3ea143315a9c059fad9f3a0f1365d54b'/>
<id>urn:sha1:666fab4a3ea143315a9c059fad9f3a0f1365d54b</id>
<content type='text'>
Conflicts:
	include/asm-generic/atomic-instrumented.h
	kernel/kprobes.c

Use the upstream atomic-instrumented.h checksum, and pick
the kprobes version of kernel/kprobes.c, which effectively
reverts this upstream workaround:

  645f224e7ba2: ("kprobes: Tell lockdep about kprobe nesting")

Since the new code *should* be fine without nesting.

Knock on wood ...

Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
</content>
</entry>
<entry>
<title>asm-generic/atomic: Add try_cmpxchg() fallbacks</title>
<updated>2020-10-12T16:27:27+00:00</updated>
<author>
<name>Peter Zijlstra</name>
<email>peterz@infradead.org</email>
</author>
<published>2020-08-29T13:03:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=29f006fdefe6f88abde973a0b0f20d2704e93fd4'/>
<id>urn:sha1:29f006fdefe6f88abde973a0b0f20d2704e93fd4</id>
<content type='text'>
Only x86 provides try_cmpxchg() outside of the atomic_t interfaces,
provide generic fallbacks to create this interface from the widely
available cmpxchg() function.

Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Signed-off-by: Masami Hiramatsu &lt;mhiramat@kernel.org&gt;
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
Acked-by: Will Deacon &lt;will@kernel.org&gt;
Link: https://lore.kernel.org/r/159870621515.1229682.15506193091065001742.stgit@devnote2
</content>
</entry>
<entry>
<title>locking/atomics: Use read-write instrumentation for atomic RMWs</title>
<updated>2020-08-24T22:09:59+00:00</updated>
<author>
<name>Marco Elver</name>
<email>elver@google.com</email>
</author>
<published>2020-07-24T07:00:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3570a1bcf45e9a7ddf9ba0e8d6d57cc67675cfef'/>
<id>urn:sha1:3570a1bcf45e9a7ddf9ba0e8d6d57cc67675cfef</id>
<content type='text'>
Use instrument_atomic_read_write() for atomic RMW ops.

Cc: Will Deacon &lt;will@kernel.org&gt;
Cc: Boqun Feng &lt;boqun.feng@gmail.com&gt;
Cc: Arnd Bergmann &lt;arnd@arndb.de&gt;
Cc: &lt;linux-arch@vger.kernel.org&gt;
Acked-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Signed-off-by: Marco Elver &lt;elver@google.com&gt;
Signed-off-by: Paul E. McKenney &lt;paulmck@kernel.org&gt;
</content>
</entry>
<entry>
<title>asm-generic, atomic-instrumented: Use generic instrumented.h</title>
<updated>2020-03-21T08:41:42+00:00</updated>
<author>
<name>Marco Elver</name>
<email>elver@google.com</email>
</author>
<published>2020-01-21T16:05:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ed8af2e4d2a71bd58f5776b7e5a477d136e32be4'/>
<id>urn:sha1:ed8af2e4d2a71bd58f5776b7e5a477d136e32be4</id>
<content type='text'>
This switches atomic-instrumented.h to use the generic instrumentation
wrappers provided by instrumented.h.

No functional change intended.

Suggested-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Marco Elver &lt;elver@google.com&gt;
Acked-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Paul E. McKenney &lt;paulmck@kernel.org&gt;
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
</content>
</entry>
<entry>
<title>asm-generic/atomic: Use __always_inline for pure wrappers</title>
<updated>2020-01-07T15:47:23+00:00</updated>
<author>
<name>Marco Elver</name>
<email>elver@google.com</email>
</author>
<published>2019-11-26T14:04:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=c020395b6634b7a674ee6aa91a971b08e268caba'/>
<id>urn:sha1:c020395b6634b7a674ee6aa91a971b08e268caba</id>
<content type='text'>
Prefer __always_inline for atomic wrappers. When building for size
(CC_OPTIMIZE_FOR_SIZE), some compilers appear to be less inclined to
inline even relatively small static inline functions that are assumed to
be inlinable such as atomic ops. This can cause problems, for example in
UACCESS regions.

By using __always_inline, we let the real implementation and not the
wrapper determine the final inlining preference.

For x86 tinyconfig we observe:
- vmlinux baseline: 1316204
- vmlinux with patch: 1315988 (-216 bytes)

This came up when addressing UACCESS warnings with CC_OPTIMIZE_FOR_SIZE
in the KCSAN runtime:
http://lkml.kernel.org/r/58708908-84a0-0a81-a836-ad97e33dbb62@infradead.org

Reported-by: Randy Dunlap &lt;rdunlap@infradead.org&gt;
Signed-off-by: Marco Elver &lt;elver@google.com&gt;
Acked-by: Mark Rutland &lt;mark.rutland@arm.com&gt;
Signed-off-by: Paul E. McKenney &lt;paulmck@kernel.org&gt;
</content>
</entry>
</feed>
