Displaying 15 results from an estimated 15 matches for "nouveau_event_put".
Did you mean:
nouveau_event_get
2013 Aug 27
11
[PATCH 0/9] drm/nouveau: Cleanup event/handler design
...andlers
drm/nouveau: Move event index check from critical section
drm/nouveau: Allocate local event handlers
drm/nouveau: Allow asymmetric nouveau_event_get/_put
drm/nouveau: Add install/remove semantics for event handlers
drm/nouveau: Convert event handler list to RCU
drm/nouveau: Fold nouveau_event_put_locked into caller
drm/nouveau: Simplify event interface
drm/nouveau: Simplify event handler interface
drivers/gpu/drm/nouveau/core/core/event.c | 121 +++++++++++++++++----
.../gpu/drm/nouveau/core/engine/software/nv50.c | 32 ++++--
.../gpu/drm/nouveau/core/engine/software/nvc0...
2013 Aug 27
0
[PATCH 3/9] drm/nouveau: Allocate local event handlers
...f(*handler), GFP_KERNEL);
+ if (!handler)
+ return -ENOMEM;
+ handler->func = func;
+ handler->priv = priv;
+ nouveau_event_get(event, index, handler);
+ return 0;
+}
+
+void
+nouveau_event_handler_destroy(struct nouveau_event *event, int index,
+ struct nouveau_eventh *handler)
+{
+ nouveau_event_put(event, index, handler);
+ kfree(handler);
+}
+
static void
nouveau_event_put_locked(struct nouveau_event *event, int index,
struct nouveau_eventh *handler)
diff --git a/drivers/gpu/drm/nouveau/core/include/core/event.h b/drivers/gpu/drm/nouveau/core/include/core/event.h
index ad4d8c2..bdf1a0...
2013 Aug 27
0
[PATCH 1/9] drm/nouveau: Add priv field for event handlers
...ouveau_event_get(pfifo->uevent, 0, &uevent.handler);
+ nouveau_event_get(pfifo->uevent, 0, &handler);
if (fence->timeout) {
unsigned long timeout = fence->timeout - jiffies;
@@ -224,7 +218,7 @@ nouveau_fence_wait_uevent(struct nouveau_fence *fence, bool intr)
}
}
- nouveau_event_put(pfifo->uevent, 0, &uevent.handler);
+ nouveau_event_put(pfifo->uevent, 0, &handler);
if (unlikely(ret < 0))
return ret;
--
1.8.1.2
2013 Aug 27
0
[PATCH 7/9] drm/nouveau: Fold nouveau_event_put_locked into caller
nouveau_event_put_locked() only has 1 call site; fold into caller.
Signed-off-by: Peter Hurley <peter at hurleysoftware.com>
---
drivers/gpu/drm/nouveau/core/core/event.c | 19 ++++++-------------
1 file changed, 6 insertions(+), 13 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/core/core/event.c b/drive...
2013 Aug 12
2
[PATCH] drm/nouveau: fix vblank deadlock
.../gpu/drm/nouveau/core/core/event.c b/drivers/gpu/drm/nouveau/core/core/event.c
index 7eb81c1..78bff7c 100644
--- a/drivers/gpu/drm/nouveau/core/core/event.c
+++ b/drivers/gpu/drm/nouveau/core/core/event.c
@@ -23,43 +23,64 @@
#include <core/os.h>
#include <core/event.h>
-static void
-nouveau_event_put_locked(struct nouveau_event *event, int index,
- struct nouveau_eventh *handler)
-{
- if (!--event->index[index].refs) {
- if (event->disable)
- event->disable(event, index);
- }
- list_del(&handler->head);
-}
-
void
nouveau_event_put(struct nouveau_event *event, int index,...
2013 Aug 27
0
[PATCH 4/9] drm/nouveau: Allow asymmetric nouveau_event_get/_put
...anged, 18 insertions(+), 14 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/core/core/event.c b/drivers/gpu/drm/nouveau/core/core/event.c
index 1a8d685..0a65ede 100644
--- a/drivers/gpu/drm/nouveau/core/core/event.c
+++ b/drivers/gpu/drm/nouveau/core/core/event.c
@@ -51,11 +51,13 @@ static void
nouveau_event_put_locked(struct nouveau_event *event, int index,
struct nouveau_eventh *handler)
{
- if (!--event->index[index].refs) {
- if (event->disable)
- event->disable(event, index);
+ if (__test_and_clear_bit(NVKM_EVENT_ENABLE, &handler->flags)) {
+ if (!--event->index[index].ref...
2013 Aug 19
0
[PATCH] drm/nouveau: fix vblank deadlock
...gpu/drm/nouveau/core/core/event.c
> index 7eb81c1..78bff7c 100644
> --- a/drivers/gpu/drm/nouveau/core/core/event.c
> +++ b/drivers/gpu/drm/nouveau/core/core/event.c
> @@ -23,43 +23,64 @@
> #include <core/os.h>
> #include <core/event.h>
>
> -static void
> -nouveau_event_put_locked(struct nouveau_event *event, int index,
> - struct nouveau_eventh *handler)
> -{
> - if (!--event->index[index].refs) {
> - if (event->disable)
> - event->disable(event, index);
> - }
> - list_del(&handler->head);
> -}
> -
> void
> n...
2013 Mar 23
1
[bisected][3.9.0-rc3] NULL ptr dereference from nv50_disp_intr()
On Tue, 2013-03-19 at 11:13 -0400, Peter Hurley wrote:
> On vanilla 3.9.0-rc3, I get this 100% repeatable oops after login when
> the user X session is coming up:
Perhaps I wasn't clear that this happens on every boot and is a
regression from 3.8
I'd be happy to help resolve this but time is of the essence; it would
be a shame to have to revert all of this for 3.9
Regards,
Peter
2014 May 14
0
[RFC PATCH v1 07/16] drm/nouveau: rework to new fence interface
...- list_for_each_entry(handler, &event->index[index].list, head) {
+ list_for_each_entry_safe(handler, next, &event->index[index].list, head) {
if (test_bit(NVKM_EVENT_ENABLE, &handler->flags) &&
handler->func(handler->priv, index) == NVKM_EVENT_DROP)
nouveau_event_put(handler);
diff --git a/drivers/gpu/drm/nouveau/nouveau_bo.c b/drivers/gpu/drm/nouveau/nouveau_bo.c
index e98af2e9a1cb..84aba3fa1bd0 100644
--- a/drivers/gpu/drm/nouveau/nouveau_bo.c
+++ b/drivers/gpu/drm/nouveau/nouveau_bo.c
@@ -959,7 +959,7 @@ nouveau_bo_move_m2mf(struct ttm_buffer_object *bo, int...
2013 Dec 01
0
3.12 nvidia switcheroo regression
...: 2 PID: 2738 Comm: bash Tainted: PF O 3.12.2-ninja+ #3
Hardware name: Apple Inc. MacBookPro10,1/Mac-C3EC7CD22292981F, BIOS
MBP101.88Z.00EE.B02.1208081132 08/08/2012
task: ffff880262bb5d00 ti: ffff88008624e000 task.ti: ffff88008624e000
RIP: 0010:[<ffffffffa0159b81>] [<ffffffffa0159b81>]
nouveau_event_put_locked+0x31/0x60 [nouveau]
RSP: 0018:ffff88008624fd48 EFLAGS: 00010097
RAX: dead000000200200 RBX: ffff88025e8bad88 RCX: 0000000000000010
RDX: dead000000100100 RSI: 0000000000000011 RDI: ffff88025ef36400
RBP: ffff88008624fd50 R08: 0000000000000217 R09: 000000000000052d
R10: 0000000000000000 R11: fff...
2013 Aug 27
0
[PATCH 6/9] drm/nouveau: Convert event handler list to RCU
...or_each_entry_safe(handler, temp, &event->index[index].list, head) {
+ rcu_read_lock();
+ list_for_each_entry_rcu(handler, &event->index[index].list, head) {
if (test_bit(NVKM_EVENT_ENABLE, &handler->flags)) {
if (handler->func(handler, index) == NVKM_EVENT_DROP)
- nouveau_event_put_locked(event, index, handler);
+ nouveau_event_put(event, index, handler);
}
}
- spin_unlock_irqrestore(&event->lock, flags);
+ rcu_read_unlock();
}
void
diff --git a/drivers/gpu/drm/nouveau/core/engine/software/nv50.c b/drivers/gpu/drm/nouveau/core/engine/software/nv50.c
index d...
2013 Aug 27
0
[PATCH 5/9] drm/nouveau: Add install/remove semantics for event handlers
...ndex[index].refs++) {
+ if (event->enable)
+ event->enable(event, index);
+ }
+ spin_unlock_irqrestore(&event->lock, flags);
return 0;
}
@@ -43,7 +84,18 @@ void
nouveau_event_handler_destroy(struct nouveau_event *event, int index,
struct nouveau_eventh *handler)
{
- nouveau_event_put(event, index, handler);
+ unsigned long flags;
+
+ if (index >= event->index_nr)
+ return;
+
+ spin_lock_irqsave(&event->lock, flags);
+ if (!--event->index[index].refs) {
+ if (event->disable)
+ event->disable(event, index);
+ }
+ list_del(&handler->head);
+ spin_u...
2014 May 14
17
[RFC PATCH v1 00/16] Convert all ttm drivers to use the new reservation interface
This series depends on the previously posted reservation api patches.
2 of them are not yet in for-next-fences branch of
git://git.linaro.org/people/sumit.semwal/linux-3.x.git
The missing patches are still in my vmwgfx_wip branch at
git://people.freedesktop.org/~mlankhorst/linux
All ttm drivers are converted to the fence api, fence_lock is removed
and rcu is used in its place.
qxl is the first
2014 Jul 31
19
[PATCH 01/19] fence: add debugging lines to fence_is_signaled for the callback
fence_is_signaled callback should support being run in
atomic context, but not in irq context.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst at canonical.com>
---
include/linux/fence.h | 23 +++++++++++++++++++----
1 file changed, 19 insertions(+), 4 deletions(-)
diff --git a/include/linux/fence.h b/include/linux/fence.h
index d174585b874b..c1a4519ba2f5 100644
---
2014 Jul 09
22
[PATCH 00/17] Convert TTM to the new fence interface.
This series applies on top of the driver-core-next branch of
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core.git
Before converting ttm to the new fence interface I had to fix some
drivers to require a reservation before poking with fence_obj.
After flipping the switch RCU becomes available instead, and
the extra reservations can be dropped again. :-)
I've done at least basic