mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH 4/5] rsa: fix typos and missing type definitions
Date: Thu, 21 Sep 2023 12:23:09 +0200	[thread overview]
Message-ID: <20230921102310.1108543-5-a.fatoum@pengutronix.de> (raw)
In-Reply-To: <20230921102310.1108543-1-a.fatoum@pengutronix.de>

Including <rsa.h> as first header shows some that some includes are
missing and looking into the file, the kerneldoc comment is out of date.
Fix both.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 include/rsa.h | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/include/rsa.h b/include/rsa.h
index 650fb234f263..f1e3c1b6c366 100644
--- a/include/rsa.h
+++ b/include/rsa.h
@@ -12,6 +12,7 @@
 #ifndef _RSA_H
 #define _RSA_H
 
+#include <linux/types.h>
 #include <errno.h>
 #include <digest.h>
 
@@ -38,10 +39,10 @@ struct rsa_public_key {
  * Verify a RSA PKCS1.5 signature against an expected hash.
  *
  * @info:	Specifies key and FIT information
- * @data:	Pointer to the input data
- * @data_len:	Data length
  * @sig:	Signature
  * @sig_len:	Number of bytes in signature
+ * @hash:	hash over payload
+ * @algo:	hashing algo
  * @return 0 if verified, -ve on error
  */
 int rsa_verify(const struct rsa_public_key *key, const uint8_t *sig,
@@ -51,6 +52,8 @@ int rsa_verify(const struct rsa_public_key *key, const uint8_t *sig,
 /* This is the maximum signature length that we support, in bits */
 #define RSA_MAX_SIG_BITS	4096
 
+struct device_node;
+
 struct rsa_public_key *rsa_of_read_key(struct device_node *node);
 void rsa_key_free(struct rsa_public_key *key);
 const struct rsa_public_key *rsa_get_key(const char *name);
-- 
2.39.2




  parent reply	other threads:[~2023-09-21 10:24 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-21 10:23 [PATCH 0/5] rsatoc: make useful for standalone RSA keys Ahmad Fatoum
2023-09-21 10:23 ` [PATCH 1/5] rsa: escape pkcs11 string passed to RSA command Ahmad Fatoum
2023-09-21 10:23 ` [PATCH 2/5] scripts: allow user to build rsatoc if COMPILE_HOST_TOOLS Ahmad Fatoum
2023-09-21 10:23 ` [PATCH 3/5] rsatoc: support extracting RSA public key from X.509 SPKI format Ahmad Fatoum
2023-09-21 10:23 ` Ahmad Fatoum [this message]
2023-09-21 10:23 ` [PATCH 5/5] rsatoc: support generating standalone keys unreferenced by FIT keyring Ahmad Fatoum
2023-09-21 12:32 ` [PATCH 0/5] rsatoc: make useful for standalone RSA keys Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230921102310.1108543-5-a.fatoum@pengutronix.de \
    --to=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox