<div dir="ltr"><div><div>Doh, I didn't get that! Sorry.<br><br></div>Regards<br></div>//Ernst<br></div><div class="gmail_extra"><br><div class="gmail_quote">2015-11-21 12:07 GMT+01:00 Christian König <span dir="ltr"><<a href="mailto:deathsimple@vodafone.de" target="_blank">deathsimple@vodafone.de</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000"><span class="">
<div>On 21.11.2015 11:48, Ernst Sjöstrand
wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">
<div>I guess the patches should be for drivers/gpu/drm/amd/<span>amdgpu</span>/amdgpu_cs.c instead?<br>
</div>
</div>
</blockquote>
<br></span>
No, why do you think so? This is a libdrm patch, not a kernel patch.<br>
<br>
Regards,<br>
Christian.<div><div class="h5"><br>
<br>
<blockquote type="cite">
<div dir="ltr">
<div><br>
</div>
<div>Regards<br>
</div>
//Ernst<br>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">2015-11-21 1:24 GMT+01:00 Alex Deucher
<span dir="ltr"><<a href="mailto:alexdeucher@gmail.com" target="_blank">alexdeucher@gmail.com</a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">From:
Jammy Zhou <<a href="mailto:Jammy.Zhou@amd.com" target="_blank">Jammy.Zhou@amd.com</a>><br>
<br>
Set the timeout to AMDGPU_TIMEOUT_INFINITE when overflow
happens<br>
<br>
Signed-off-by: Jammy Zhou <<a href="mailto:Jammy.Zhou@amd.com" target="_blank">Jammy.Zhou@amd.com</a>><br>
Reviewed-by: Christian König <<a href="mailto:christian.koenig@amd.com" target="_blank">christian.koenig@amd.com</a>><br>
---<br>
amdgpu/amdgpu_cs.c | 8 ++++++--<br>
1 file changed, 6 insertions(+), 2 deletions(-)<br>
<br>
diff --git a/amdgpu/amdgpu_cs.c b/amdgpu/amdgpu_cs.c<br>
index 4da9821..aa594c4 100644<br>
--- a/amdgpu/amdgpu_cs.c<br>
+++ b/amdgpu/amdgpu_cs.c<br>
@@ -289,12 +289,16 @@ drm_private uint64_t
amdgpu_cs_calculate_timeout(uint64_t timeout)<br>
<br>
if (timeout != AMDGPU_TIMEOUT_INFINITE) {<br>
struct timespec current;<br>
+ uint64_t current_ns;<br>
r = clock_gettime(CLOCK_MONOTONIC,
¤t);<br>
if (r)<br>
return r;<br>
<br>
- timeout += ((uint64_t)current.tv_sec) *
1000000000ull;<br>
- timeout += current.tv_nsec;<br>
+ current_ns = ((uint64_t)current.tv_sec) *
1000000000ull;<br>
+ current_ns += current.tv_nsec;<br>
+ timeout += current_ns;<br>
+ if (timeout < current_ns)<br>
+ timeout = AMDGPU_TIMEOUT_INFINITE;<br>
}<br>
return timeout;<br>
}<br>
<span><font color="#888888">--<br>
1.8.3.1<br>
<br>
_______________________________________________<br>
dri-devel mailing list<br>
<a href="mailto:dri-devel@lists.freedesktop.org" target="_blank">dri-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/dri-devel" rel="noreferrer" target="_blank">http://lists.freedesktop.org/mailman/listinfo/dri-devel</a><br>
</font></span></blockquote>
</div>
<br>
</div>
<br>
<fieldset></fieldset>
<br>
<pre>_______________________________________________
dri-devel mailing list
<a href="mailto:dri-devel@lists.freedesktop.org" target="_blank">dri-devel@lists.freedesktop.org</a>
<a href="http://lists.freedesktop.org/mailman/listinfo/dri-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/dri-devel</a>
</pre>
</blockquote>
<br>
</div></div></div>
</blockquote></div><br></div>