[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <24023a79de1acee5147dd9b1e061d6df008047ab.camel@vmware.com>
Date: Wed, 24 Apr 2019 09:26:15 +0000
From: Thomas Hellstrom <thellstrom@...are.com>
To: Deepak Singh Rawat <drawat@...are.com>
CC: "dri-devel@...ts.freedesktop.org" <dri-devel@...ts.freedesktop.org>,
Linux-graphics-maintainer <Linux-graphics-maintainer@...are.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 8/9] drm/vmwgfx: Implement an infrastructure for
read-coherent resources
On Mon, 2019-04-22 at 20:12 +0000, Deepak Singh Rawat wrote:
> Minor nits below, otherwise
>
> Reviewed-by: Deepak Rawat <drawat@...are.com>
>
> On Fri, 2019-04-12 at 09:04 -0700, Thomas Hellstrom wrote:
> > Similar to write-coherent resources, make sure that from the user-
> > space
> > point of view, GPU rendered contents is automatically available for
> > reading by the CPU.
> >
> > Signed-off-by: Thomas Hellstrom <thellstrom@...are.com>
> > ---
> >
> > + while (cur) {
> > + struct vmw_resource *cur_res =
> > + container_of(cur, struct vmw_resource,
> > mob_node);
> > +
> > + if (cur_res->backup_offset >= res_end) {
> > + cur = cur->rb_left;
> > + } else if (cur_res->backup_offset + cur_res-
> > > backup_size <=
> > + res_start) {
> > + cur = cur->rb_right;
> > + } else {
> > + found = cur_res;
>
> I didn't looked into how RB tree works but do you need to break the
> loop when resource is found?
No, here we will continue looking for a resource with even lower
starting offset. I'll add a comment about that.
Thanks,
Thomas
Powered by blists - more mailing lists