riscv-openocd/src
Jonathan Bell ee87f2b4a9 jtag/drivers: bcm2835gpio: implement memory barriers when bitbashing
This GPIO driver is common to SoCs that have in-order ARM cores
(BCM2835) as well as superscalar (BCM2836-7) and speculative
out-of-order cores (BCM2711).

For BCM2837 and BCM2711, the processor can dual-issue stores and
is free to merge writes to peripheral memory for pages mapped
MT_NORMAL_NC, which is the default provided by /dev/[gpio]mem.

This can cause glitches (or missing edges) on GPIO pins when
toggled with no delay, as pipelined writes to the same address
can get arbitrarily squelched.

To prevent this happening, make sure the preceding write ops are
flushed outside the shareable domain by using a memory barrier.

Signed-off-by: Jonathan Bell <jonathan@raspberrypi.com>
Change-Id: I8805cc0911667bcb9b7f4ca340d7f4f1cb25d096
Reviewed-on: https://review.openocd.org/c/openocd/+/7258
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
2022-10-21 18:05:41 +00:00
..
flash flash/nor/at91samd: Use 32-bit register writes for ST-Link compat 2022-10-08 07:52:28 +00:00
helper openocd: fix SPDX tag format for files .c 2022-09-18 08:22:01 +00:00
jtag jtag/drivers: bcm2835gpio: implement memory barriers when bitbashing 2022-10-21 18:05:41 +00:00
pld fix leaky file-handle in virtex2 driver 2022-10-08 07:54:49 +00:00
rtos Remove duplicate of a counter in hwthread_update_threads 2022-10-08 07:52:12 +00:00
rtt openocd: fix SPDX tag format for files .c 2022-09-18 08:22:01 +00:00
server openocd: fix SPDX tag format for files .c 2022-09-18 08:22:01 +00:00
svf openocd: fix SPDX tag format for files .c 2022-09-18 08:22:01 +00:00
target target/xtensa: fill register number field in the cache 2022-10-15 15:58:44 +00:00
transport openocd: fix SPDX tag format for files .c 2022-09-18 08:22:01 +00:00
xsvf openocd: fix SPDX tag format for files .c 2022-09-18 08:22:01 +00:00
Makefile.am openocd: build: add SPDX tag 2022-07-23 13:06:38 +00:00
hello.c openocd: fix SPDX tag format for files .c 2022-09-18 08:22:01 +00:00
hello.h openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00
main.c openocd: fix SPDX tag format for files .c 2022-09-18 08:22:01 +00:00
openocd.c openocd: fix SPDX tag format for files .c 2022-09-18 08:22:01 +00:00
openocd.h openocd: src: replace the GPL-2.0-or-later license tag 2022-07-23 13:59:13 +00:00