* [PATCH 1/1] efi/capsule-loader: superfluous assignment
@ 2020-02-23 20:54 Heinrich Schuchardt
2020-02-23 21:24 ` Ard Biesheuvel
0 siblings, 1 reply; 2+ messages in thread
From: Heinrich Schuchardt @ 2020-02-23 20:54 UTC (permalink / raw)
To: Ard Biesheuvel; +Cc: linux-efi, linux-kernel, Heinrich Schuchardt
In efi_capsule_write() the value 0 assigned to ret is never used.
Identified with cppcheck.
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
---
drivers/firmware/efi/capsule-loader.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/firmware/efi/capsule-loader.c b/drivers/firmware/efi/capsule-loader.c
index d3067cbd5114..4dde8edd53b6 100644
--- a/drivers/firmware/efi/capsule-loader.c
+++ b/drivers/firmware/efi/capsule-loader.c
@@ -168,7 +168,7 @@ static ssize_t efi_capsule_submit_update(struct capsule_info *cap_info)
static ssize_t efi_capsule_write(struct file *file, const char __user *buff,
size_t count, loff_t *offp)
{
- int ret = 0;
+ int ret;
struct capsule_info *cap_info = file->private_data;
struct page *page;
void *kbuff = NULL;
--
2.25.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 1/1] efi/capsule-loader: superfluous assignment
2020-02-23 20:54 [PATCH 1/1] efi/capsule-loader: superfluous assignment Heinrich Schuchardt
@ 2020-02-23 21:24 ` Ard Biesheuvel
0 siblings, 0 replies; 2+ messages in thread
From: Ard Biesheuvel @ 2020-02-23 21:24 UTC (permalink / raw)
To: Heinrich Schuchardt; +Cc: linux-efi, Linux Kernel Mailing List
On Sun, 23 Feb 2020 at 21:54, Heinrich Schuchardt <xypron.glpk@gmx.de> wrote:
>
> In efi_capsule_write() the value 0 assigned to ret is never used.
>
> Identified with cppcheck.
>
> Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Queued in efi/next, thanks
> ---
> drivers/firmware/efi/capsule-loader.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/firmware/efi/capsule-loader.c b/drivers/firmware/efi/capsule-loader.c
> index d3067cbd5114..4dde8edd53b6 100644
> --- a/drivers/firmware/efi/capsule-loader.c
> +++ b/drivers/firmware/efi/capsule-loader.c
> @@ -168,7 +168,7 @@ static ssize_t efi_capsule_submit_update(struct capsule_info *cap_info)
> static ssize_t efi_capsule_write(struct file *file, const char __user *buff,
> size_t count, loff_t *offp)
> {
> - int ret = 0;
> + int ret;
> struct capsule_info *cap_info = file->private_data;
> struct page *page;
> void *kbuff = NULL;
> --
> 2.25.0
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-02-23 21:25 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-23 20:54 [PATCH 1/1] efi/capsule-loader: superfluous assignment Heinrich Schuchardt
2020-02-23 21:24 ` Ard Biesheuvel
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).