Patch "net: fix sock_timestamping_bind_phc() to release device" has been added to the 5.16-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

    net: fix sock_timestamping_bind_phc() to release device

to the 5.16-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:
     net-fix-sock_timestamping_bind_phc-to-release-device.patch
and it can be found in the queue-5.16 subdirectory.

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


>From 2a4d75bfe41232608f5596a6d1369f92ccb20817 Mon Sep 17 00:00:00 2001
From: Miroslav Lichvar <mlichvar@xxxxxxxxxx>
Date: Tue, 11 Jan 2022 16:10:53 +0100
Subject: net: fix sock_timestamping_bind_phc() to release device

From: Miroslav Lichvar <mlichvar@xxxxxxxxxx>

commit 2a4d75bfe41232608f5596a6d1369f92ccb20817 upstream.

Don't forget to release the device in sock_timestamping_bind_phc() after
it was used to get the vclock indices.

Fixes: d463126e23f1 ("net: sock: extend SO_TIMESTAMPING for PHC binding")
Signed-off-by: Miroslav Lichvar <mlichvar@xxxxxxxxxx>
Cc: Yangbo Lu <yangbo.lu@xxxxxxx>
Signed-off-by: David S. Miller <davem@xxxxxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
---
 net/core/sock.c |    2 ++
 1 file changed, 2 insertions(+)

--- a/net/core/sock.c
+++ b/net/core/sock.c
@@ -843,6 +843,8 @@ static int sock_timestamping_bind_phc(st
 	}
 
 	num = ethtool_get_phc_vclocks(dev, &vclock_index);
+	dev_put(dev);
+
 	for (i = 0; i < num; i++) {
 		if (*(vclock_index + i) == phc_index) {
 			match = true;


Patches currently in stable-queue which might be from mlichvar@xxxxxxxxxx are

queue-5.16/net-fix-sof_timestamping_bind_phc-to-work-with-multi.patch
queue-5.16/net-fix-sock_timestamping_bind_phc-to-release-device.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