Re: [PATCH 0/5] prevent OOM triggered by TTM

2018-02-07 Thread Thomas Hellstrom
:43 PM To: He, Roger <hongbo...@amd.com>; amd-...@lists.freedesktop.org; dri-devel@lists.freedesktop.org Cc: Koenig, Christian <christian.koe...@amd.com> Subject: Re: [PATCH 0/5] prevent OOM triggered by TTM Hi, Roger, On 02/06/2018 10:04 AM, Roger He wrote: currently ttm cod

Re: [PATCH 0/5] prevent OOM triggered by TTM

2018-02-07 Thread Christian König
com>; amd-...@lists.freedesktop.org; dri-devel@lists.freedesktop.org Cc: Koenig, Christian <christian.koe...@amd.com> Subject: Re: [PATCH 0/5] prevent OOM triggered by TTM Hi, Roger, On 02/06/2018 10:04 AM, Roger He wrote: currently ttm code has no any allocation limit. So it allows pages

Re: [PATCH 0/5] prevent OOM triggered by TTM

2018-02-07 Thread Thomas Hellstrom
op.org Cc: Koenig, Christian <christian.koe...@amd.com> Subject: Re: [PATCH 0/5] prevent OOM triggered by TTM Hi, Roger, On 02/06/2018 10:04 AM, Roger He wrote: currently ttm code has no any allocation limit. So it allows pages allocatation unlimited until OOM. Because if swap space is ful

RE: [PATCH 0/5] prevent OOM triggered by TTM

2018-02-07 Thread He, Roger
m <tho...@shipmail.org>; amd-...@lists.freedesktop.org; dri-devel@lists.freedesktop.org Cc: Koenig, Christian <christian.koe...@amd.com> Subject: Re: [PATCH 0/5] prevent OOM triggered by TTM > AMD prefers return value of no memory rather than OOM for now. Yeah, but Thomas is r

Re: [PATCH 0/5] prevent OOM triggered by TTM

2018-02-07 Thread Christian König
Koenig, Christian <christian.koe...@amd.com> Subject: Re: [PATCH 0/5] prevent OOM triggered by TTM Hi, Roger, On 02/06/2018 10:04 AM, Roger He wrote: currently ttm code has no any allocation limit. So it allows pages allocatation unlimited until OOM. Because if swap space is full of s

RE: [PATCH 0/5] prevent OOM triggered by TTM

2018-02-07 Thread He, Roger
-devel@lists.freedesktop.org Cc: Koenig, Christian <christian.koe...@amd.com> Subject: Re: [PATCH 0/5] prevent OOM triggered by TTM Hi, Roger, On 02/06/2018 10:04 AM, Roger He wrote: > currently ttm code has no any allocation limit. So it allows pages > allocatation unlimited until OOM. Because if

Re: [PATCH 0/5] prevent OOM triggered by TTM

2018-02-06 Thread Thomas Hellstrom
Hi, Roger, On 02/06/2018 10:04 AM, Roger He wrote: currently ttm code has no any allocation limit. So it allows pages allocatation unlimited until OOM. Because if swap space is full of swapped pages and then system memory will be filled up with ttm pages. and then any memory allocation request

RE: [PATCH 0/5] prevent OOM triggered by TTM

2018-02-06 Thread He, Roger
op.org Cc: tho...@shipmail.org Subject: Re: [PATCH 0/5] prevent OOM triggered by TTM Nice work, but a few comments. First of all you need to reorder the patches. Adding the exceptions to the restrictions should come first, then the restriction itself. Otherwise we might break a setup in b

Re: [PATCH 0/5] prevent OOM triggered by TTM

2018-02-06 Thread Christian König
Nice work, but a few comments. First of all you need to reorder the patches. Adding the exceptions to the restrictions should come first, then the restriction itself. Otherwise we might break a setup in between the patches and that is bad for bisecting. Then make all values configurable,

[PATCH 0/5] prevent OOM triggered by TTM

2018-02-06 Thread Roger He
currently ttm code has no any allocation limit. So it allows pages allocatation unlimited until OOM. Because if swap space is full of swapped pages and then system memory will be filled up with ttm pages. and then any memory allocation request will trigger OOM. the following patches is for