From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ville =?iso-8859-1?Q?Syrj=E4l=E4?= Subject: Re: [PATCH 1/4] drm/ttm: split no_wait argument in 2 GPU or reserve wait Date: Thu, 25 Feb 2010 19:11:52 +0200 Message-ID: <20100225171152.GP10145@sci.fi> References: <1267116614-17393-1-git-send-email-jglisse@redhat.com> <1267116614-17393-2-git-send-email-jglisse@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: Content-Disposition: inline In-Reply-To: <1267116614-17393-2-git-send-email-jglisse@redhat.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.sourceforge.net To: Jerome Glisse Cc: skeggsb@gmail.com, thellstrom@vmware.com, dri-devel@lists.sf.net List-Id: dri-devel@lists.freedesktop.org On Thu, Feb 25, 2010 at 05:50:11PM +0100, Jerome Glisse wrote: > There is case where we want to be able to wait only for the > GPU while not waiting for other buffer to be unreserved. This > patch split the no_wait argument all the way down in the whole > ttm path so that upper level can decide on what to wait on or > not. > = > This patch break the API to other modules, update to others > driver are following in separate patches. > = > Signed-off-by: Jerome Glisse > --- > drivers/gpu/drm/ttm/ttm_bo.c | 57 ++++++++++++++++++++-----------= ----- > drivers/gpu/drm/ttm/ttm_bo_util.c | 9 ++++-- > include/drm/ttm/ttm_bo_api.h | 6 ++- > include/drm/ttm/ttm_bo_driver.h | 29 +++++++++++------- > 4 files changed, 60 insertions(+), 41 deletions(-) > = > diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c > index c7320ce..d2b2482 100644 > --- a/drivers/gpu/drm/ttm/ttm_bo.c > +++ b/drivers/gpu/drm/ttm/ttm_bo.c > @@ -357,7 +357,8 @@ static int ttm_bo_add_ttm(struct ttm_buffer_object *b= o, bool zero_alloc) > = > static int ttm_bo_handle_move_mem(struct ttm_buffer_object *bo, > struct ttm_mem_reg *mem, > - bool evict, bool interruptible, bool no_wait) > + bool evict, bool interruptible, > + bool no_wait_reserve, bool no_wait_gpu) Code which calls these boolean monsters is very hard to read. How about converting all of these booleans into some kind of flags? -- = Ville Syrj=E4l=E4 syrjala@sci.fi http://www.sci.fi/~syrjala/ ---------------------------------------------------------------------------= --- Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev --