2017-11-01 15:07:57 +01:00
|
|
|
/* SPDX-License-Identifier: GPL-2.0 */
|
2011-03-13 16:54:26 +08:00
|
|
|
/*
|
|
|
|
|
* CAAM Error Reporting code header
|
|
|
|
|
*
|
|
|
|
|
* Copyright 2009-2011 Freescale Semiconductor, Inc.
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#ifndef CAAM_ERROR_H
|
|
|
|
|
#define CAAM_ERROR_H
|
2018-12-21 14:47:46 +02:00
|
|
|
|
|
|
|
|
#include "desc.h"
|
|
|
|
|
|
2011-05-02 18:29:17 -05:00
|
|
|
#define CAAM_ERROR_STR_MAX 302
|
2018-09-12 11:59:32 +03:00
|
|
|
|
2019-07-31 16:08:03 +03:00
|
|
|
int caam_strstatus(struct device *dev, u32 status, bool qi_v2);
|
2018-09-12 11:59:32 +03:00
|
|
|
|
|
|
|
|
#define caam_jr_strstatus(jrdev, status) caam_strstatus(jrdev, status, false)
|
|
|
|
|
#define caam_qi2_strstatus(qidev, status) caam_strstatus(qidev, status, true)
|
2017-07-10 08:40:28 +03:00
|
|
|
|
2019-05-23 10:50:30 +02:00
|
|
|
void caam_dump_sg(const char *prefix_str, int prefix_type,
|
2017-07-10 08:40:28 +03:00
|
|
|
int rowsize, int groupsize, struct scatterlist *sg,
|
|
|
|
|
size_t tlen, bool ascii);
|
2018-12-21 14:47:46 +02:00
|
|
|
|
|
|
|
|
static inline bool is_mdha(u32 algtype)
|
|
|
|
|
{
|
|
|
|
|
return (algtype & OP_ALG_ALGSEL_MASK & ~OP_ALG_ALGSEL_SUBMASK) ==
|
|
|
|
|
OP_ALG_CHA_MDHA;
|
|
|
|
|
}
|
2011-03-13 16:54:26 +08:00
|
|
|
#endif /* CAAM_ERROR_H */
|