X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=include%2Flinux%2Fccp.h;h=7f437036baa4bec9efa4fd1f8b619f9849889218;hb=c9f21cb6388898bfe69886d001316dae7ecc9a4b;hp=ebcc9d1462198d990a9a473f0fecd435045f7b53;hpb=413e55742a4f18da6173271ca66748e690997f30;p=deliverable%2Flinux.git diff --git a/include/linux/ccp.h b/include/linux/ccp.h index ebcc9d146219..7f437036baa4 100644 --- a/include/linux/ccp.h +++ b/include/linux/ccp.h @@ -26,6 +26,13 @@ struct ccp_cmd; #if defined(CONFIG_CRYPTO_DEV_CCP_DD) || \ defined(CONFIG_CRYPTO_DEV_CCP_DD_MODULE) +/** + * ccp_present - check if a CCP device is present + * + * Returns zero if a CCP device is present, -ENODEV otherwise. + */ +int ccp_present(void); + /** * ccp_enqueue_cmd - queue an operation for processing by the CCP * @@ -53,6 +60,11 @@ int ccp_enqueue_cmd(struct ccp_cmd *cmd); #else /* CONFIG_CRYPTO_DEV_CCP_DD is not enabled */ +static inline int ccp_present(void) +{ + return -ENODEV; +} + static inline int ccp_enqueue_cmd(struct ccp_cmd *cmd) { return -ENODEV;