Tao Zeng fec8367f95 amfc: fix kasan report [1/1]
PD#SWPL-171396

Problem:
kasan report:
BUG: KASAN: slab-out-of-bounds in amfc_decompress+0x144/0x14bc [amlogic_amfc]
write of size 32 at addr ffffff8011d68780 by task init/1

 CPU: 3 PID: 1 Comm: init Tainted: P B OE 5.15.137-android14-11-maybe-dirty #1
 Hardware name: s7d_s905x5m_bm201 (DT)
 Call trace:
 dump_backtrace+0x144/0x190
 show_stack+0x2c/0x48
 dump_stack_lvl+0x7c/0x94
 print_report+0x178/0x4a0
 kasan_report+0xb0/0x104
 kasan_check_range+0x274/0x2b4
 memset+0x58/0x88
 amfc_decompress+0x144/0x14bc [amlogic_amfc]
 amfc_crypto_decompress+0x68/0xd8 [amlogic_amfc]

Solution:
fix it

Verify:
local

Change-Id: I84df77652100ba1d43169feedef057d13cf34656
Signed-off-by: Tao Zeng <tao.zeng@amlogic.com>
2024-06-02 19:10:14 +08:00
2024-05-29 20:36:49 +08:00
2024-06-02 19:10:14 +08:00
2024-05-30 15:19:32 +08:00
S
Description
No description provided
118 MiB
Languages
C 98.9%
Perl 0.4%
Makefile 0.4%
Shell 0.2%