]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net: mctp i3c: Copy headers if cloned
authorMatt Johnston <matt@codeconstruct.com.au>
Thu, 6 Mar 2025 10:24:18 +0000 (18:24 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 22 Mar 2025 19:54:11 +0000 (12:54 -0700)
commit370dacb7edc23ffd942ba2af10b8816a9788c6c2
tree8f2671e04f3487c14955f454321563d743c9a911
parent956d8ef54a420db704ac02052832e51f9d6586bb
net: mctp i3c: Copy headers if cloned

[ Upstream commit 26db9c9ee19c36a97dbb1cfef007a3c189c4c874 ]

Use skb_cow_head() prior to modifying the tx skb. This is necessary
when the skb has been cloned, to avoid modifying other shared clones.

Signed-off-by: Matt Johnston <matt@codeconstruct.com.au>
Fixes: c8755b29b58e ("mctp i3c: MCTP I3C driver")
Link: https://patch.msgid.link/20250306-matt-i3c-cow-head-v1-1-d5e6a5495227@codeconstruct.com.au
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/mctp/mctp-i3c.c