Skip to content

Commit

Permalink
drm/i915: Extract general GT interrupt handlers
Browse files Browse the repository at this point in the history
i915_irq.c is large. It serves as the central dispatch and handler for
all of our device interrupts. Lets break it up by pulling out the GT
interrupt handlers.

Based on a patch by Chris Wilson.

Signed-off-by: Andi Shyti <andi.shyti@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Link: https://patchwork.freedesktop.org/patch/msgid/20190811210633.18417-1-chris@chris-wilson.co.uk
  • Loading branch information
Andi Shyti authored and Chris Wilson committed Aug 12, 2019
1 parent d762043 commit cf1c97d
Show file tree
Hide file tree
Showing 10 changed files with 593 additions and 551 deletions.
1 change: 1 addition & 0 deletions drivers/gpu/drm/i915/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ gt-y += \
gt/intel_engine_pm.o \
gt/intel_engine_user.o \
gt/intel_gt.o \
gt/intel_gt_irq.o \
gt/intel_gt_pm.o \
gt/intel_gt_pm_irq.o \
gt/intel_hangcheck.o \
Expand Down
8 changes: 4 additions & 4 deletions drivers/gpu/drm/i915/gt/intel_breadcrumbs.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ static void irq_enable(struct intel_engine_cs *engine)
return;

/* Caller disables interrupts */
spin_lock(&engine->i915->irq_lock);
spin_lock(&engine->gt->irq_lock);
engine->irq_enable(engine);
spin_unlock(&engine->i915->irq_lock);
spin_unlock(&engine->gt->irq_lock);
}

static void irq_disable(struct intel_engine_cs *engine)
Expand All @@ -46,9 +46,9 @@ static void irq_disable(struct intel_engine_cs *engine)
return;

/* Caller disables interrupts */
spin_lock(&engine->i915->irq_lock);
spin_lock(&engine->gt->irq_lock);
engine->irq_disable(engine);
spin_unlock(&engine->i915->irq_lock);
spin_unlock(&engine->gt->irq_lock);
}

static void __intel_breadcrumbs_disarm_irq(struct intel_breadcrumbs *b)
Expand Down
Loading

0 comments on commit cf1c97d

Please sign in to comment.