OSDN Git Service

target/arm: New function allocation_tag_mem_probe()
authorPeter Maydell <peter.maydell@linaro.org>
Tue, 12 Sep 2023 14:04:27 +0000 (15:04 +0100)
committerPeter Maydell <peter.maydell@linaro.org>
Thu, 21 Sep 2023 15:07:14 +0000 (16:07 +0100)
commitaa03378bccb1138cb6a3d5a8c91b11feda036188
tree5bb391500282a2b9fe40a54315ae9c2e0c777a69
parent31aaaddecb36c17eeeb991e2124de5132df18af9
target/arm: New function allocation_tag_mem_probe()

For the FEAT_MOPS operations, the existing allocation_tag_mem()
function almost does what we want, but it will take a watchpoint
exception even for an ra == 0 probe request, and it requires that the
caller guarantee that the memory is accessible.  For FEAT_MOPS we
want a function that will not take any kind of exception, and will
return NULL for the not-accessible case.

Rename allocation_tag_mem() to allocation_tag_mem_probe() and add an
extra 'probe' argument that lets us distinguish these cases;
allocation_tag_mem() is now a wrapper that always passes 'false'.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20230912140434.1333369-6-peter.maydell@linaro.org
target/arm/tcg/mte_helper.c