Thread (2 messages) 2 messages, 2 authors, 2026-01-24

Re: [PATCH v6 1/6] dt-bindings: gpio-mmio: Correct opencores GPIO

From: Gary Lau <hidden>
Date: 2026-01-23 14:18:14
Also in: linux-gpio, lkml

Hi Stafford,

I should clarify my setup: I'm using hardware address translation to make the
OpenCores 8-bit GPIO appear as 32-bit to the CPU. Specifically:

1. Address translation: The CPU's 32-bit addresses are right-shifted by 2 bits
   (adr_i[2] in Verilog), so each 32-bit CPU access maps to the correct 8-bit
   OpenCores register.

2. Data width adaptation: Only dat_i[7:0] and dat_o[7:0] are connected, so
   32-bit writes are truncated to 8-bit, and reads are zero-extended.

This hardware wrapper makes brcm,bcm6345-gpio driver "work" with my OpenCores
GPIO, but it's really a hardware-level compatibility layer, not true software
compatibility.

So you're absolutely right that the native opencores,gpio isn't compatible
with brcm,bcm6345-gpio. My setup works because of custom hardware translation,
not because the IP cores are compatible.

Best regards,
Gary






Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help