rtlwifi: rtl8192ee: Fix memory leak when loading firmware
authorLarry Finger <Larry.Finger@lwfinger.net>
Thu, 14 Sep 2017 18:17:44 +0000 (13:17 -0500)
committerKalle Valo <kvalo@codeaurora.org>
Wed, 20 Sep 2017 12:44:44 +0000 (15:44 +0300)
commit519ce2f933fa14acf69d5c8cabcc18711943d629
tree4edd6a03091f78415212d2bc49493041419e3ef5
parent0f61953dd0f5fbed6ac833f58dc590293b7569b0
rtlwifi: rtl8192ee: Fix memory leak when loading firmware

In routine rtl92ee_set_fw_rsvdpagepkt(), the driver allocates an skb, but
never calls rtl_cmd_send_packet(), which will free the buffer. All other
rtlwifi drivers perform this operation correctly.

This problem has been in the driver since it was included in the kernel.
Fortunately, each firmware load only leaks 4 buffers, which likely
explains why it has not previously been detected.

Cc: Stable <stable@vger.kernel.org> # 3.18+
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/realtek/rtlwifi/rtl8192ee/fw.c