Re: [PATCH v2] arm: print alloc free paths for address in registers

From: Vlastimil Babka
Date: Fri Mar 12 2021 - 04:22:26 EST


On 3/11/21 11:51 AM, Maninder Singh wrote:
> Hi,
>
>  
>
>> Instead of your changes to SL*B, could you check mem_dump_obj() and others added
>> by Paul in 5.12-rc1?
>
>> (+CC Paul, thus not trimming)
>
>  
>
> checked mem_dump_obj(), but it only provides path of allocation and not of free.
>
> /**
>  * mem_dump_obj - Print available provenance information
>
> ..
>
>  * if available, the return address and stack trace from the allocation
>  * of that object.
>  */
> void mem_dump_obj(void *object)
>
> and in case of "Use After Free", Free path is also required.
>
> So we need to add support for free path in this API if we have to use it.

I think that would make sense.  

> Thanks,
>
> Maninder Singh
>