Oopenvela-robotmm: Add double-free detection to delay list
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
mm_lock delete check and invalid return,heap not use in interrupt Signed-off-by: huojianchao<huojianchao@xiaomi.com> | 2 个月前 | |
mm_lock delete check and invalid return,heap not use in interrupt Signed-off-by: huojianchao<huojianchao@xiaomi.com> | 2 个月前 | |
mm: Add double-free detection to delay list When same memory is freed twice and both added to delay list (race condition in interrupt context), it causes crash later in mm_forcefree() when processing the delay list. This patch adds early detection in add_delaylist() using: 1. Magic value (addr ^ 0xDEADBEEF) for O(1) fast path 2. List traversal for confirmation when magic matches The double-free will be caught immediately with DEBUGASSERT instead of crashing later in free_delaylist() Changes: - Add MM_DELAY_MAGIC and magic field to mm_delaynode_s - Implement two-step detection in add_delaylist() - Sync implementation across mm_heap and tlsf allocators Signed-off-by: ligd <liguiding1@xiaomi.com> | 2 个月前 | |
Merge branch 'master' into vela apache/nuttx commit id: eb27ebba8adfe29644a7b890f86e6f16941921dc Signed-off-by: ligd <liguiding1@xiaomi.com> Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com> | 2 个月前 | |
Merge branch 'master' into vela apache/nuttx commit id: eb27ebba8adfe29644a7b890f86e6f16941921dc Signed-off-by: ligd <liguiding1@xiaomi.com> Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com> | 2 个月前 | |
mm/mm_foreach:update check for mm_foreach This patch makes the following two changes: 1.Update SMP, interrupt context and rmutex lock checks in mm_foreach. 2.Move mm_free_delaylist() call from mm_foreach() to its callers. Signed-off-by: tengshuangshuang <tengshuangshuang@xiaomi.com> | 2 个月前 | |
mm_lock delete check and invalid return,heap not use in interrupt Signed-off-by: huojianchao<huojianchao@xiaomi.com> | 2 个月前 | |
mm/mm_foreach:update check for mm_foreach This patch makes the following two changes: 1.Update SMP, interrupt context and rmutex lock checks in mm_foreach. 2.Move mm_free_delaylist() call from mm_foreach() to its callers. Signed-off-by: tengshuangshuang <tengshuangshuang@xiaomi.com> | 2 个月前 | |
mm: Add double-free detection to delay list When same memory is freed twice and both added to delay list (race condition in interrupt context), it causes crash later in mm_forcefree() when processing the delay list. This patch adds early detection in add_delaylist() using: 1. Magic value (addr ^ 0xDEADBEEF) for O(1) fast path 2. List traversal for confirmation when magic matches The double-free will be caught immediately with DEBUGASSERT instead of crashing later in free_delaylist() Changes: - Add MM_DELAY_MAGIC and magic field to mm_delaynode_s - Implement two-step detection in add_delaylist() - Sync implementation across mm_heap and tlsf allocators Signed-off-by: ligd <liguiding1@xiaomi.com> | 2 个月前 | |
mm/kasan: fix judge mm_heapmenber when use tags kasan one memory block from heap may be used to initialize into another heap pool, the new heap start with tags need to clear when judge mem is or no heapmember Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com> | 2 个月前 | |
kasan/unregister: Modify the logic of unpoison 1. When a region is not included in other regions, we will remove it from g_region. Unpoison is not needed afterward because mm->shadow will no longer be mapped after removal. 2. When a region is contained within other regions, we will unpoison it, The size passed in at this point is also complete. It will not be subtracted from the header of the Kasan region structure in the Kasan register. Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com> | 2 个月前 | |
mm/mm_foreach:update check for mm_foreach This patch makes the following two changes: 1.Update SMP, interrupt context and rmutex lock checks in mm_foreach. 2.Move mm_free_delaylist() call from mm_foreach() to its callers. Signed-off-by: tengshuangshuang <tengshuangshuang@xiaomi.com> | 2 个月前 | |
diagnose: add mm related diagnose event Added malloc failed and double-free diagnose event. Signed-off-by: xuxingliang <xuxingliang@xiaomi.com> | 2 个月前 | |
fix kasan_bypss compile unused error Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com> | 2 个月前 | |
mm_lock delete check and invalid return,heap not use in interrupt Signed-off-by: huojianchao<huojianchao@xiaomi.com> | 2 个月前 | |
mm/mm_foreach:update check for mm_foreach This patch makes the following two changes: 1.Update SMP, interrupt context and rmutex lock checks in mm_foreach. 2.Move mm_free_delaylist() call from mm_foreach() to its callers. Signed-off-by: tengshuangshuang <tengshuangshuang@xiaomi.com> | 2 个月前 | |
mm_lock delete check and invalid return,heap not use in interrupt Signed-off-by: huojianchao<huojianchao@xiaomi.com> | 2 个月前 | |
mm:add mm_sbrk api for specified heap Signed-off-by: anjiahao <anjiahao@xiaomi.com> | 2 个月前 | |
Merge branch 'master' into vela apache/nuttx commit id: eb27ebba8adfe29644a7b890f86e6f16941921dc Signed-off-by: ligd <liguiding1@xiaomi.com> Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com> | 2 个月前 | |
Merge branch 'master' into vela apache/nuttx commit id: eb27ebba8adfe29644a7b890f86e6f16941921dc Signed-off-by: ligd <liguiding1@xiaomi.com> Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com> | 2 个月前 |