Patch "hippi: Fix a size used in a 'pci_free_consistent()' in an error handling path" has been added to the 5.7-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

    hippi: Fix a size used in a 'pci_free_consistent()' in an error handling path

to the 5.7-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:
     hippi-fix-a-size-used-in-a-pci_free_consistent-in-an.patch
and it can be found in the queue-5.7 subdirectory.

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



commit 6b10ca33d28250b9a4cb82f83be60790ee03aa13
Author: Christophe JAILLET <christophe.jaillet@xxxxxxxxxx>
Date:   Tue Jul 14 13:00:27 2020 +0200

    hippi: Fix a size used in a 'pci_free_consistent()' in an error handling path
    
    [ Upstream commit 3195c4706b00106aa82c73acd28340fa8fc2bfc1 ]
    
    The size used when calling 'pci_alloc_consistent()' and
    'pci_free_consistent()' should match.
    
    Fix it and have it consistent with the corresponding call in 'rr_close()'.
    
    Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
    Signed-off-by: Christophe JAILLET <christophe.jaillet@xxxxxxxxxx>
    Signed-off-by: David S. Miller <davem@xxxxxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/net/hippi/rrunner.c b/drivers/net/hippi/rrunner.c
index 2a6ec53949666..a4b3fce69ecd9 100644
--- a/drivers/net/hippi/rrunner.c
+++ b/drivers/net/hippi/rrunner.c
@@ -1242,7 +1242,7 @@ static int rr_open(struct net_device *dev)
 		rrpriv->info = NULL;
 	}
 	if (rrpriv->rx_ctrl) {
-		pci_free_consistent(pdev, sizeof(struct ring_ctrl),
+		pci_free_consistent(pdev, 256 * sizeof(struct ring_ctrl),
 				    rrpriv->rx_ctrl, rrpriv->rx_ctrl_dma);
 		rrpriv->rx_ctrl = NULL;
 	}



[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