Skip to contentSkip to conversation

nv50: fix crash in NV50SyncToVBlank

PATCH In review Marcin Slusarz 2 participants 3 messages Apr 15, 2012 – May 3, 2012 4 messages not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

#2 lore raw

PATCH 1/1 nv50: fix crash in NV50SyncToVBlank

Regression from "WIP: port to new libdrm".

---
 src/nv50_accel.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
src/nv50_accel.c +3 -0
index 66d6cb8..7c640f2 100644
@@ -44,6 +44,9 @@ NV50SyncToVBlank(PixmapPtr ppix, BoxPtr box)
 	if (!crtcs)
 		return;
 
+	if (!PUSH_SPACE(push, 10))
+		return;
+
 	BEGIN_NV04(push, SUBC_NVSW(0x0060), 2);
 	PUSH_DATA (push, pNv->vblank_sem->handle);
 	PUSH_DATA (push, 0);
Signature · 1 line
1.7.8.5

A message that is not in the archive (sent off-list or not yet received): [email protected]

#4 lore raw
Quoted 11 lines · Marcin Slusarz

Regression from "WIP: port to new libdrm".

---
 src/nv50_accel.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
src/nv50_accel.c +0 -0
index 66d6cb8..7c640f2 100644

src/nv50_accel.c NV50SyncToVBlank(PixmapPtr ppix, BoxPtr box) · line 52

Quoted 9 lines
src/nv50_accel.c +3 -0
@@ -44,6 +44,9 @@ NV50SyncToVBlank(PixmapPtr ppix, BoxPtr box)
 	if (!crtcs)
 		return;
 
+	if (!PUSH_SPACE(push, 10))
+		return;
+
 	BEGIN_NV04(push, SUBC_NVSW(0x0060), 2);
 	PUSH_DATA (push, pNv->vblank_sem->handle);
 	PUSH_DATA (push, 0);

Nobody uses "sync to vblank"? It's crashy as hell without this patch...

Marcin

A message that is not in the archive (sent off-list or not yet received): [email protected]

#6 lore raw
Quoted 14 lines · Marcin Slusarz
Quoted 13 lines · Marcin Slusarz

Regression from "WIP: port to new libdrm".

---
 src/nv50_accel.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
src/nv50_accel.c +0 -0
index 66d6cb8..7c640f2 100644
@@ -44,6 +44,9 @@ NV50SyncToVBlank(PixmapPtr ppix, BoxPtr box)
 	if (!crtcs)
 		return;
 
Quoted 10 lines

src/nv50_accel.c NV50SyncToVBlank(PixmapPtr ppix, BoxPtr box) · line 52

Quoted 7 lines
src/nv50_accel.c +3 -0
+	if (!PUSH_SPACE(push, 10))
+		return;
+
 	BEGIN_NV04(push, SUBC_NVSW(0x0060), 2);
 	PUSH_DATA (push, pNv->vblank_sem->handle);
 	PUSH_DATA (push, 0);

Nobody uses "sync to vblank"? It's crashy as hell without this patch...

Apparently not ... I certainly never enable it because I couldn't find the switch that doesn't require restarting the X server yet (granted, I haven't looked besides noticing driconf doesn't do it).

Patch pushed, thank you.

Quoted 5 lines

Marcin
_______________________________________________
Nouveau mailing list [email protected]
http://lists.freedesktop.org/mailman/listinfo/nouveau