<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/arch/parisc/include/asm/spinlock.h, branch v6.3</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.3</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.3'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2021-10-30T14:37:28+00:00</updated>
<entry>
<title>locking: Remove spin_lock_flags() etc</title>
<updated>2021-10-30T14:37:28+00:00</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2021-10-22T11:59:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f98a3dccfcb0b9b9c3bef8df9edd61cda80ad937'/>
<id>urn:sha1:f98a3dccfcb0b9b9c3bef8df9edd61cda80ad937</id>
<content type='text'>
parisc, ia64 and powerpc32 are the only remaining architectures that
provide custom arch_{spin,read,write}_lock_flags() functions, which are
meant to re-enable interrupts while waiting for a spinlock.

However, none of these can actually run into this codepath, because
it is only called on architectures without CONFIG_GENERIC_LOCKBREAK,
or when CONFIG_DEBUG_LOCK_ALLOC is set without CONFIG_LOCKDEP, and none
of those combinations are possible on the three architectures.

Going back in the git history, it appears that arch/mn10300 may have
been able to run into this code path, but there is a good chance that
it never worked. On the architectures that still exist, it was
already impossible to hit back in 2008 after the introduction of
CONFIG_GENERIC_LOCKBREAK, and possibly earlier.

As this is all dead code, just remove it and the helper functions built
around it. For arch/ia64, the inline asm could be cleaned up, but
it seems safer to leave it untouched.

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Acked-by: Helge Deller &lt;deller@gmx.de&gt;  # parisc
Link: https://lore.kernel.org/r/20211022120058.1031690-1-arnd@kernel.org
</content>
</entry>
<entry>
<title>parisc: Improve spinlock handling</title>
<updated>2020-10-15T06:10:39+00:00</updated>
<author>
<name>John David Anglin</name>
<email>dave.anglin@bell.net</email>
</author>
<published>2020-10-02T19:41:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f173e3a751708b7f5e0b77dcdd4ac3c2287b735e'/>
<id>urn:sha1:f173e3a751708b7f5e0b77dcdd4ac3c2287b735e</id>
<content type='text'>
Use READ_ONCE() to check if spinlock is locked.
The other changes are cleanups.

Signed-off-by: John David Anglin &lt;dave.anglin@bell.net&gt;
Signed-off-by: Helge Deller &lt;deller@gmx.de&gt;
</content>
</entry>
<entry>
<title>Revert "parisc: Revert "Release spinlocks using ordered store""</title>
<updated>2020-07-28T16:56:14+00:00</updated>
<author>
<name>Helge Deller</name>
<email>deller@gmx.de</email>
</author>
<published>2020-07-28T16:56:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=157e9afcc4fa25068b0e8743bc254a9b56010e13'/>
<id>urn:sha1:157e9afcc4fa25068b0e8743bc254a9b56010e13</id>
<content type='text'>
This reverts commit 86d4d068df573a8c2105554624796c086d6bec3d.

Signed-off-by: Helge Deller &lt;deller@gmx.de&gt;
Cc: &lt;stable@vger.kernel.org&gt; # v5.0+
</content>
</entry>
<entry>
<title>Revert "parisc: Use ldcw instruction for SMP spinlock release barrier"</title>
<updated>2020-07-28T16:54:40+00:00</updated>
<author>
<name>Helge Deller</name>
<email>deller@gmx.de</email>
</author>
<published>2020-07-28T16:54:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6e9f06ee6c9566f3606d93182ac8f803a148504b'/>
<id>urn:sha1:6e9f06ee6c9566f3606d93182ac8f803a148504b</id>
<content type='text'>
This reverts commit 9e5c602186a692a7e848c0da17aed40f49d30519.
No need to use the ldcw instruction as SMP spinlock release barrier.
Revert it to gain back speed again.

Signed-off-by: Helge Deller &lt;deller@gmx.de&gt;
Cc: &lt;stable@vger.kernel.org&gt; # v5.2+
</content>
</entry>
<entry>
<title>Revert "parisc: Improve interrupt handling in arch_spin_lock_flags()"</title>
<updated>2020-07-28T16:49:45+00:00</updated>
<author>
<name>Helge Deller</name>
<email>deller@gmx.de</email>
</author>
<published>2020-07-28T16:49:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3d05b8aebc5f10ee3ab129b61100196855dd7249'/>
<id>urn:sha1:3d05b8aebc5f10ee3ab129b61100196855dd7249</id>
<content type='text'>
This reverts commit 2772f0efd5bbd5413db3d22e363b779ca0fa5310.
It turns out that we want to implement the spinlock code differently.

Signed-off-by: Helge Deller &lt;deller@gmx.de&gt;
Cc: &lt;stable@vger.kernel.org&gt; # v5.7+
</content>
</entry>
<entry>
<title>parisc: Rework arch_rw locking functions</title>
<updated>2020-04-05T20:29:55+00:00</updated>
<author>
<name>Helge Deller</name>
<email>deller@gmx.de</email>
</author>
<published>2020-04-05T20:29:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=fbdc8f0f4891df7b5eb643ec0a509a4ac7dcfc2e'/>
<id>urn:sha1:fbdc8f0f4891df7b5eb643ec0a509a4ac7dcfc2e</id>
<content type='text'>
Clean up the arch read/write locking functions based on the arc
implemenation. This improves readability of those functions.

Signed-off-by: Helge Deller &lt;deller@gmx.de&gt;
</content>
</entry>
<entry>
<title>parisc: Improve interrupt handling in arch_spin_lock_flags()</title>
<updated>2020-04-05T20:16:38+00:00</updated>
<author>
<name>Helge Deller</name>
<email>deller@gmx.de</email>
</author>
<published>2020-04-05T20:08:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=2772f0efd5bbd5413db3d22e363b779ca0fa5310'/>
<id>urn:sha1:2772f0efd5bbd5413db3d22e363b779ca0fa5310</id>
<content type='text'>
Rewrite arch_spin_lock() and arch_spin_lock_flags() to not re-enable and
disable the PSW_SM_I interrupt flag too often.

Signed-off-by: Helge Deller &lt;deller@gmx.de&gt;
</content>
</entry>
<entry>
<title>parisc: Use ldcw instruction for SMP spinlock release barrier</title>
<updated>2019-05-03T21:47:40+00:00</updated>
<author>
<name>John David Anglin</name>
<email>dave.anglin@bell.net</email>
</author>
<published>2019-04-14T23:20:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=9e5c602186a692a7e848c0da17aed40f49d30519'/>
<id>urn:sha1:9e5c602186a692a7e848c0da17aed40f49d30519</id>
<content type='text'>
There are only a couple of instructions that can function as a memory
barrier on parisc.  Currently, we use the sync instruction as a memory
barrier when releasing a spinlock.  However, the ldcw instruction is a
better barrier when we have a handy memory location since it operates in
the cache on coherent machines.

This patch updates the spinlock release code to use ldcw.  I also
changed the "stw,ma" instructions to "stw" instructions as it is not an
adequate barrier.

Signed-off-by: John David Anglin &lt;dave.anglin@bell.net&gt;
Signed-off-by: Helge Deller &lt;deller@gmx.de&gt;
</content>
</entry>
<entry>
<title>parisc: Revert "Release spinlocks using ordered store"</title>
<updated>2018-11-06T11:03:22+00:00</updated>
<author>
<name>John David Anglin</name>
<email>dave.anglin@bell.net</email>
</author>
<published>2018-11-06T11:00:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=86d4d068df573a8c2105554624796c086d6bec3d'/>
<id>urn:sha1:86d4d068df573a8c2105554624796c086d6bec3d</id>
<content type='text'>
This reverts commit d27dfa13b9f77ae7e6ed09d70a0426ed26c1a8f9.

Unfortunately, this patch needs to be reverted.  We need the full sync
barrier and not the limited barrier provided by using an ordered store.
The sync ensures that all accesses and cache purge instructions that
follow the sync are performed after all such instructions prior the sync
instruction have completed executing.

The patch breaks the rwlock implementation in glibc.  This caused the
test-lock application in the libprelude testsuite to hang.  With the
change reverted, the test runs correctly and the libprelude package
builds successfully.

Signed-off-by: John David Anglin &lt;dave.anglin@bell.net&gt;
Signed-off-by: Helge Deller &lt;deller@gmx.de&gt;
</content>
</entry>
<entry>
<title>parisc: Release spinlocks using ordered store</title>
<updated>2018-10-17T06:18:01+00:00</updated>
<author>
<name>John David Anglin</name>
<email>dave.anglin@bell.net</email>
</author>
<published>2018-10-17T01:07:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=d27dfa13b9f77ae7e6ed09d70a0426ed26c1a8f9'/>
<id>urn:sha1:d27dfa13b9f77ae7e6ed09d70a0426ed26c1a8f9</id>
<content type='text'>
This patch updates the spin unlock code to use an ordered store with
release semanatics.  All prior accesses are guaranteed to be performed
before an ordered store is performed.

Using an ordered store is significantly faster than using the sync
memory barrier.

Signed-off-by: John David Anglin &lt;dave.anglin@bell.net&gt;
Signed-off-by: Helge Deller &lt;deller@gmx.de&gt;
</content>
</entry>
</feed>
