summaryrefslogtreecommitdiff
path: root/scripts/lib/kdoc
diff options
context:
space:
mode:
authorHerbert Xu <herbert@gondor.apana.org.au>2025-05-15 13:54:49 +0800
committerHerbert Xu <herbert@gondor.apana.org.au>2025-05-19 13:48:20 +0800
commit8e69871836669177d2d2a5acec5c8dca3319d2f1 (patch)
treeea5ba4bb0dd0227be372c6f31257ba2fe0768e17 /scripts/lib/kdoc
parent91b6ff579dda7660a9d11778f9dc4dd0a879de22 (diff)
crypto: testmgr - Ignore EEXIST on shash allocation
Soon hmac will support ahash. For compatibility hmac still supports shash so it is possible for two hmac algorithms to be registered at the same time. The shash algorithm will have the driver name "hmac-shash(XXX-driver)". Due to a quirk in the API, there is no way to locate the shash algorithm using the name "hmac(XXX-driver)". It has to be addressed as either "hmac(XXX)" or "hmac-shash(XXX-driver)". Looking it up with "hmac(XXX-driver)" will simply trigger the creation of another instance, and on the second instantiation this will fail with EEXIST. Catch the error EEXIST along with ENOENT since it is expected. If a real shash algorithm came this way, it would be addressed using the proper name "hmac-shash(XXX-driver)". Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'scripts/lib/kdoc')
0 files changed, 0 insertions, 0 deletions