1. 15 Jun, 2018 3 commits
    • Chris Wilson's avatar
      drm/i915: Be irqsafe inside reset · 042ed2db
      Chris Wilson authored
      As we want to be able to call i915_reset_engine and co from a softirq or
      timer context, we need to be irqsafe at all times. So we have to forgo
      the simple spin_lock_irq for the full spin_lock_irqsave.
      Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: default avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180615093137.14270-1-chris@chris-wilson.co.uk
      042ed2db
    • Mika Kuoppala's avatar
      drm/i915: Fix context ban and hang accounting for client · 14921f3c
      Mika Kuoppala authored
      If client is smart or lucky enough to create a new context
      after each hang, our context banning mechanism will never
      catch up, and as a result of that it will be saved from
      client banning. This can result in a never ending streak of
      gpu hangs caused by bad or malicious client, preventing
      access from other legit gpu clients.
      
      Fix this by always incrementing per client ban score if
      it hangs in short successions regardless of context ban
      scoring. The exception are non bannable contexts. They remain
      detached from client ban scoring mechanism.
      
      v2: xchg timestamp, tidyup (Chris)
      v3: comment, bannable & banned together (Chris)
      
      Fixes: b083a087 ("drm/i915: Add per client max context ban limit")
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: default avatarMika Kuoppala <mika.kuoppala@linux.intel.com>
      Reviewed-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180615104429.31477-1-mika.kuoppala@linux.intel.com
      14921f3c
    • Chris Wilson's avatar
      drm/i915: Keep the ctx workarounds tightly packed · 548764bb
      Chris Wilson authored
      For each platform, we have a few registers that are rewritten with
      different values -- they are not part of a sequence, just different parts
      of a masked register set at different times (e.g. platform and gen
      workarounds). Consolidate these into a single register write to keep the
      table compact, important since we are running of room in the current
      fixed sized buffer.
      
      While adjusting the construction of the wa table, make it non fatal so
      that the driver still loads but keeping the warning and extra details
      for inspection.
      
      Inspecting the changes for a Kabylake system,
      Before:
      	Address	val		mask		read
      	0x07014	0x20002000	0x00002000	0x00002100
      	0x0E194	0x01000100	0x00000100	0x00000114
      	0x0E4F0	0x81008100	0x00008100	0xFFFF8120
      	0x0E184	0x00200020	0x00000020	0x00000022
      	0x0E194	0x00140014	0x00000014	0x00000114
      	0x07004	0x00420042	0x00000042	0x000029C2
      	0x0E188	0x00080000	0x00000008	0x00008030
      	0x07300	0x80208020	0x00008020	0x00008830
      	0x07300	0x00100010	0x00000010	0x00008830
      	0x0E184	0x00020002	0x00000002	0x00000022
      	0x0E180	0x20002000	0x00002000	0x00002000
      	0x02580	0x00010000	0x00000001	0x00000004
      	0x02580	0x00060004	0x00000006	0x00000004
      	0x07014	0x01000100	0x00000100	0x00002100
      	0x0E100	0x00100010	0x00000010	0x00008050
      
      After:
      	Address	val		mask		read
      	0x02580	0x00070004	0x00000007	0x00000004
      	0x07004	0x00420042	0x00000042	0x000029C2
      	0x07014	0x21002100	0x00002100	0x00002100
      	0x07300	0x80308030	0x00008030	0x00008830
      	0x0E100	0x00100010	0x00000010	0x00008050
      	0x0E180	0x20002000	0x00002000	0x00002000
      	0x0E184	0x00220022	0x00000022	0x00000022
      	0x0E188	0x00080000	0x00000008	0x00008030
      	0x0E194	0x01140114	0x00000114	0x00000114
      	0x0E4F0	0x81008100	0x00008100	0xFFFF8120
      Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Cc: Oscar Mateo <oscar.mateo@intel.com>
      Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
      Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
      Reviewed-by: default avatarMika Kuoppala <mika.kuoppala@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180615120207.13952-1-chris@chris-wilson.co.uk
      548764bb
  2. 14 Jun, 2018 30 commits
  3. 13 Jun, 2018 1 commit
  4. 12 Jun, 2018 6 commits