提交 e22cdcfa 编写于 作者: M Marek Vasut 提交者: Herbert Xu

crypto: caam - Kill SPRINTFCAT() with fire

This macro is just like an encyclopedia of string handling done wrong.
This must die. This is so wrong on so many levels.
Signed-off-by: NMarek Vasut <marex@denx.de>
Cc: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Horia Geanta <horia.geanta@freescale.com>
Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
上级 4f0fa52a
......@@ -158,16 +158,6 @@ static const char * const rng_err_id_list[] = {
"Secure key generation",
};
#define SPRINTFCAT(str, format, param, max_alloc) \
{ \
char *tmp; \
\
tmp = kmalloc(sizeof(format) + max_alloc, GFP_ATOMIC); \
sprintf(tmp, format, param); \
strcat(str, tmp); \
kfree(tmp); \
}
static void report_ccb_status(struct device *jrdev, u32 status,
const char *error, char *__outstr)
{
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册