Patch "um: vector: fix bpfflash parameter evaluation" has been added to the 5.15-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    um: vector: fix bpfflash parameter evaluation

to the 5.15-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     um-vector-fix-bpfflash-parameter-evaluation.patch
and it can be found in the queue-5.15 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 142af4f21a32276690a6c3e5afec039e11e410a4
Author: Johannes Berg <johannes.berg@xxxxxxxxx>
Date:   Thu Mar 28 10:06:36 2024 +0100

    um: vector: fix bpfflash parameter evaluation
    
    [ Upstream commit 584ed2f76ff5fe360d87a04d17b6520c7999e06b ]
    
    With W=1 the build complains about a pointer compared to
    zero, clearly the result should've been compared.
    
    Fixes: 9807019a62dc ("um: Loadable BPF "Firmware" for vector drivers")
    Signed-off-by: Johannes Berg <johannes.berg@xxxxxxxxx>
    Reviewed-by: Tiwei Bie <tiwei.btw@xxxxxxxxxxxx>
    Signed-off-by: Richard Weinberger <richard@xxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/arch/um/drivers/vector_kern.c b/arch/um/drivers/vector_kern.c
index 45a4bcd27a39b..310fb14a85f77 100644
--- a/arch/um/drivers/vector_kern.c
+++ b/arch/um/drivers/vector_kern.c
@@ -141,7 +141,7 @@ static bool get_bpf_flash(struct arglist *def)
 
 	if (allow != NULL) {
 		if (kstrtoul(allow, 10, &result) == 0)
-			return (allow > 0);
+			return result > 0;
 	}
 	return false;
 }




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux