nfc: fdp: Fix potential memory leak in fdp_nci_send()
stable inclusion from stable-v5.10.154 commit e8c11ee2d07f7c4dfa2ac0ea8efc4f627e58ea57 category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I64YCB Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=e8c11ee2d07f7c4dfa2ac0ea8efc4f627e58ea57 -------------------------------- [ Upstream commit 8e4aae6b ] fdp_nci_send() will call fdp_nci_i2c_write that will not free skb in the function. As a result, when fdp_nci_i2c_write() finished, the skb will memleak. fdp_nci_send() should free skb after fdp_nci_i2c_write() finished. Fixes: a06347c0 ("NFC: Add Intel Fields Peak NFC solution driver") Signed-off-by:Shang XiaoJing <shangxiaojing@huawei.com> Signed-off-by:
David S. Miller <davem@davemloft.net> Signed-off-by:
Sasha Levin <sashal@kernel.org> Signed-off-by:
Lipeng Sang <sanglipeng1@jd.com> (cherry picked from commit e8e91593)
Loading
Please sign in to comment