Patch "s390/ap: fix error handling in __verify_queue_reservations()" has been added to the 5.18-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

    s390/ap: fix error handling in __verify_queue_reservations()

to the 5.18-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:
     s390-ap-fix-error-handling-in-__verify_queue_reservations.patch
and it can be found in the queue-5.18 subdirectory.

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


>From 2f23256c0ea20627c91ea2d468cda945f68c3395 Mon Sep 17 00:00:00 2001
From: Tony Krowiak <akrowiak@xxxxxxxxxxxxx>
Date: Wed, 6 Jul 2022 17:43:29 -0400
Subject: s390/ap: fix error handling in __verify_queue_reservations()

From: Tony Krowiak <akrowiak@xxxxxxxxxxxxx>

commit 2f23256c0ea20627c91ea2d468cda945f68c3395 upstream.

The AP bus's __verify_queue_reservations function increments the ref count
for the device driver passed in as a parameter, but fails to decrement it
before returning control to the caller. This will prevents any subsequent
removal of the module.

Signed-off-by: Tony Krowiak <akrowiak@xxxxxxxxxxxxx>
Reported-by: Tony Krowiak <akrowiak@xxxxxxxxxxxxx>
Reviewed-by: Harald Freudenberger <freude@xxxxxxxxxxxxx>
Fixes: 4f8206b88286 ("s390/ap: driver callback to indicate resource in use")
Link: https://lore.kernel.org/r/20220706222619.602094-1-akrowiak@xxxxxxxxxxxxx
Cc: stable@xxxxxxxxxxxxxxx
[agordeev@xxxxxxxxxxxxx fixed description, added Fixes and Link]
Signed-off-by: Alexander Gordeev <agordeev@xxxxxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
---
 drivers/s390/crypto/ap_bus.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/s390/crypto/ap_bus.c
+++ b/drivers/s390/crypto/ap_bus.c
@@ -1410,7 +1410,7 @@ static int __verify_queue_reservations(s
 	if (ap_drv->in_use) {
 		rc = ap_drv->in_use(ap_perms.apm, newaqm);
 		if (rc)
-			return -EBUSY;
+			rc = -EBUSY;
 	}
 
 	/* release the driver's module */


Patches currently in stable-queue which might be from akrowiak@xxxxxxxxxxxxx are

queue-5.18/s390-ap-fix-error-handling-in-__verify_queue_reservations.patch



[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