Generating dts snippets for ECDSA keys does not work properly, there are various endianess problems. As we do not need this currently for barebox drop the support for now. Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx> --- scripts/keytoc.c | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/scripts/keytoc.c b/scripts/keytoc.c index 60e177aeee..3ac42bc6d0 100644 --- a/scripts/keytoc.c +++ b/scripts/keytoc.c @@ -470,15 +470,8 @@ static int gen_key_ecdsa(EVP_PKEY *key, const char *key_name, const char *key_na return -EINVAL; if (dts) { - fprintf(outfilep, "\t\tkey-%s {\n", key_name_c); - fprintf(outfilep, "\t\t\tecdsa,x-point = <"); - print_bignum(key_x, bits); - fprintf(outfilep, ">;\n"); - fprintf(outfilep, "\t\t\tecdsa,y-point = <"); - print_bignum(key_y, bits); - fprintf(outfilep, ">;\n"); - fprintf(outfilep, "\t\t\tecdsa,curve = \"%s\";\n", group); - fprintf(outfilep, "\t\t};\n"); + fprintf(stderr, "ERROR: generating a dts snippet for ECDSA keys is not yet supported\n"); + return -EOPNOTSUPP; } else { fprintf(outfilep, "\nstatic uint32_t %s_x[] = {", key_name_c); print_bignum(key_x, bits); @@ -598,6 +591,9 @@ static int gen_key(const char *keyname, const char *path) } ret = gen_key_ecdsa(key, keyname, key_name_c); + if (ret == -EOPNOTSUPP) + return ret; + if (ret) ret = gen_key_rsa(key, keyname, key_name_c); -- 2.39.2