Patch "mailbox: pcc: Reset pcc_chan_count to zero in case of PCC probe failure" 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

    mailbox: pcc: Reset pcc_chan_count to zero in case of PCC probe failure

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:
     mailbox-pcc-reset-pcc_chan_count-to-zero-in-case-of-.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 a10a9355cd52afb48fb7a15a874cd0aa11c21123
Author: Huisong Li <lihuisong@xxxxxxxxxx>
Date:   Sat Nov 12 10:05:28 2022 +0800

    mailbox: pcc: Reset pcc_chan_count to zero in case of PCC probe failure
    
    [ Upstream commit 6d7d3c287410c0ad499e478e2338dc3d7e3392b1 ]
    
    Currently, 'pcc_chan_count' is remains set to a non-zero value if PCC
    subspaces are parsed successfully but something else fail later during
    the initial PCC probing phase. This will result in pcc_mbox_request_channel
    trying to access the resources that are not initialised or allocated and
    may end up in a system crash.
    
    Reset pcc_chan_count to 0 when the PCC probe fails in order to prevent
    the possible issue as described above.
    
    Fixes: ce028702ddbc ("mailbox: pcc: Move bulk of PCCT parsing into pcc_mbox_probe")
    Signed-off-by: Huisong Li <lihuisong@xxxxxxxxxx>
    Reviewed-by: Sudeep Holla <sudeep.holla@xxxxxxx>
    Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@xxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/mailbox/pcc.c b/drivers/mailbox/pcc.c
index 3c2bc0ca454c..105d46c9801b 100644
--- a/drivers/mailbox/pcc.c
+++ b/drivers/mailbox/pcc.c
@@ -743,6 +743,7 @@ static int __init pcc_init(void)
 
 	if (IS_ERR(pcc_pdev)) {
 		pr_debug("Err creating PCC platform bundle\n");
+		pcc_chan_count = 0;
 		return PTR_ERR(pcc_pdev);
 	}
 



[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