Patch "media: atomisp: fix uninitialized bug in gmin_get_pmic_id_and_addr()" has been added to the 5.10-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: atomisp: fix uninitialized bug in gmin_get_pmic_id_and_addr()

to the 5.10-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-atomisp-fix-uninitialized-bug-in-gmin_get_pmic.patch
and it can be found in the queue-5.10 subdirectory.

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



commit c4496a185aa0127adb10e50dab9cac17ba901ed7
Author: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
Date:   Tue Oct 12 09:21:50 2021 +0100

    media: atomisp: fix uninitialized bug in gmin_get_pmic_id_and_addr()
    
    [ Upstream commit cb4d67a998e97365afdf34965b069601da1dae60 ]
    
    The "power" pointer is not initialized on the else path and that would
    lead to an Oops.
    
    Link: https://lore.kernel.org/linux-media/20211012082150.GA31086@kili
    Fixes: c30f4cb2d4c7 ("media: atomisp: Refactor PMIC detection to a separate function")
    Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
    Reviewed-by: Kieran Bingham <kieran.bingham+renesas@xxxxxxxxxxxxxxxx>
    Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c b/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
index 135994d44802c..34480ca164746 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_gmin_platform.c
@@ -481,7 +481,7 @@ static int atomisp_get_acpi_power(struct device *dev)
 
 static u8 gmin_get_pmic_id_and_addr(struct device *dev)
 {
-	struct i2c_client *power;
+	struct i2c_client *power = NULL;
 	static u8 pmic_i2c_addr;
 
 	if (pmic_id)



[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