Hi Christian,
We are planning to add a pk-like parsing interface to PSA. See https://github.com/ARM-software/psa-api/issues/44 and https://github.com/Mbed-TLS/mbedtls/pull/7910.
Unfortunately, due to resource constraints, this API will not be available until Mbed TLS 4.0 (if not 4.1). In the meantime, when Mbed TLS is built with MBEDTLS_USE_PSA_CRYPTO, you can use mbedtls_pk_parse_key and friends to parse a key, then construct a PSA key from that. See https://github.com/Mbed-TLS/mbedtls/pull/7766 for some tips in transitioning from the legacy crypto API to PSA, with code fragments. This is somewhat cumbersome, and we do plan to improve the situation in Mbed TLS 3.6 by providing better bridges between PK and PSA. We haven't yet finalized the design there, so please feel free to open a feature request on GitHub if there isn't already an issue that covers your use case.
By the way, the reason this happens to work with RSA keys, but not with EC keys, is that PSA uses the smallest sensible input format. For RSA keys, there are multiple numbers to encode and the smallest sensible format is an ASN.1 format that is “high-level” enough for pkparse. PSA does not support PEM imports, but this just happens to work because the PSA code calls a lower-level function that also tries to parse PEM. With EC keys, the smallest sensible format is just the private value (for private keys) or a compact encoding of the two coordinates (for public keys), and this doesn't contain enough metadata for pkparse to support it.
Best regards,