[4/8] efi/capsule: Adjust return type of efi_capsule_setup_info

Message ID 20170405092317.27921-5-ard.biesheuvel@linaro.org
State New
Headers show
Series
  • efi: add support for non-standard capsule headers
Related show

Commit Message

Ard Biesheuvel April 5, 2017, 9:23 a.m.
From: Jan Kiszka <jan.kiszka@siemens.com>


We actually expect int at the caller and never return any size
information.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>

Cc: Matt Fleming <matt@codeblueprint.co.uk>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>

---
 drivers/firmware/efi/capsule-loader.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

-- 
2.9.3

--
To unsubscribe from this list: send the line "unsubscribe linux-efi" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

Matt Fleming April 18, 2017, 12:33 p.m. | #1
On Wed, 05 Apr, at 10:23:13AM, Ard Biesheuvel wrote:
> From: Jan Kiszka <jan.kiszka@siemens.com>

> 

> We actually expect int at the caller and never return any size

> information.

> 

> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>

> Cc: Matt Fleming <matt@codeblueprint.co.uk>

> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>

> ---

>  drivers/firmware/efi/capsule-loader.c | 4 ++--

>  1 file changed, 2 insertions(+), 2 deletions(-)


Reviewed-by: Matt Fleming <matt@codeblueprint.co.uk>

--
To unsubscribe from this list: send the line "unsubscribe linux-efi" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Patch

diff --git a/drivers/firmware/efi/capsule-loader.c b/drivers/firmware/efi/capsule-loader.c
index 3fb91e1597a9..37d3f6ec2d28 100644
--- a/drivers/firmware/efi/capsule-loader.c
+++ b/drivers/firmware/efi/capsule-loader.c
@@ -53,8 +53,8 @@  static void efi_free_all_buff_pages(struct capsule_info *cap_info)
  * @kbuff: a mapped first page buffer pointer
  * @hdr_bytes: the total received number of bytes for efi header
  **/
-static ssize_t efi_capsule_setup_info(struct capsule_info *cap_info,
-				      void *kbuff, size_t hdr_bytes)
+static int efi_capsule_setup_info(struct capsule_info *cap_info,
+				  void *kbuff, size_t hdr_bytes)
 {
 	efi_capsule_header_t *cap_hdr;
 	size_t pages_needed;