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]
Date:   Tue, 31 Jan 2023 13:49:36 +0000
From:   Niall Leonard via B4 Submission Endpoint 
        <devnull+nl250060.ncr.com@...nel.org>
To:     Linus Walleij <linus.walleij@...aro.org>,
        Bartosz Golaszewski <brgl@...ev.pl>,
        Rob Herring <robh+dt@...nel.org>,
        Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>
Cc:     linux-gpio@...r.kernel.org, devicetree@...r.kernel.org,
        linux-kernel@...r.kernel.org, Niall Leonard <nl250060@....com>
Subject: [PATCH v2 0/2] Introduce new optional property to mark port as
 write only.

Some electronics do not allow the data regsister to be read without
corrupting the existing data on the port. It a quirk of the board
design.
e.g. I have a couple of boards where the electronics engineer decided 
to only use the chip select line, so no read/write signal is connected. 
This means that reading the address activates the chip select and drives 
the contents of the data bus to the port.This makes it impossible to 
read the last data written to the port.

This solution is to use the existing shadow data register 'bgpio_data'.
It  can be used to return the last value written to the port by the read 
operation.
 
This is enabled for a particular port using a new flag and a new
device tree property "no-input" to allow it to be selected on a board by 
board basis. This means it will only effect hardware that requests it.

Signed-off-by: Niall Leonard <nl250060@....com>
---
Changes in v2:
- Description of change updated to clarify why it is needed.
- Patches squashed as per request during review.
- wd,mbl-gpio bindings updated to yaml format.
- Link to v1: https://lore.kernel.org/r/20230126-gpio-mmio-fix-v1-0-8a20ce0e8275@ncr.com

---
Niall Leonard (2):
      dt-bindings: improve wb,mbl-gpio binding documentation.
      gpio: mmio: Use new flag BGPIOF_NO_INPUT.

 .../devicetree/bindings/gpio/wd,mbl-gpio.txt       | 38 -----------
 .../devicetree/bindings/gpio/wd,mbl-gpio.yaml      | 78 ++++++++++++++++++++++
 drivers/gpio/gpio-mmio.c                           | 24 ++++++-
 include/linux/gpio/driver.h                        |  1 +
 4 files changed, 100 insertions(+), 41 deletions(-)
---
base-commit: 1b929c02afd37871d5afb9d498426f83432e71c2
change-id: 20230126-gpio-mmio-fix-1a69d03ec9e7

Best regards,
-- 
Niall Leonard <nl250060@....com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ