firmware/2lib/include/2secdata.h
/*
 * Helper function to check if hwcrypto is allowed.
 */
Helper function to check if hwcrypto is allowed.
Helper function to check if hwcrypto is allowed .
static inline int vb2_hwcrypto_allowed(struct vb2_context *ctx)
{
	if (ctx->flags & VB2_CONTEXT_RECOVERY_MODE)
		return 0;
	if (vb2_secdata_kernel_get(ctx, VB2_SECDATA_KERNEL_FLAGS)
				& VB2_SECDATA_KERNEL_FLAG_HWCRYPTO_ALLOWED)
		return 1;
	return 0;
}
static inline int vb2_hwcrypto_allowed ( struct vb2_context * ctx ) { if ( ctx -> flags & VB2_CONTEXT_RECOVERY_MODE ) return 0 ; if ( vb2_secdata_kernel_get ( ctx , VB2_SECDATA_KERNEL_FLAGS ) & VB2_SECDATA_KERNEL_FLAG_HWCRYPTO_ALLOWED ) return 1 ; return 0 ; }
Helper function to check if hwcrypto is allowed.
Helper function to check if hwcrypto is allowed .
/* disable hwcrypto in recovery mode */ /* enable hwcrypto only if RW firmware set the flag */