lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <cover.1607094989.git.wilken.gottwalt@posteo.net>
Date:   Fri, 4 Dec 2020 16:33:46 +0100
From:   Wilken Gottwalt <wilken.gottwalt@...teo.net>
To:     linux-kernel@...r.kernel.org
Cc:     Ohad Ben-Cohen <ohad@...ery.com>,
        Bjorn Andersson <bjorn.andersson@...aro.org>,
        Baolin Wang <baolin.wang7@...il.com>,
        Rob Herring <robh+dt@...nel.org>,
        Maxime Ripard <mripard@...nel.org>,
        Chen-Yu Tsai <wens@...e.org>,
        Jernej Skrabec <jernej.skrabec@...l.net>
Subject: [PATCH v2 0/2] hwspinlock: add sunxi hardware spinlock support

Most of the Allwinner sun8i and sun50i based SoCs contain a spinlock
unit which can be used to sync access to devices shared between the ARM
cores in the embedded OpenRisc (AR100) core. This spinlock unit is
included in the A83T, A64, H2+, H3, H5 and H6 SoCs and according to the
datasheets support at least 32 spinlocks. The implementation supports
32, 64, 128 and 256 spinlock setups, but there is no known SoC yet,
which supports more the 32.

This driver adds support for this hardware spinlock unit to Linux
including all 4 possible setups. The driver reports the found setup via
debugfs. It can be build as a builtin and normal module by using the
HWSPINLOCK_SUNXI symbol.

This driver is the first step to enable hwspinlock support in Linux,
but also needs support on the OpenRisc core side in the crust firmware.
This patch provides the driver and binding documentation but is not yet
included into the sun8i and sun50i dtsi files. Also not every sun8i or
sun50i SoC seem to have support for this hardware. For example the H616
is missing the whole spinlock section in the datasheets.

This patch adds:
- hwspinlock driver sunxi_hwspinlock
- updates makefiles
- hwspinlock dt bindings documentation
- updates MAINTAINERS

Signed-off-by: Wilken Gottwalt <wilken.gottwalt@...teo.net>

Changes in v2:
  - redone coverletter
  - fixed ranges in the device tree description
  - added suggestions from Bjorn Andersson and Maxime Ripard to the driver
  - provided better driver and test description

Wilken Gottwalt (2):
  dt-bindings: hwlock: sunxi: add sunxi_hwspinlock documentation
  hwspinlock: add sunxi hardware spinlock support

 .../bindings/hwlock/sunxi-hwspinlock.yaml     |  64 +++++
 MAINTAINERS                                   |   6 +
 drivers/hwspinlock/Kconfig                    |   9 +
 drivers/hwspinlock/Makefile                   |   1 +
 drivers/hwspinlock/sunxi_hwspinlock.c         | 234 ++++++++++++++++++
 5 files changed, 314 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/hwlock/sunxi-hwspinlock.yaml
 create mode 100644 drivers/hwspinlock/sunxi_hwspinlock.c

-- 
2.29.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ