Patch "media: i2c: rdacm21: Fix uninitialized value" has been added to the 6.1-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

    media: i2c: rdacm21: Fix uninitialized value

to the 6.1-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:
     media-i2c-rdacm21-fix-uninitialized-value.patch
and it can be found in the queue-6.1 subdirectory.

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



commit 2754be5ab5c7c6e188ebe4a485742494038016ba
Author: Jacopo Mondi <jacopo.mondi@xxxxxxxxxxxxxxxx>
Date:   Thu Aug 10 15:33:37 2023 +0200

    media: i2c: rdacm21: Fix uninitialized value
    
    [ Upstream commit 33c7ae8f49e3413c81e879e1fdfcea4c5516e37b ]
    
    Fix the following smatch warning:
    
    drivers/media/i2c/rdacm21.c:373 ov10640_check_id() error: uninitialized
    symbol 'val'.
    
    Initialize 'val' to 0 in the ov10640_check_id() function.
    
    Fixes: 2b821698dc73 ("media: i2c: rdacm21: Power up OV10640 before OV490")
    Reported-by: Hans Verkuil <hverkuil-cisco@xxxxxxxxx>
    Signed-off-by: Jacopo Mondi <jacopo.mondi@xxxxxxxxxxxxxxxx>
    Signed-off-by: Hans Verkuil <hverkuil-cisco@xxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/media/i2c/rdacm21.c b/drivers/media/i2c/rdacm21.c
index 9ccc56c30d3b0..d269c541ebe4c 100644
--- a/drivers/media/i2c/rdacm21.c
+++ b/drivers/media/i2c/rdacm21.c
@@ -351,7 +351,7 @@ static void ov10640_power_up(struct rdacm21_device *dev)
 static int ov10640_check_id(struct rdacm21_device *dev)
 {
 	unsigned int i;
-	u8 val;
+	u8 val = 0;
 
 	/* Read OV10640 ID to test communications. */
 	for (i = 0; i < OV10640_PID_TIMEOUT; ++i) {



[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