<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/hwspinlock, branch v5.15.7</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v5.15.7</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v5.15.7'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2021-05-28T03:19:42+00:00</updated>
<entry>
<title>hwspinlock: add sun6i hardware spinlock support</title>
<updated>2021-05-28T03:19:42+00:00</updated>
<author>
<name>Wilken Gottwalt</name>
<email>wilken.gottwalt@posteo.net</email>
</author>
<published>2021-03-14T09:31:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3c881e05c814c970e4f9577446a9d3461d134607'/>
<id>urn:sha1:3c881e05c814c970e4f9577446a9d3461d134607</id>
<content type='text'>
Adds the sun6i_hwspinlock driver for the hardware spinlock unit found in
most of the sun6i compatible SoCs.

This unit provides at least 32 spinlocks in hardware. The implementation
supports 32, 64, 128 or 256 32bit registers. A lock can be taken by
reading a register and released by writing a 0 to it. This driver
supports all 4 spinlock setups, but for now only the first setup (32
locks) seem to exist in available devices. This spinlock unit is shared
between all ARM cores and the embedded companion core. All of them can
take/release a lock with a single cycle operation. It can be used to
sync access to devices shared by the ARM cores and the companion core.

There are two ways to check if a lock is taken. The first way is to read
a lock. If a 0 is returned, the lock was free and is taken now. If an 1
is returned, the caller has to try again. Which means the lock is taken.
The second way is to read a 32bit wide status register where every bit
represents one of the 32 first locks. According to the datasheets this
status register supports only the 32 first locks. This is the reason the
first way (lock read/write) approach is used to be able to cover all 256
locks in future devices. The driver also reports the amount of supported
locks via debugfs.

Reviewed-by: Samuel Holland &lt;samuel@sholland.org&gt;
Acked-by: Maxime Ripard &lt;maxime@cerno.tech&gt;
Signed-off-by: Wilken Gottwalt &lt;wilken.gottwalt@posteo.net&gt;
Link: https://lore.kernel.org/r/bfd2b97307c2321b15c09683f4bd5e1fcc792f13.1615713499.git.wilken.gottwalt@posteo.net
Signed-off-by: Bjorn Andersson &lt;bjorn.andersson@linaro.org&gt;
</content>
</entry>
<entry>
<title>hwspinlock: remove sirf driver</title>
<updated>2021-03-18T02:22:06+00:00</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2021-01-20T13:25:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=1cb8f3e2d8fe7533c26df9925a83bd3d185b312e'/>
<id>urn:sha1:1cb8f3e2d8fe7533c26df9925a83bd3d185b312e</id>
<content type='text'>
The CSR SiRF prima2/atlas platforms are getting removed, so this driver
is no longer needed.

Cc: Barry Song &lt;baohua@kernel.org&gt;
Link: https://lore.kernel.org/linux-arm-kernel/20210120124812.2800027-1-arnd@kernel.org/T/
Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Link: https://lore.kernel.org/r/20210120132537.2285157-1-arnd@kernel.org
Signed-off-by: Bjorn Andersson &lt;bjorn.andersson@linaro.org&gt;
</content>
</entry>
<entry>
<title>hwspinlock: omap: Add support for K3 AM64x SoCs</title>
<updated>2021-02-09T17:36:50+00:00</updated>
<author>
<name>Suman Anna</name>
<email>s-anna@ti.com</email>
</author>
<published>2021-02-09T17:22:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=b9ddb2500e7e544410f38476ab928fc2fe01e381'/>
<id>urn:sha1:b9ddb2500e7e544410f38476ab928fc2fe01e381</id>
<content type='text'>
The AM64x SoC contains a HwSpinlock IP instance in the MAIN domain,
and is a minor variant of the IP on the current TI K3 SoCs such as
AM64x, J721E or J7200 SoCs. The IP is not built with the K3 safety
feature in hardware, and has slightly different integration into
the overall SoC.

Add the support for this IP through a new compatible.

Signed-off-by: Suman Anna &lt;s-anna@ti.com&gt;
Link: https://lore.kernel.org/r/20210209172240.2305-3-s-anna@ti.com
Signed-off-by: Bjorn Andersson &lt;bjorn.andersson@linaro.org&gt;
</content>
</entry>
<entry>
<title>hwspinlock: sirf: Remove the redundant 'of_match_ptr'</title>
<updated>2020-12-10T19:34:40+00:00</updated>
<author>
<name>Baolin Wang</name>
<email>baolin.wang7@gmail.com</email>
</author>
<published>2020-06-08T12:20:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=c3e9b463b41b45c4556a13043265097e2184226e'/>
<id>urn:sha1:c3e9b463b41b45c4556a13043265097e2184226e</id>
<content type='text'>
Remove the the redundant 'of_match_ptr' macro to fix below warning
when the CONFIG_OF is not selected.

All warnings:
drivers/hwspinlock/sirf_hwspinlock.c:87:34: warning: unused variable
'sirf_hwpinlock_ids' [-Wunused-const-variable]

Reported-by: kernel test robot &lt;lkp@intel.com&gt;
Signed-off-by: Baolin Wang &lt;baolin.wang7@gmail.com&gt;
Link: https://lore.kernel.org/r/250d35cb489c3c4c066f7ce256d27f36712a1979.1591618255.git.baolin.wang7@gmail.com
Signed-off-by: Bjorn Andersson &lt;bjorn.andersson@linaro.org&gt;
</content>
</entry>
<entry>
<title>hwspinlock: sprd: fixed warning of unused variable 'sprd_hwspinlock_of_match'</title>
<updated>2020-11-18T03:42:13+00:00</updated>
<author>
<name>Chunyan Zhang</name>
<email>chunyan.zhang@unisoc.com</email>
</author>
<published>2020-11-12T07:04:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=8266b809264caa23038ceab2811fc452cf936e84'/>
<id>urn:sha1:8266b809264caa23038ceab2811fc452cf936e84</id>
<content type='text'>
The macro function of_match_ptr() is NULL if CONFIG_OF is not set, in this
case Clang compiler would complain the of_device_id variable is unused.

Reviewed-by: Baolin Wang &lt;baolin.wang7@gmail.com&gt;
Reported-by: kernel test robot &lt;lkp@intel.com&gt;
Fixes: d8c8bbbb1aba ("hwspinlock: sprd: Add hardware spinlock driver")
Signed-off-by: Chunyan Zhang &lt;chunyan.zhang@unisoc.com&gt;
Link: https://lore.kernel.org/r/20201112070410.14810-1-zhang.lyra@gmail.com
Signed-off-by: Bjorn Andersson &lt;bjorn.andersson@linaro.org&gt;
</content>
</entry>
<entry>
<title>hwspinlock: sprd: use module_platform_driver() instead postcore initcall</title>
<updated>2020-11-03T00:04:06+00:00</updated>
<author>
<name>Chunyan Zhang</name>
<email>chunyan.zhang@unisoc.com</email>
</author>
<published>2020-10-30T03:46:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=8308678ebde1cbca9fb628ba2e7b6e4ea0b15acf'/>
<id>urn:sha1:8308678ebde1cbca9fb628ba2e7b6e4ea0b15acf</id>
<content type='text'>
The hardware spinlock devices are defined in the DT, there's no need for
init calls order, remove boilerplate code by using module_platform_driver.

Reviewed-by: Baolin Wang &lt;baolin.wang7@gmail.com&gt;
Signed-off-by: Chunyan Zhang &lt;chunyan.zhang@unisoc.com&gt;
Link: https://lore.kernel.org/r/20201030034654.15775-3-zhang.lyra@gmail.com
Signed-off-by: Bjorn Andersson &lt;bjorn.andersson@linaro.org&gt;
</content>
</entry>
<entry>
<title>hwspinlock: sprd: Remove redundant header files</title>
<updated>2020-10-26T15:17:54+00:00</updated>
<author>
<name>Baolin Wang</name>
<email>baolin.wang@linux.alibaba.com</email>
</author>
<published>2020-06-01T06:05:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3116a9931fa6fa067986a2cb0cc447c58530b1f0'/>
<id>urn:sha1:3116a9931fa6fa067986a2cb0cc447c58530b1f0</id>
<content type='text'>
Remove redundant header files.

Signed-off-by: Baolin Wang &lt;baolin.wang@linux.alibaba.com&gt;
Link: https://lore.kernel.org/r/1590991552-93643-1-git-send-email-baolin.wang@linux.alibaba.com
Signed-off-by: Bjorn Andersson &lt;bjorn.andersson@linaro.org&gt;
</content>
</entry>
<entry>
<title>hwspinlock: qcom: Allow mmio usage in addition to syscon</title>
<updated>2020-07-14T05:29:28+00:00</updated>
<author>
<name>Bjorn Andersson</name>
<email>bjorn.andersson@linaro.org</email>
</author>
<published>2020-06-22T07:59:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=7a1e6fb1c606d414320b7498e7f8357d73c972e5'/>
<id>urn:sha1:7a1e6fb1c606d414320b7498e7f8357d73c972e5</id>
<content type='text'>
In modern Qualcomm platforms the mutex region of the TCSR is forked off
into its own block, all with a offset of 0 and stride of 4096, and in
some of these platforms no other registers in this region is accessed
from Linux.

So add support for directly memory mapping this register space, to avoid
the need to represent this block using a syscon.

Reviewed-by: Baolin Wang &lt;baolin.wang7@gmail.com&gt;
Reviewed-by: Vinod Koul &lt;vkoul@kernel.org&gt;
Signed-off-by: Bjorn Andersson &lt;bjorn.andersson@linaro.org&gt;
Link: https://lore.kernel.org/r/20200622075956.171058-4-bjorn.andersson@linaro.org
Signed-off-by: Bjorn Andersson &lt;bjorn.andersson@linaro.org&gt;
</content>
</entry>
<entry>
<title>hwspinlock: Simplify Kconfig</title>
<updated>2020-06-21T07:36:03+00:00</updated>
<author>
<name>Ezequiel Garcia</name>
<email>ezequiel@collabora.com</email>
</author>
<published>2020-04-14T22:09:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=285e74ab4f94d921a56fcf66320b3cd65e35b6bc'/>
<id>urn:sha1:285e74ab4f94d921a56fcf66320b3cd65e35b6bc</id>
<content type='text'>
Every hwspinlock driver is expected to depend on the
hwspinlock core, so it's possible to simplify the
Kconfig, factoring out the HWSPINLOCK dependency.

Reviewed-by: Baolin Wang &lt;baolin.wang7@gmail.com&gt;
Signed-off-by: Ezequiel Garcia &lt;ezequiel@collabora.com&gt;
Link: https://lore.kernel.org/r/20200414220943.6203-1-ezequiel@collabora.com
Signed-off-by: Bjorn Andersson &lt;bjorn.andersson@linaro.org&gt;
</content>
</entry>
<entry>
<title>hwspinlock: hwspinlock_internal.h: Replace zero-length array with flexible-array member</title>
<updated>2020-03-26T05:30:46+00:00</updated>
<author>
<name>Gustavo A. R. Silva</name>
<email>gustavo@embeddedor.com</email>
</author>
<published>2020-03-19T21:38:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ef17f5193edd42e8913c93d0b601c101c56a15bb'/>
<id>urn:sha1:ef17f5193edd42e8913c93d0b601c101c56a15bb</id>
<content type='text'>
The current codebase makes use of the zero-length array language
extension to the C90 standard, but the preferred mechanism to declare
variable-length types such as these ones is a flexible array member[1][2],
introduced in C99:

struct foo {
        int stuff;
        struct boo array[];
};

By making use of the mechanism above, we will get a compiler warning
in case the flexible array does not occur last in the structure, which
will help us prevent some kind of undefined behavior bugs from being
inadvertently introduced[3] to the codebase from now on.

Also, notice that, dynamic memory allocations won't be affected by
this change:

"Flexible array members have incomplete type, and so the sizeof operator
may not be applied. As a quirk of the original implementation of
zero-length arrays, sizeof evaluates to zero."[1]

This issue was found with the help of Coccinelle.

[1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html
[2] https://github.com/KSPP/linux/issues/21
[3] commit 76497732932f ("cxgb3/l2t: Fix undefined behaviour")

Reviewed-by: Baolin Wang &lt;baolin.wang7@gmail.com&gt;
Signed-off-by: Gustavo A. R. Silva &lt;gustavo@embeddedor.com&gt;
Link: https://lore.kernel.org/r/20200319213839.GA10669@embeddedor.com
Signed-off-by: Bjorn Andersson &lt;bjorn.andersson@linaro.org&gt;
</content>
</entry>
</feed>
