From 8693db6580a46b1011842f124519f2c10d940609 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Thu, 8 Aug 2024 19:46:45 +0800 Subject: [PATCH] wifi: mt76: replace skb_put with skb_put_zero mainline inclusion from mainline-v6.10-rc1 commit 7f819a2f4fbc510e088b49c79addcf1734503578 category: bugfix bugzilla: https://gitee.com/src-openeuler/kernel/issues/IAGPSS CVE: CVE-2024-42225 Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=7f819a2f4fbc510e088b49c79addcf1734503578 -------------------------------- Avoid potentially reusing uninitialized data Signed-off-by: Felix Fietkau Conflicts: drivers/net/wireless/mediatek/mt76/mt76_connac_mcu.c [commit d0e274af2f2e ("mt76: mt76_connac: create mcu library") is not merged resulting in a conflict] Signed-off-by: Wang Hai --- drivers/net/wireless/mediatek/mt76/mt7915/mcu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c b/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c index 69691bf6197d..333a75e4a08c 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c +++ b/drivers/net/wireless/mediatek/mt76/mt7915/mcu.c @@ -724,7 +724,7 @@ mt7915_mcu_add_nested_subtlv(struct sk_buff *skb, int sub_tag, int sub_len, .len = cpu_to_le16(sub_len), }; - ptlv = skb_put(skb, sub_len); + ptlv = skb_put_zero(skb, sub_len); memcpy(ptlv, &tlv, sizeof(tlv)); le16_add_cpu(sub_ntlv, 1); -- Gitee