Skip to contentSkip to conversation

drm/nv50: let applications hanging on vm flush to be killed

PATCH In review Marcin Slusarz 2 participants 2 messages Apr 25, 2012 – May 27, 2012 1 message not in the archive

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH v2 3/4 drm/nv50: let applications hanging on vm flush to be killed

---
 drivers/gpu/drm/nouveau/nv50_graph.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
drivers/gpu/drm/nouveau/nv50_graph.c +5 -0
index 6899547..a61853f 100644
@@ -435,6 +435,11 @@ nv84_graph_tlb_flush(struct drm_device *dev, int engine)
 			if ((tmp & 7) == 1)
 				idle = false;
 		}
+
+		if (fatal_signal_pending(current)) {
+			ret = -ERESTARTSYS;
+			break;
+		}
 	} while (!idle && !(timeout = ptimer->read(dev) - start > 2000000000));
 
 	if (timeout) {
Signature · 1 line
1.7.8.5

A message that is not in the archive (sent off-list or not yet received): 1335388836-13127-3-git-send-email-marcin.slusarz-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org

#2 lore raw

From: Marcin Slusarz <[email protected]>
Subject: [PATCH v3] drm/nv50: let applications hanging on vm flush to be killed

---
v3: rebased on top of current nouveau-git

---
 drivers/gpu/drm/nouveau/nv50_graph.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
drivers/gpu/drm/nouveau/nv50_graph.c +4 -0
index 78365fe..ef6757f 100644
@@ -242,6 +242,10 @@ nv84_graph_tlb_flush(struct nouveau_device *ndev, int engine)
 			if ((tmp & 7) == 1)
 				idle = false;
 		}
+		if (fatal_signal_pending(current)) {
+			ret = -ERESTARTSYS;
+			break;
+		}
 	} while (!idle &&
 		 !(timeout = ptimer->read(ptimer) - start > 2000000000));
 
Signature · 1 line
1.7.8.6