summaryrefslogtreecommitdiff
path: root/include/linux/debugobjects.h
diff options
context:
space:
mode:
authorChen-Yu Tsai <wens@kernel.org>2026-03-24 19:43:52 +0300
committerChen-Yu Tsai <wens@kernel.org>2026-04-27 18:25:35 +0300
commit67890da74dd1b85a47769561bfc6e0c542762d45 (patch)
tree6ba8fe551f1de2629696036dc3208a2fb0a3c2a8 /include/linux/debugobjects.h
parent7765752f528b5b516d8cdf94faaabcba935dff41 (diff)
downloadlinux-67890da74dd1b85a47769561bfc6e0c542762d45.tar.xz
soc: sunxi: sram: Allow SRAM to be claimed multiple times
On the H616, the SRAM C region is an alias mapping to part of the VE SRAM (accessible in whole at a different address) and part of the DE SRAM (otherwise unaccessible). As such both the VE and DE need to claim this SRAM region to prevent access from the CPU. The SRAM claim API is designed so that a "claim" routes the SRAM to the peripheral device, disabling access from the CPU. So long as the written register value is the same for all the claimants involved, allowing multiple or repeated claims is trivial. This is indeed the case for all supported SRAM regions. The only known SRAM region to have multiple different settings is the SRAM C2 region; this can be claimed by the AE, CE, or ACE (assumed to be AE + CE). This region is not supported, and likely will never be needed nor supported, as there is no documentation for the peripherals involved. Change the SRAM region "claimed" field from a boolean to a reference count. A claim will increment the count, while a release decreases it. The first claim will trigger the register value write. The driver otherwise behaves as before. Reviewed-by: Jernej Skrabec <jernej.skrabec@gmail.com> Link: https://patch.msgid.link/20260324164357.1607247-5-wens@kernel.org Signed-off-by: Chen-Yu Tsai <wens@kernel.org>
Diffstat (limited to 'include/linux/debugobjects.h')
0 files changed, 0 insertions, 0 deletions