]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
Bluetooth: L2CAP: copy RX timestamp to new fragments
authorPauli Virtanen <pav@iki.fi>
Thu, 24 Apr 2025 19:51:03 +0000 (22:51 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 9 May 2025 07:43:58 +0000 (09:43 +0200)
[ Upstream commit 3908feb1bd7f319a10e18d84369a48163264cc7d ]

Copy timestamp too when allocating new skb for received fragment.
Fixes missing RX timestamps with fragmentation.

Fixes: 4d7ea8ee90e4 ("Bluetooth: L2CAP: Fix handling fragmented length")
Signed-off-by: Pauli Virtanen <pav@iki.fi>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/bluetooth/l2cap_core.c

index d4dcdb2370cc98e01412b12c3775b35617929855..72ee41b894a520b867ad589deba9ab423d49c101 100644 (file)
@@ -7386,6 +7386,9 @@ static int l2cap_recv_frag(struct l2cap_conn *conn, struct sk_buff *skb,
                        return -ENOMEM;
                /* Init rx_len */
                conn->rx_len = len;
+
+               skb_set_delivery_time(conn->rx_skb, skb->tstamp,
+                                     skb->tstamp_type);
        }
 
        /* Copy as much as the rx_skb can hold */