lkml.org 
[lkml]   [2023]   [Apr]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRE: [PATCH v3] dma-buf/heaps: system_heap: avoid too much allocation
From
Date
>On Wed, Apr 12, 2023 at 4:38?AM Jaewon Kim <jaewon31.kim@samsung.com> wrote:
>
>> Yes I think you're right. As a allocator, dma-buf system heap looks to be loose
>> in memory allocation. Limiting dmabuf memory may be required. But I think there
>> is no nice and reasonable way so far. And the dma-buf system heap is being
>> widely used in Android mobile system. AFAIK the camera consumes huge memory
>> through this dma-buf system heap. I actually even looked a huge size request
>> over 2GB in one dma-buf request.
>>
>Hey can you point me to where you saw a request that big? That's a
>non-buggy request?!

(let me resend as plain text)
It was one of camera scenarios. I internally asked and heard that was not a bug
but normal. I think 2GB looks too big for one graphics buffer but it could be
for other purposes like camera. I think the system heap should support that.

Regarding __GFP_RETRY_MAYFAIL, we may need to say dma-buf system heap was
designed to gather many pages up to a requested size. If mm returns NULL due to
__GFP_RETRY_MAYFAIL, dma-buf system heap will release other already allocated
pages, so that it may help to avoid oom.

\
 
 \ /
  Last update: 2023-04-13 02:18    [W:0.093 / U:26.980 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site