Patch "EDAC/ti: Fix handling of platform_get_irq() error" has been added to the 5.4-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

    EDAC/ti: Fix handling of platform_get_irq() error

to the 5.4-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:
     edac-ti-fix-handling-of-platform_get_irq-error.patch
and it can be found in the queue-5.4 subdirectory.

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



commit 19ff9080051b877c47b055bea8d8b76a7845d95f
Author: Krzysztof Kozlowski <krzk@xxxxxxxxxx>
Date:   Thu Aug 27 09:07:43 2020 +0200

    EDAC/ti: Fix handling of platform_get_irq() error
    
    [ Upstream commit 66077adb70a2a9e92540155b2ace33ec98299c90 ]
    
    platform_get_irq() returns a negative error number on error. In such a
    case, comparison to 0 would pass the check therefore check the return
    value properly, whether it is negative.
    
     [ bp: Massage commit message. ]
    
    Fixes: 86a18ee21e5e ("EDAC, ti: Add support for TI keystone and DRA7xx EDAC")
    Signed-off-by: Krzysztof Kozlowski <krzk@xxxxxxxxxx>
    Signed-off-by: Borislav Petkov <bp@xxxxxxx>
    Reviewed-by: Tero Kristo <t-kristo@xxxxxx>
    Link: https://lkml.kernel.org/r/20200827070743.26628-2-krzk@xxxxxxxxxx
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/edac/ti_edac.c b/drivers/edac/ti_edac.c
index 6ac26d1b929f0..3247689467435 100644
--- a/drivers/edac/ti_edac.c
+++ b/drivers/edac/ti_edac.c
@@ -278,7 +278,8 @@ static int ti_edac_probe(struct platform_device *pdev)
 
 	/* add EMIF ECC error handler */
 	error_irq = platform_get_irq(pdev, 0);
-	if (!error_irq) {
+	if (error_irq < 0) {
+		ret = error_irq;
 		edac_printk(KERN_ERR, EDAC_MOD_NAME,
 			    "EMIF irq number not defined.\n");
 		goto err;



[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