MCPcopy Create free account
hub / github.com/F-Stack/f-stack / crypto_find_device_byhid

Function crypto_find_device_byhid

freebsd/opencrypto/crypto.c:1082–1095  ·  view source on GitHub ↗

* Return the device_t for the specified driver or NULL * if the driver identifier is invalid. */

Source from the content-addressed store, hash-verified

1080 * if the driver identifier is invalid.
1081 */
1082device_t
1083crypto_find_device_byhid(int hid)
1084{
1085 struct cryptocap *cap;
1086 device_t dev;
1087
1088 dev = NULL;
1089 CRYPTO_DRIVER_LOCK();
1090 cap = crypto_checkdriver(hid);
1091 if (cap != NULL)
1092 dev = cap->cc_dev;
1093 CRYPTO_DRIVER_UNLOCK();
1094 return (dev);
1095}
1096
1097/*
1098 * Return the device/driver capabilities.

Callers 1

cryptodev_findFunction · 0.85

Calls 1

crypto_checkdriverFunction · 0.85

Tested by

no test coverage detected