Merge pull request #4141 from gilles-peskine-arm/psa-test-functions-lift

Lift some PSA test functions to a separate module