[Mesa-dev] [PATCH] svga: fix dma.pending > 0 test

Neha Bhende bhenden at vmware.com
Tue Feb 26 15:13:57 UTC 2019


Looks good.
Reviewed-by: Neha Bhende <bhenden at vmware.com>


Regards,

Neha

________________________________
From: Brian Paul <brianp at vmware.com>
Sent: Monday, February 25, 2019 7:13 PM
To: mesa-dev at lists.freedesktop.org
Cc: Neha Bhende
Subject: [PATCH] svga: fix dma.pending > 0 test

The dma.pending field is boolean, so testing for > 0 isn't right.
---
 src/gallium/drivers/svga/svga_resource_buffer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gallium/drivers/svga/svga_resource_buffer.c b/src/gallium/drivers/svga/svga_resource_buffer.c
index e4d12f0..a3e11ad 100644
--- a/src/gallium/drivers/svga/svga_resource_buffer.c
+++ b/src/gallium/drivers/svga/svga_resource_buffer.c
@@ -117,7 +117,7 @@ svga_buffer_transfer_map(struct pipe_context *pipe,
          (void) svga_buffer_handle(svga, resource, sbuf->bind_flags);
       }

-      if (sbuf->dma.pending > 0) {
+      if (sbuf->dma.pending) {
          svga_buffer_upload_flush(svga, sbuf);
          svga_context_finish(svga);
       }
--
1.8.5.6

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20190226/0aa918a7/attachment.html>


More information about the mesa-dev mailing list