drm/i915/selftests: Teach execlists to take intel_gt as its argument
Subsystems (2)
PATCH 1/1 drm/i915/selftests: Teach execlists to take intel_gt as its argument
The execlists selftests are hardware centric and so want to use the gt as its target.
--- drivers/gpu/drm/i915/gt/selftest_lrc.c | 280 ++++++++++++------------- 1 file changed, 138 insertions(+), 142 deletions(-)
drivers/gpu/drm/i915/gt/selftest_lrc.c +138 -142
@@ -51,20 +51,20 @@ static struct i915_vma *create_scratch(struct intel_gt *gt)static int live_sanitycheck (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_engines_iter it;struct i915_gem_context *ctx;struct intel_context *ce;struct igt_spinner spin;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_CONTEXTS (i915)) +if (!HAS_LOGICAL_RING_CONTEXTS (gt->i915))return 0 ; -if (igt_spinner_init (&spin, &i915->gt)) +if (igt_spinner_init (&spin, gt))return -ENOMEM ; - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx) goto err_spin;
@@ -81,13 +81,13 @@ static int live_sanitycheck(void *arg)if (!igt_wait_for_spinner (&spin, rq)) {GEM_TRACE ("spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx; }igt_spinner_end (&spin); -if (igt_flush_test (i915)) { +if (igt_flush_test (gt->i915)) { err = -EIO ; goto err_ctx; }
@@ -416,7 +416,7 @@ slice_semaphore_queue(struct intel_engine_cs *outer,static int live_timeslice_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct drm_i915_gem_object *obj;struct i915_vma *vma;void *vaddr;
@@ -432,11 +432,11 @@ static int live_timeslice_preempt(void *arg)* ready task. */ - obj =i915_gem_object_create_internal (i915,PAGE_SIZE ); + obj =i915_gem_object_create_internal (gt->i915,PAGE_SIZE );if (IS_ERR (obj))return PTR_ERR (obj); - vma =i915_vma_instance (obj, &i915->ggtt.vm,NULL ); + vma =i915_vma_instance (obj, >->ggtt->vm,NULL );if (IS_ERR (vma)) { err =PTR_ERR (vma); goto err_obj;
@@ -456,7 +456,7 @@ static int live_timeslice_preempt(void *arg)struct intel_engine_cs *engine;enum intel_engine_id id; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {if (!intel_engine_has_preemption (engine))continue ;
@@ -466,7 +466,7 @@ static int live_timeslice_preempt(void *arg)if (err) goto err_pin; -if (igt_flush_test (i915)) { +if (igt_flush_test (gt->i915)) { err = -EIO ; goto err_pin; }
@@ -484,7 +484,7 @@ static int live_timeslice_preempt(void *arg)static int live_busywait_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct intel_engine_cs *engine;struct drm_i915_gem_object *obj;
@@ -498,19 +498,19 @@ static int live_busywait_preempt(void *arg)* preempt the busywaits used to synchronise between rings. */ - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi)return -ENOMEM ; ctx_hi->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MAX_USER_PRIORITY ); - ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi; ctx_lo->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MIN_USER_PRIORITY ); - obj =i915_gem_object_create_internal (i915,PAGE_SIZE ); + obj =i915_gem_object_create_internal (gt->i915,PAGE_SIZE );if (IS_ERR (obj)) { err =PTR_ERR (obj); goto err_ctx_lo;
@@ -522,7 +522,7 @@ static int live_busywait_preempt(void *arg) goto err_obj; } - vma =i915_vma_instance (obj, &i915->ggtt.vm,NULL ); + vma =i915_vma_instance (obj, >->ggtt->vm,NULL );if (IS_ERR (vma)) { err =PTR_ERR (vma); goto err_map;
@@ -532,7 +532,7 @@ static int live_busywait_preempt(void *arg)if (err) goto err_map; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct i915_request *lo, *hi;struct igt_live_test t;u32 *cs;
@@ -543,7 +543,7 @@ static int live_busywait_preempt(void *arg)if (!intel_engine_can_store_dword (engine))continue ; -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_vma; }
@@ -623,7 +623,7 @@ static int live_busywait_preempt(void *arg)i915_request_add (hi);if (i915_request_wait (lo,0 ,HZ /5 ) <0 ) { -struct drm_printer p =drm_info_printer (i915->drm.dev); +struct drm_printer p =drm_info_printer (gt->i915->drm.dev);pr_err ("%s: Failed to preempt semaphore busywait!\n" , engine->name);
@@ -631,7 +631,7 @@ static int live_busywait_preempt(void *arg)intel_engine_dump (engine, &p,"%s\n" , engine->name);GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_vma; }
@@ -677,45 +677,45 @@ spinner_create_request(struct igt_spinner *spin,static int live_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct igt_spinner spin_hi, spin_lo;struct intel_engine_cs *engine;enum intel_engine_id id;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (!(i915->caps.scheduler &I915_SCHEDULER_CAP_PREEMPTION )) +if (!(gt->i915->caps.scheduler &I915_SCHEDULER_CAP_PREEMPTION ))pr_err ("Logical preemption supported, but not exposed\n" ); -if (igt_spinner_init (&spin_hi, &i915->gt)) +if (igt_spinner_init (&spin_hi, gt))return -ENOMEM ; -if (igt_spinner_init (&spin_lo, &i915->gt)) +if (igt_spinner_init (&spin_lo, gt)) goto err_spin_hi; - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi) goto err_spin_lo; ctx_hi->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MAX_USER_PRIORITY ); - ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi; ctx_lo->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MIN_USER_PRIORITY ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct igt_live_test t;struct i915_request *rq;if (!intel_engine_has_preemption (engine))continue ; -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_ctx_lo; }
@@ -731,7 +731,7 @@ static int live_preempt(void *arg)if (!igt_wait_for_spinner (&spin_lo, rq)) {GEM_TRACE ("lo spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }
@@ -748,7 +748,7 @@ static int live_preempt(void *arg)if (!igt_wait_for_spinner (&spin_hi, rq)) {GEM_TRACE ("hi spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }
@@ -776,7 +776,7 @@ static int live_preempt(void *arg)static int live_late_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct igt_spinner spin_hi, spin_lo;struct intel_engine_cs *engine;
@@ -784,34 +784,34 @@ static int live_late_preempt(void *arg)enum intel_engine_id id;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (igt_spinner_init (&spin_hi, &i915->gt)) +if (igt_spinner_init (&spin_hi, gt))return -ENOMEM ; -if (igt_spinner_init (&spin_lo, &i915->gt)) +if (igt_spinner_init (&spin_lo, gt)) goto err_spin_hi; - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi) goto err_spin_lo; - ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi;/* Make sure ctx_lo stays before ctx_hi until we trigger preemption. */ ctx_lo->sched.priority =I915_USER_PRIORITY (1 ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct igt_live_test t;struct i915_request *rq;if (!intel_engine_has_preemption (engine))continue ; -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_ctx_lo; }
@@ -875,7 +875,7 @@ static int live_late_preempt(void *arg) err_wedged:igt_spinner_end (&spin_hi);igt_spinner_end (&spin_lo); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }
@@ -885,14 +885,13 @@ struct preempt_client {struct i915_gem_context *ctx; }; -static int preempt_client_init (struct drm_i915_private *i915, -struct preempt_client *c) +static int preempt_client_init (struct intel_gt *gt,struct preempt_client *c) { - c->ctx =kernel_context (i915); + c->ctx =kernel_context (gt->i915);if (!c->ctx)return -ENOMEM ; -if (igt_spinner_init (&c->spin, &i915->gt)) +if (igt_spinner_init (&c->spin, gt)) goto err_ctx;return 0 ;
@@ -910,7 +909,7 @@ static void preempt_client_fini(struct preempt_client *c)static int live_nopreempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *engine;struct preempt_client a, b;enum intel_engine_id id;
@@ -921,16 +920,16 @@ static int live_nopreempt(void *arg)* that may be being observed and not want to be interrupted. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (preempt_client_init (i915, &a)) +if (preempt_client_init (gt, &a))return -ENOMEM ; -if (preempt_client_init (i915, &b)) +if (preempt_client_init (gt, &b)) goto err_client_a; b.ctx->sched.priority =I915_USER_PRIORITY (I915_PRIORITY_MAX ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct i915_request *rq_a, *rq_b;if (!intel_engine_has_preemption (engine))
@@ -990,7 +989,7 @@ static int live_nopreempt(void *arg) goto err_wedged; } -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged; }
@@ -1004,14 +1003,14 @@ static int live_nopreempt(void *arg) err_wedged:igt_spinner_end (&b.spin);igt_spinner_end (&a.spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_b; }static int live_suppress_self_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *engine;struct i915_sched_attr attr = { .priority =I915_USER_PRIORITY (I915_PRIORITY_MAX )
@@ -1027,28 +1026,28 @@ static int live_suppress_self_preempt(void *arg)* completion event. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;/* presume black blox */ -if (intel_vgpu_active (i915)) +if (intel_vgpu_active (gt->i915))return 0 ;/* GVT forces single port & request submission */ -if (preempt_client_init (i915, &a)) +if (preempt_client_init (gt, &a))return -ENOMEM ; -if (preempt_client_init (i915, &b)) +if (preempt_client_init (gt, &b)) goto err_client_a; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct i915_request *rq_a, *rq_b;int depth;if (!intel_engine_has_preemption (engine))continue ; -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged;intel_engine_pm_get (engine);
@@ -1109,7 +1108,7 @@ static int live_suppress_self_preempt(void *arg) }intel_engine_pm_put (engine); -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged; }
@@ -1123,7 +1122,7 @@ static int live_suppress_self_preempt(void *arg) err_wedged:igt_spinner_end (&b.spin);igt_spinner_end (&a.spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_b; }
@@ -1183,7 +1182,7 @@ static void dummy_request_free(struct i915_request *dummy)static int live_suppress_wait_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct preempt_client client[4 ];struct intel_engine_cs *engine;enum intel_engine_id id;
@@ -1196,19 +1195,19 @@ static int live_suppress_wait_preempt(void *arg)* not needlessly generate preempt-to-idle cycles. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (preempt_client_init (i915, &client[0 ]))/* ELSP[0] */ +if (preempt_client_init (gt, &client[0 ]))/* ELSP[0] */ return -ENOMEM ; -if (preempt_client_init (i915, &client[1 ]))/* ELSP[1] */ +if (preempt_client_init (gt, &client[1 ]))/* ELSP[1] */ goto err_client_0; -if (preempt_client_init (i915, &client[2 ]))/* head of queue */ +if (preempt_client_init (gt, &client[2 ]))/* head of queue */ goto err_client_1; -if (preempt_client_init (i915, &client[3 ]))/* bystander */ +if (preempt_client_init (gt, &client[3 ]))/* bystander */ goto err_client_2; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {int depth;if (!intel_engine_has_preemption (engine))
@@ -1263,7 +1262,7 @@ static int live_suppress_wait_preempt(void *arg)for (i =0 ; i <ARRAY_SIZE (client); i++)igt_spinner_end (&client[i].spin); -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged;if (engine->execlists.preempt_hang.count) {
@@ -1291,14 +1290,14 @@ static int live_suppress_wait_preempt(void *arg) err_wedged:for (i =0 ; i <ARRAY_SIZE (client); i++)igt_spinner_end (&client[i].spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_3; }static int live_chain_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *engine;struct preempt_client hi, lo;enum intel_engine_id id;
@@ -1310,16 +1309,16 @@ static int live_chain_preempt(void *arg)* the previously submitted spinner in B. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (preempt_client_init (i915, &hi)) +if (preempt_client_init (gt, &hi))return -ENOMEM ; -if (preempt_client_init (i915, &lo)) +if (preempt_client_init (gt, &lo)) goto err_client_hi; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct i915_sched_attr attr = { .priority =I915_USER_PRIORITY (I915_PRIORITY_MAX ), };
@@ -1350,7 +1349,7 @@ static int live_chain_preempt(void *arg) goto err_wedged; } -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_wedged; }
@@ -1388,7 +1387,7 @@ static int live_chain_preempt(void *arg)igt_spinner_end (&hi.spin);if (i915_request_wait (rq,0 ,HZ /5 ) <0 ) {struct drm_printer p = -drm_info_printer (i915->drm.dev); +drm_info_printer (gt->i915->drm.dev);pr_err ("Failed to preempt over chain of %d\n" , count);
@@ -1404,7 +1403,7 @@ static int live_chain_preempt(void *arg)i915_request_add (rq);if (i915_request_wait (rq,0 ,HZ /5 ) <0 ) {struct drm_printer p = -drm_info_printer (i915->drm.dev); +drm_info_printer (gt->i915->drm.dev);pr_err ("Failed to flush low priority chain of %d requests\n" , count);
@@ -1430,45 +1429,45 @@ static int live_chain_preempt(void *arg) err_wedged:igt_spinner_end (&hi.spin);igt_spinner_end (&lo.spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_lo; }static int live_preempt_hang (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct igt_spinner spin_hi, spin_lo;struct intel_engine_cs *engine;enum intel_engine_id id;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (!intel_has_reset_engine (&i915->gt)) +if (!intel_has_reset_engine (gt))return 0 ; -if (igt_spinner_init (&spin_hi, &i915->gt)) +if (igt_spinner_init (&spin_hi, gt))return -ENOMEM ; -if (igt_spinner_init (&spin_lo, &i915->gt)) +if (igt_spinner_init (&spin_lo, gt)) goto err_spin_hi; - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi) goto err_spin_lo; ctx_hi->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MAX_USER_PRIORITY ); - ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi; ctx_lo->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MIN_USER_PRIORITY ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct i915_request *rq;if (!intel_engine_has_preemption (engine))
@@ -1485,7 +1484,7 @@ static int live_preempt_hang(void *arg)if (!igt_wait_for_spinner (&spin_lo, rq)) {GEM_TRACE ("lo spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }
@@ -1507,28 +1506,28 @@ static int live_preempt_hang(void *arg) HZ / 10)) {pr_err ("Preemption did not occur within timeout!" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; } -set_bit (I915_RESET_ENGINE + id, &i915->gt.reset.flags); +set_bit (I915_RESET_ENGINE + id, >->reset.flags);intel_engine_reset (engine,NULL ); -clear_bit (I915_RESET_ENGINE + id, &i915->gt.reset.flags); +clear_bit (I915_RESET_ENGINE + id, >->reset.flags); engine->execlists.preempt_hang.inject_hang = false;if (!igt_wait_for_spinner (&spin_hi, rq)) {GEM_TRACE ("hi spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }igt_spinner_end (&spin_hi);igt_spinner_end (&spin_lo); -if (igt_flush_test (i915)) { +if (igt_flush_test (gt->i915)) { err = -EIO ; goto err_ctx_lo; }
@@ -1557,7 +1556,7 @@ static int random_priority(struct rnd_state *rnd) }struct preempt_smoke { -struct drm_i915_private *i915; +struct intel_gt *gt;struct i915_gem_context **contexts;struct intel_engine_cs *engine;struct drm_i915_gem_object *batch;
@@ -1657,7 +1656,7 @@ static int smoke_crescendo(struct preempt_smoke *smoke, unsigned int flags)unsigned long count;int err =0 ; -for_each_engine (engine, smoke->i915, id) { +for_each_engine (engine, smoke->gt->i915, id) { arg[id] = *smoke; arg[id].engine = engine;if (!(flags &BATCH ))
@@ -1674,7 +1673,7 @@ static int smoke_crescendo(struct preempt_smoke *smoke, unsigned int flags) } count =0 ; -for_each_engine (engine, smoke->i915, id) { +for_each_engine (engine, smoke->gt->i915, id) {int status;if (IS_ERR_OR_NULL (tsk[id]))
@@ -1691,7 +1690,7 @@ static int smoke_crescendo(struct preempt_smoke *smoke, unsigned int flags)pr_info ("Submitted %lu crescendo:%x requests across %d engines and %d contexts\n" , count, flags, -RUNTIME_INFO (smoke->i915)->num_engines, smoke->ncontext); +RUNTIME_INFO (smoke->gt->i915)->num_engines, smoke->ncontext);return 0 ; }
@@ -1703,7 +1702,7 @@ static int smoke_random(struct preempt_smoke *smoke, unsigned int flags) count =0 ; do { - for_each_engine(smoke->engine, smoke->i915, id) { + for_each_engine(smoke->engine, smoke->gt->i915, id) { struct i915_gem_context *ctx = smoke_context(smoke); int err;
@@ -1719,14 +1718,14 @@ static int smoke_random(struct preempt_smoke *smoke, unsigned int flags)pr_info ("Submitted %lu random:%x requests across %d engines and %d contexts\n" , count, flags, -RUNTIME_INFO (smoke->i915)->num_engines, smoke->ncontext); +RUNTIME_INFO (smoke->gt->i915)->num_engines, smoke->ncontext);return 0 ; }static int live_preempt_smoke (void *arg) {struct preempt_smoke smoke = { - .i915 = arg, + .gt = arg, .prng =I915_RND_STATE_INITIALIZER (i915_selftest.random_seed), .ncontext =1024 , };
@@ -1736,7 +1735,7 @@ static int live_preempt_smoke(void *arg)u32 *cs;int n; -if (!HAS_LOGICAL_RING_PREEMPTION (smoke.i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (smoke.gt->i915))return 0 ; smoke.contexts = kmalloc_array(smoke.ncontext,
@@ -1745,7 +1744,8 @@ static int live_preempt_smoke(void *arg)if (!smoke.contexts)return -ENOMEM ; - smoke.batch =i915_gem_object_create_internal (smoke.i915,PAGE_SIZE ); + smoke.batch = +i915_gem_object_create_internal (smoke.gt->i915,PAGE_SIZE );if (IS_ERR (smoke.batch)) { err =PTR_ERR (smoke.batch); goto err_free;
@@ -1762,13 +1762,13 @@ static int live_preempt_smoke(void *arg)i915_gem_object_flush_map (smoke.batch);i915_gem_object_unpin_map (smoke.batch); -if (igt_live_test_begin (&t, smoke.i915, __func__,"all" )) { +if (igt_live_test_begin (&t, smoke.gt->i915, __func__,"all" )) { err = -EIO ; goto err_batch; }for (n =0 ; n < smoke.ncontext; n++) { - smoke.contexts[n] =kernel_context (smoke.i915); + smoke.contexts[n] =kernel_context (smoke.gt->i915);if (!smoke.contexts[n]) goto err_ctx; }
@@ -1801,7 +1801,7 @@ static int live_preempt_smoke(void *arg)return err; } -static int nop_virtual_engine(struct drm_i915_private *i915, +static int nop_virtual_engine(struct intel_gt *gt, struct intel_engine_cs **siblings, unsigned int nsibling, unsigned int nctx,
@@ -1820,7 +1820,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915,GEM_BUG_ON (!nctx || nctx >ARRAY_SIZE (ctx));for (n =0 ; n < nctx; n++) { - ctx[n] =kernel_context (i915); + ctx[n] =kernel_context (gt->i915);if (!ctx[n]) { err = -ENOMEM ; nctx = n;
@@ -1845,7 +1845,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915, } } - err =igt_live_test_begin (&t, i915, __func__, ve[0 ]->engine->name); + err =igt_live_test_begin (&t, gt->i915, __func__, ve[0 ]->engine->name);if (err) goto out;
@@ -1892,7 +1892,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915, request[nc]->fence.context, request[nc]->fence.seqno);GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt);break ; } }
@@ -1914,7 +1914,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915, prime, div64_u64(ktime_to_ns(times[1]), prime)); out: -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) err = -EIO ;for (nc =0 ; nc < nctx; nc++) {
@@ -1927,19 +1927,18 @@ static int nop_virtual_engine(struct drm_i915_private *i915,static int live_virtual_engine (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ];struct intel_engine_cs *engine; -struct intel_gt *gt = &i915->gt;enum intel_engine_id id;unsigned int class, inst;int err; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ; -for_each_engine (engine, i915, id) { - err =nop_virtual_engine (i915, &engine,1 ,1 ,0 ); +for_each_engine (engine, gt->i915, id) { + err =nop_virtual_engine (gt, &engine,1 ,1 ,0 );if (err) {pr_err ("Failed to wrap engine %s: err=%d\n" , engine->name, err);
@@ -1961,13 +1960,13 @@ static int live_virtual_engine(void *arg)continue ;for (n =1 ; n <= nsibling +1 ; n++) { - err =nop_virtual_engine (i915, siblings, nsibling, + err =nop_virtual_engine (gt, siblings, nsibling, n,0 );if (err)return err; } - err =nop_virtual_engine (i915, siblings, nsibling, n,CHAIN ); + err =nop_virtual_engine (gt, siblings, nsibling, n,CHAIN );if (err)return err; }
@@ -1975,7 +1974,7 @@ static int live_virtual_engine(void *arg)return 0 ; } -static int mask_virtual_engine (struct drm_i915_private *i915, +static int mask_virtual_engine (struct intel_gt *gt,struct intel_engine_cs **siblings,unsigned int nsibling) {
@@ -1991,7 +1990,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915,* restrict it to our desired engine within the virtual engine. */ - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx)return -ENOMEM ;
@@ -2005,7 +2004,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915,if (err) goto out_put; - err =igt_live_test_begin (&t, i915, __func__, ve->engine->name); + err =igt_live_test_begin (&t, gt->i915, __func__, ve->engine->name);if (err) goto out_unpin;
@@ -2036,7 +2035,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915, request[n]->fence.context, request[n]->fence.seqno);GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto out; }
@@ -2052,7 +2051,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915, err =igt_live_test_end (&t); out: -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) err = -EIO ;for (n =0 ; n < nsibling; n++)
@@ -2069,13 +2068,12 @@ static int mask_virtual_engine(struct drm_i915_private *i915,static int live_virtual_mask (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ]; -struct intel_gt *gt = &i915->gt;unsigned int class, inst;int err; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;for (class =0 ; class <=MAX_ENGINE_CLASS ; class++) {
@@ -2091,7 +2089,7 @@ static int live_virtual_mask(void *arg)if (nsibling <2 )continue ; - err =mask_virtual_engine (i915, siblings, nsibling); + err =mask_virtual_engine (gt, siblings, nsibling);if (err)return err; }
@@ -2099,7 +2097,7 @@ static int live_virtual_mask(void *arg)return 0 ; } -static int preserved_virtual_engine (struct drm_i915_private *i915, +static int preserved_virtual_engine (struct intel_gt *gt,struct intel_engine_cs **siblings,unsigned int nsibling) {
@@ -2112,7 +2110,7 @@ static int preserved_virtual_engine(struct drm_i915_private *i915,int err =0 ;u32 *cs; - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx)return -ENOMEM ;
@@ -2132,7 +2130,7 @@ static int preserved_virtual_engine(struct drm_i915_private *i915,if (err) goto out_put; - err =igt_live_test_begin (&t, i915, __func__, ve->engine->name); + err =igt_live_test_begin (&t, gt->i915, __func__, ve->engine->name);if (err) goto out_unpin;
@@ -2212,9 +2210,8 @@ static int preserved_virtual_engine(struct drm_i915_private *i915,static int live_virtual_preserved (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ]; -struct intel_gt *gt = &i915->gt;unsigned int class, inst;/*
@@ -2223,11 +2220,11 @@ static int live_virtual_preserved(void *arg)* are preserved. */ -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;/* As we use CS_GPR we cannot run before they existed on all engines. */ -if (INTEL_GEN (i915) <9 ) +if (INTEL_GEN (gt->i915) <9 )return 0 ;for (class =0 ; class <=MAX_ENGINE_CLASS ; class++) {
@@ -2243,7 +2240,7 @@ static int live_virtual_preserved(void *arg)if (nsibling <2 )continue ; - err =preserved_virtual_engine (i915, siblings, nsibling); + err =preserved_virtual_engine (gt, siblings, nsibling);if (err)return err; }
@@ -2251,7 +2248,7 @@ static int live_virtual_preserved(void *arg)return 0 ; } -static int bond_virtual_engine(struct drm_i915_private *i915, +static int bond_virtual_engine(struct intel_gt *gt, unsigned int class, struct intel_engine_cs **siblings, unsigned int nsibling,
@@ -2267,13 +2264,13 @@ static int bond_virtual_engine(struct drm_i915_private *i915,GEM_BUG_ON (nsibling >=ARRAY_SIZE (rq) -1 ); - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx)return -ENOMEM ; err =0 ; rq[0 ] =ERR_PTR (-ENOMEM ); -for_each_engine (master, i915, id) { +for_each_engine (master, gt->i915, id) {struct i915_sw_fence fence = {};if (master->class == class)
@@ -2378,7 +2375,7 @@ static int bond_virtual_engine(struct drm_i915_private *i915, out:for (n =0 ; !IS_ERR (rq[n]); n++)i915_request_put (rq[n]); -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) err = -EIO ;kernel_context_close (ctx);
@@ -2395,13 +2392,12 @@ static int live_virtual_bond(void *arg) { "schedule", BOND_SCHEDULE }, { }, }; -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ]; -struct intel_gt *gt = &i915->gt;unsigned int class, inst;int err; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;for (class =0 ; class <=MAX_ENGINE_CLASS ; class++) {
@@ -2420,7 +2416,7 @@ static int live_virtual_bond(void *arg)continue ;for (p = phases; p->name; p++) { - err =bond_virtual_engine (i915, + err =bond_virtual_engine (gt, class, siblings, nsibling, p->flags);if (err) {
@@ -2462,7 +2458,7 @@ int intel_execlists_live_selftests(struct drm_i915_private *i915)if (intel_gt_is_wedged (&i915->gt))return 0 ; -return i915_live_subtests (tests, i915); +return intel_gt_live_subtests (tests, &i915->gt); }static void hexdump (const void *buf,size_t len)
Signature · 6 lines
2.23.0 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
PATCH v2 1/1 drm/i915/selftests: Teach execlists to take intel_gt as its argument
The execlists selftests are hardware centric and so want to use the gt as its target.
--- drivers/gpu/drm/i915/gt/selftest_lrc.c | 290 ++++++++++++------------- 1 file changed, 143 insertions(+), 147 deletions(-)
drivers/gpu/drm/i915/gt/selftest_lrc.c +143 -147
@@ -51,20 +51,20 @@ static struct i915_vma *create_scratch(struct intel_gt *gt)static int live_sanitycheck (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_engines_iter it;struct i915_gem_context *ctx;struct intel_context *ce;struct igt_spinner spin;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_CONTEXTS (i915)) +if (!HAS_LOGICAL_RING_CONTEXTS (gt->i915))return 0 ; -if (igt_spinner_init (&spin, &i915->gt)) +if (igt_spinner_init (&spin, gt))return -ENOMEM ; - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx) goto err_spin;
@@ -81,13 +81,13 @@ static int live_sanitycheck(void *arg)if (!igt_wait_for_spinner (&spin, rq)) {GEM_TRACE ("spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx; }igt_spinner_end (&spin); -if (igt_flush_test (i915)) { +if (igt_flush_test (gt->i915)) { err = -EIO ; goto err_ctx; }
@@ -102,7 +102,7 @@ static int live_sanitycheck(void *arg)return err; } -static int live_unlite_restore (struct drm_i915_private *i915,int prio) +static int live_unlite_restore (struct intel_gt *gt,int prio) {struct intel_engine_cs *engine;struct i915_gem_context *ctx;
@@ -115,15 +115,15 @@ static int live_unlite_restore(struct drm_i915_private *i915, int prio)* on the same engine from the same parent context. */ -if (igt_spinner_init (&spin, &i915->gt)) +if (igt_spinner_init (&spin, gt))return err; - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx) goto err_spin; err =0 ; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct intel_context *ce[2 ] = {};struct i915_request *rq[2 ];struct igt_live_test t;
@@ -135,7 +135,7 @@ static int live_unlite_restore(struct drm_i915_private *i915, int prio)if (!intel_engine_can_store_dword (engine))continue ; -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ;break ; }
@@ -416,7 +416,7 @@ slice_semaphore_queue(struct intel_engine_cs *outer,static int live_timeslice_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct drm_i915_gem_object *obj;struct i915_vma *vma;void *vaddr;
@@ -432,11 +432,11 @@ static int live_timeslice_preempt(void *arg)* ready task. */ - obj =i915_gem_object_create_internal (i915,PAGE_SIZE ); + obj =i915_gem_object_create_internal (gt->i915,PAGE_SIZE );if (IS_ERR (obj))return PTR_ERR (obj); - vma =i915_vma_instance (obj, &i915->ggtt.vm,NULL ); + vma =i915_vma_instance (obj, >->ggtt->vm,NULL );if (IS_ERR (vma)) { err =PTR_ERR (vma); goto err_obj;
@@ -456,7 +456,7 @@ static int live_timeslice_preempt(void *arg)struct intel_engine_cs *engine;enum intel_engine_id id; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {if (!intel_engine_has_preemption (engine))continue ;
@@ -466,7 +466,7 @@ static int live_timeslice_preempt(void *arg)if (err) goto err_pin; -if (igt_flush_test (i915)) { +if (igt_flush_test (gt->i915)) { err = -EIO ; goto err_pin; }
@@ -484,7 +484,7 @@ static int live_timeslice_preempt(void *arg)static int live_busywait_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct intel_engine_cs *engine;struct drm_i915_gem_object *obj;
@@ -498,19 +498,19 @@ static int live_busywait_preempt(void *arg)* preempt the busywaits used to synchronise between rings. */ - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi)return -ENOMEM ; ctx_hi->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MAX_USER_PRIORITY ); - ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi; ctx_lo->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MIN_USER_PRIORITY ); - obj =i915_gem_object_create_internal (i915,PAGE_SIZE ); + obj =i915_gem_object_create_internal (gt->i915,PAGE_SIZE );if (IS_ERR (obj)) { err =PTR_ERR (obj); goto err_ctx_lo;
@@ -522,7 +522,7 @@ static int live_busywait_preempt(void *arg) goto err_obj; } - vma =i915_vma_instance (obj, &i915->ggtt.vm,NULL ); + vma =i915_vma_instance (obj, >->ggtt->vm,NULL );if (IS_ERR (vma)) { err =PTR_ERR (vma); goto err_map;
@@ -532,7 +532,7 @@ static int live_busywait_preempt(void *arg)if (err) goto err_map; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct i915_request *lo, *hi;struct igt_live_test t;u32 *cs;
@@ -543,7 +543,7 @@ static int live_busywait_preempt(void *arg)if (!intel_engine_can_store_dword (engine))continue ; -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_vma; }
@@ -623,7 +623,7 @@ static int live_busywait_preempt(void *arg)i915_request_add (hi);if (i915_request_wait (lo,0 ,HZ /5 ) <0 ) { -struct drm_printer p =drm_info_printer (i915->drm.dev); +struct drm_printer p =drm_info_printer (gt->i915->drm.dev);pr_err ("%s: Failed to preempt semaphore busywait!\n" , engine->name);
@@ -631,7 +631,7 @@ static int live_busywait_preempt(void *arg)intel_engine_dump (engine, &p,"%s\n" , engine->name);GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_vma; }
@@ -677,45 +677,45 @@ spinner_create_request(struct igt_spinner *spin,static int live_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct igt_spinner spin_hi, spin_lo;struct intel_engine_cs *engine;enum intel_engine_id id;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (!(i915->caps.scheduler &I915_SCHEDULER_CAP_PREEMPTION )) +if (!(gt->i915->caps.scheduler &I915_SCHEDULER_CAP_PREEMPTION ))pr_err ("Logical preemption supported, but not exposed\n" ); -if (igt_spinner_init (&spin_hi, &i915->gt)) +if (igt_spinner_init (&spin_hi, gt))return -ENOMEM ; -if (igt_spinner_init (&spin_lo, &i915->gt)) +if (igt_spinner_init (&spin_lo, gt)) goto err_spin_hi; - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi) goto err_spin_lo; ctx_hi->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MAX_USER_PRIORITY ); - ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi; ctx_lo->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MIN_USER_PRIORITY ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct igt_live_test t;struct i915_request *rq;if (!intel_engine_has_preemption (engine))continue ; -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_ctx_lo; }
@@ -731,7 +731,7 @@ static int live_preempt(void *arg)if (!igt_wait_for_spinner (&spin_lo, rq)) {GEM_TRACE ("lo spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }
@@ -748,7 +748,7 @@ static int live_preempt(void *arg)if (!igt_wait_for_spinner (&spin_hi, rq)) {GEM_TRACE ("hi spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }
@@ -776,7 +776,7 @@ static int live_preempt(void *arg)static int live_late_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct igt_spinner spin_hi, spin_lo;struct intel_engine_cs *engine;
@@ -784,34 +784,34 @@ static int live_late_preempt(void *arg)enum intel_engine_id id;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (igt_spinner_init (&spin_hi, &i915->gt)) +if (igt_spinner_init (&spin_hi, gt))return -ENOMEM ; -if (igt_spinner_init (&spin_lo, &i915->gt)) +if (igt_spinner_init (&spin_lo, gt)) goto err_spin_hi; - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi) goto err_spin_lo; - ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi;/* Make sure ctx_lo stays before ctx_hi until we trigger preemption. */ ctx_lo->sched.priority =I915_USER_PRIORITY (1 ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct igt_live_test t;struct i915_request *rq;if (!intel_engine_has_preemption (engine))continue ; -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_ctx_lo; }
@@ -875,7 +875,7 @@ static int live_late_preempt(void *arg) err_wedged:igt_spinner_end (&spin_hi);igt_spinner_end (&spin_lo); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }
@@ -885,14 +885,13 @@ struct preempt_client {struct i915_gem_context *ctx; }; -static int preempt_client_init (struct drm_i915_private *i915, -struct preempt_client *c) +static int preempt_client_init (struct intel_gt *gt,struct preempt_client *c) { - c->ctx =kernel_context (i915); + c->ctx =kernel_context (gt->i915);if (!c->ctx)return -ENOMEM ; -if (igt_spinner_init (&c->spin, &i915->gt)) +if (igt_spinner_init (&c->spin, gt)) goto err_ctx;return 0 ;
@@ -910,7 +909,7 @@ static void preempt_client_fini(struct preempt_client *c)static int live_nopreempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *engine;struct preempt_client a, b;enum intel_engine_id id;
@@ -921,16 +920,16 @@ static int live_nopreempt(void *arg)* that may be being observed and not want to be interrupted. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (preempt_client_init (i915, &a)) +if (preempt_client_init (gt, &a))return -ENOMEM ; -if (preempt_client_init (i915, &b)) +if (preempt_client_init (gt, &b)) goto err_client_a; b.ctx->sched.priority =I915_USER_PRIORITY (I915_PRIORITY_MAX ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct i915_request *rq_a, *rq_b;if (!intel_engine_has_preemption (engine))
@@ -990,7 +989,7 @@ static int live_nopreempt(void *arg) goto err_wedged; } -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged; }
@@ -1004,14 +1003,14 @@ static int live_nopreempt(void *arg) err_wedged:igt_spinner_end (&b.spin);igt_spinner_end (&a.spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_b; }static int live_suppress_self_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *engine;struct i915_sched_attr attr = { .priority =I915_USER_PRIORITY (I915_PRIORITY_MAX )
@@ -1027,28 +1026,28 @@ static int live_suppress_self_preempt(void *arg)* completion event. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;/* presume black blox */ -if (intel_vgpu_active (i915)) +if (intel_vgpu_active (gt->i915))return 0 ;/* GVT forces single port & request submission */ -if (preempt_client_init (i915, &a)) +if (preempt_client_init (gt, &a))return -ENOMEM ; -if (preempt_client_init (i915, &b)) +if (preempt_client_init (gt, &b)) goto err_client_a; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct i915_request *rq_a, *rq_b;int depth;if (!intel_engine_has_preemption (engine))continue ; -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged;intel_engine_pm_get (engine);
@@ -1109,7 +1108,7 @@ static int live_suppress_self_preempt(void *arg) }intel_engine_pm_put (engine); -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged; }
@@ -1123,7 +1122,7 @@ static int live_suppress_self_preempt(void *arg) err_wedged:igt_spinner_end (&b.spin);igt_spinner_end (&a.spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_b; }
@@ -1183,7 +1182,7 @@ static void dummy_request_free(struct i915_request *dummy)static int live_suppress_wait_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct preempt_client client[4 ];struct intel_engine_cs *engine;enum intel_engine_id id;
@@ -1196,19 +1195,19 @@ static int live_suppress_wait_preempt(void *arg)* not needlessly generate preempt-to-idle cycles. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (preempt_client_init (i915, &client[0 ]))/* ELSP[0] */ +if (preempt_client_init (gt, &client[0 ]))/* ELSP[0] */ return -ENOMEM ; -if (preempt_client_init (i915, &client[1 ]))/* ELSP[1] */ +if (preempt_client_init (gt, &client[1 ]))/* ELSP[1] */ goto err_client_0; -if (preempt_client_init (i915, &client[2 ]))/* head of queue */ +if (preempt_client_init (gt, &client[2 ]))/* head of queue */ goto err_client_1; -if (preempt_client_init (i915, &client[3 ]))/* bystander */ +if (preempt_client_init (gt, &client[3 ]))/* bystander */ goto err_client_2; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {int depth;if (!intel_engine_has_preemption (engine))
@@ -1263,7 +1262,7 @@ static int live_suppress_wait_preempt(void *arg)for (i =0 ; i <ARRAY_SIZE (client); i++)igt_spinner_end (&client[i].spin); -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged;if (engine->execlists.preempt_hang.count) {
@@ -1291,14 +1290,14 @@ static int live_suppress_wait_preempt(void *arg) err_wedged:for (i =0 ; i <ARRAY_SIZE (client); i++)igt_spinner_end (&client[i].spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_3; }static int live_chain_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *engine;struct preempt_client hi, lo;enum intel_engine_id id;
@@ -1310,16 +1309,16 @@ static int live_chain_preempt(void *arg)* the previously submitted spinner in B. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (preempt_client_init (i915, &hi)) +if (preempt_client_init (gt, &hi))return -ENOMEM ; -if (preempt_client_init (i915, &lo)) +if (preempt_client_init (gt, &lo)) goto err_client_hi; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct i915_sched_attr attr = { .priority =I915_USER_PRIORITY (I915_PRIORITY_MAX ), };
@@ -1350,7 +1349,7 @@ static int live_chain_preempt(void *arg) goto err_wedged; } -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_wedged; }
@@ -1388,7 +1387,7 @@ static int live_chain_preempt(void *arg)igt_spinner_end (&hi.spin);if (i915_request_wait (rq,0 ,HZ /5 ) <0 ) {struct drm_printer p = -drm_info_printer (i915->drm.dev); +drm_info_printer (gt->i915->drm.dev);pr_err ("Failed to preempt over chain of %d\n" , count);
@@ -1404,7 +1403,7 @@ static int live_chain_preempt(void *arg)i915_request_add (rq);if (i915_request_wait (rq,0 ,HZ /5 ) <0 ) {struct drm_printer p = -drm_info_printer (i915->drm.dev); +drm_info_printer (gt->i915->drm.dev);pr_err ("Failed to flush low priority chain of %d requests\n" , count);
@@ -1430,45 +1429,45 @@ static int live_chain_preempt(void *arg) err_wedged:igt_spinner_end (&hi.spin);igt_spinner_end (&lo.spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_lo; }static int live_preempt_hang (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct igt_spinner spin_hi, spin_lo;struct intel_engine_cs *engine;enum intel_engine_id id;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (!intel_has_reset_engine (&i915->gt)) +if (!intel_has_reset_engine (gt))return 0 ; -if (igt_spinner_init (&spin_hi, &i915->gt)) +if (igt_spinner_init (&spin_hi, gt))return -ENOMEM ; -if (igt_spinner_init (&spin_lo, &i915->gt)) +if (igt_spinner_init (&spin_lo, gt)) goto err_spin_hi; - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi) goto err_spin_lo; ctx_hi->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MAX_USER_PRIORITY ); - ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi; ctx_lo->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MIN_USER_PRIORITY ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {struct i915_request *rq;if (!intel_engine_has_preemption (engine))
@@ -1485,7 +1484,7 @@ static int live_preempt_hang(void *arg)if (!igt_wait_for_spinner (&spin_lo, rq)) {GEM_TRACE ("lo spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }
@@ -1507,28 +1506,28 @@ static int live_preempt_hang(void *arg) HZ / 10)) {pr_err ("Preemption did not occur within timeout!" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; } -set_bit (I915_RESET_ENGINE + id, &i915->gt.reset.flags); +set_bit (I915_RESET_ENGINE + id, >->reset.flags);intel_engine_reset (engine,NULL ); -clear_bit (I915_RESET_ENGINE + id, &i915->gt.reset.flags); +clear_bit (I915_RESET_ENGINE + id, >->reset.flags); engine->execlists.preempt_hang.inject_hang = false;if (!igt_wait_for_spinner (&spin_hi, rq)) {GEM_TRACE ("hi spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }igt_spinner_end (&spin_hi);igt_spinner_end (&spin_lo); -if (igt_flush_test (i915)) { +if (igt_flush_test (gt->i915)) { err = -EIO ; goto err_ctx_lo; }
@@ -1557,7 +1556,7 @@ static int random_priority(struct rnd_state *rnd) }struct preempt_smoke { -struct drm_i915_private *i915; +struct intel_gt *gt;struct i915_gem_context **contexts;struct intel_engine_cs *engine;struct drm_i915_gem_object *batch;
@@ -1657,7 +1656,7 @@ static int smoke_crescendo(struct preempt_smoke *smoke, unsigned int flags)unsigned long count;int err =0 ; -for_each_engine (engine, smoke->i915, id) { +for_each_engine (engine, smoke->gt->i915, id) { arg[id] = *smoke; arg[id].engine = engine;if (!(flags &BATCH ))
@@ -1674,7 +1673,7 @@ static int smoke_crescendo(struct preempt_smoke *smoke, unsigned int flags) } count =0 ; -for_each_engine (engine, smoke->i915, id) { +for_each_engine (engine, smoke->gt->i915, id) {int status;if (IS_ERR_OR_NULL (tsk[id]))
@@ -1691,7 +1690,7 @@ static int smoke_crescendo(struct preempt_smoke *smoke, unsigned int flags)pr_info ("Submitted %lu crescendo:%x requests across %d engines and %d contexts\n" , count, flags, -RUNTIME_INFO (smoke->i915)->num_engines, smoke->ncontext); +RUNTIME_INFO (smoke->gt->i915)->num_engines, smoke->ncontext);return 0 ; }
@@ -1703,7 +1702,7 @@ static int smoke_random(struct preempt_smoke *smoke, unsigned int flags) count =0 ; do { - for_each_engine(smoke->engine, smoke->i915, id) { + for_each_engine(smoke->engine, smoke->gt->i915, id) { struct i915_gem_context *ctx = smoke_context(smoke); int err;
@@ -1719,14 +1718,14 @@ static int smoke_random(struct preempt_smoke *smoke, unsigned int flags)pr_info ("Submitted %lu random:%x requests across %d engines and %d contexts\n" , count, flags, -RUNTIME_INFO (smoke->i915)->num_engines, smoke->ncontext); +RUNTIME_INFO (smoke->gt->i915)->num_engines, smoke->ncontext);return 0 ; }static int live_preempt_smoke (void *arg) {struct preempt_smoke smoke = { - .i915 = arg, + .gt = arg, .prng =I915_RND_STATE_INITIALIZER (i915_selftest.random_seed), .ncontext =1024 , };
@@ -1736,7 +1735,7 @@ static int live_preempt_smoke(void *arg)u32 *cs;int n; -if (!HAS_LOGICAL_RING_PREEMPTION (smoke.i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (smoke.gt->i915))return 0 ; smoke.contexts = kmalloc_array(smoke.ncontext,
@@ -1745,7 +1744,8 @@ static int live_preempt_smoke(void *arg)if (!smoke.contexts)return -ENOMEM ; - smoke.batch =i915_gem_object_create_internal (smoke.i915,PAGE_SIZE ); + smoke.batch = +i915_gem_object_create_internal (smoke.gt->i915,PAGE_SIZE );if (IS_ERR (smoke.batch)) { err =PTR_ERR (smoke.batch); goto err_free;
@@ -1762,13 +1762,13 @@ static int live_preempt_smoke(void *arg)i915_gem_object_flush_map (smoke.batch);i915_gem_object_unpin_map (smoke.batch); -if (igt_live_test_begin (&t, smoke.i915, __func__,"all" )) { +if (igt_live_test_begin (&t, smoke.gt->i915, __func__,"all" )) { err = -EIO ; goto err_batch; }for (n =0 ; n < smoke.ncontext; n++) { - smoke.contexts[n] =kernel_context (smoke.i915); + smoke.contexts[n] =kernel_context (smoke.gt->i915);if (!smoke.contexts[n]) goto err_ctx; }
@@ -1801,7 +1801,7 @@ static int live_preempt_smoke(void *arg)return err; } -static int nop_virtual_engine(struct drm_i915_private *i915, +static int nop_virtual_engine(struct intel_gt *gt, struct intel_engine_cs **siblings, unsigned int nsibling, unsigned int nctx,
@@ -1820,7 +1820,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915,GEM_BUG_ON (!nctx || nctx >ARRAY_SIZE (ctx));for (n =0 ; n < nctx; n++) { - ctx[n] =kernel_context (i915); + ctx[n] =kernel_context (gt->i915);if (!ctx[n]) { err = -ENOMEM ; nctx = n;
@@ -1845,7 +1845,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915, } } - err =igt_live_test_begin (&t, i915, __func__, ve[0 ]->engine->name); + err =igt_live_test_begin (&t, gt->i915, __func__, ve[0 ]->engine->name);if (err) goto out;
@@ -1892,7 +1892,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915, request[nc]->fence.context, request[nc]->fence.seqno);GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt);break ; } }
@@ -1914,7 +1914,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915, prime, div64_u64(ktime_to_ns(times[1]), prime)); out: -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) err = -EIO ;for (nc =0 ; nc < nctx; nc++) {
@@ -1927,19 +1927,18 @@ static int nop_virtual_engine(struct drm_i915_private *i915,static int live_virtual_engine (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ];struct intel_engine_cs *engine; -struct intel_gt *gt = &i915->gt;enum intel_engine_id id;unsigned int class, inst;int err; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ; -for_each_engine (engine, i915, id) { - err =nop_virtual_engine (i915, &engine,1 ,1 ,0 ); +for_each_engine (engine, gt->i915, id) { + err =nop_virtual_engine (gt, &engine,1 ,1 ,0 );if (err) {pr_err ("Failed to wrap engine %s: err=%d\n" , engine->name, err);
@@ -1961,13 +1960,13 @@ static int live_virtual_engine(void *arg)continue ;for (n =1 ; n <= nsibling +1 ; n++) { - err =nop_virtual_engine (i915, siblings, nsibling, + err =nop_virtual_engine (gt, siblings, nsibling, n,0 );if (err)return err; } - err =nop_virtual_engine (i915, siblings, nsibling, n,CHAIN ); + err =nop_virtual_engine (gt, siblings, nsibling, n,CHAIN );if (err)return err; }
@@ -1975,7 +1974,7 @@ static int live_virtual_engine(void *arg)return 0 ; } -static int mask_virtual_engine (struct drm_i915_private *i915, +static int mask_virtual_engine (struct intel_gt *gt,struct intel_engine_cs **siblings,unsigned int nsibling) {
@@ -1991,7 +1990,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915,* restrict it to our desired engine within the virtual engine. */ - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx)return -ENOMEM ;
@@ -2005,7 +2004,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915,if (err) goto out_put; - err =igt_live_test_begin (&t, i915, __func__, ve->engine->name); + err =igt_live_test_begin (&t, gt->i915, __func__, ve->engine->name);if (err) goto out_unpin;
@@ -2036,7 +2035,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915, request[n]->fence.context, request[n]->fence.seqno);GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto out; }
@@ -2052,7 +2051,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915, err =igt_live_test_end (&t); out: -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) err = -EIO ;for (n =0 ; n < nsibling; n++)
@@ -2069,13 +2068,12 @@ static int mask_virtual_engine(struct drm_i915_private *i915,static int live_virtual_mask (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ]; -struct intel_gt *gt = &i915->gt;unsigned int class, inst;int err; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;for (class =0 ; class <=MAX_ENGINE_CLASS ; class++) {
@@ -2091,7 +2089,7 @@ static int live_virtual_mask(void *arg)if (nsibling <2 )continue ; - err =mask_virtual_engine (i915, siblings, nsibling); + err =mask_virtual_engine (gt, siblings, nsibling);if (err)return err; }
@@ -2099,7 +2097,7 @@ static int live_virtual_mask(void *arg)return 0 ; } -static int preserved_virtual_engine (struct drm_i915_private *i915, +static int preserved_virtual_engine (struct intel_gt *gt,struct intel_engine_cs **siblings,unsigned int nsibling) {
@@ -2112,7 +2110,7 @@ static int preserved_virtual_engine(struct drm_i915_private *i915,int err =0 ;u32 *cs; - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx)return -ENOMEM ;
@@ -2132,7 +2130,7 @@ static int preserved_virtual_engine(struct drm_i915_private *i915,if (err) goto out_put; - err =igt_live_test_begin (&t, i915, __func__, ve->engine->name); + err =igt_live_test_begin (&t, gt->i915, __func__, ve->engine->name);if (err) goto out_unpin;
@@ -2212,9 +2210,8 @@ static int preserved_virtual_engine(struct drm_i915_private *i915,static int live_virtual_preserved (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ]; -struct intel_gt *gt = &i915->gt;unsigned int class, inst;/*
@@ -2223,11 +2220,11 @@ static int live_virtual_preserved(void *arg)* are preserved. */ -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;/* As we use CS_GPR we cannot run before they existed on all engines. */ -if (INTEL_GEN (i915) <9 ) +if (INTEL_GEN (gt->i915) <9 )return 0 ;for (class =0 ; class <=MAX_ENGINE_CLASS ; class++) {
@@ -2243,7 +2240,7 @@ static int live_virtual_preserved(void *arg)if (nsibling <2 )continue ; - err =preserved_virtual_engine (i915, siblings, nsibling); + err =preserved_virtual_engine (gt, siblings, nsibling);if (err)return err; }
@@ -2251,7 +2248,7 @@ static int live_virtual_preserved(void *arg)return 0 ; } -static int bond_virtual_engine(struct drm_i915_private *i915, +static int bond_virtual_engine(struct intel_gt *gt, unsigned int class, struct intel_engine_cs **siblings, unsigned int nsibling,
@@ -2267,13 +2264,13 @@ static int bond_virtual_engine(struct drm_i915_private *i915,GEM_BUG_ON (nsibling >=ARRAY_SIZE (rq) -1 ); - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx)return -ENOMEM ; err =0 ; rq[0 ] =ERR_PTR (-ENOMEM ); -for_each_engine (master, i915, id) { +for_each_engine (master, gt->i915, id) {struct i915_sw_fence fence = {};if (master->class == class)
@@ -2378,7 +2375,7 @@ static int bond_virtual_engine(struct drm_i915_private *i915, out:for (n =0 ; !IS_ERR (rq[n]); n++)i915_request_put (rq[n]); -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) err = -EIO ;kernel_context_close (ctx);
@@ -2395,13 +2392,12 @@ static int live_virtual_bond(void *arg) { "schedule", BOND_SCHEDULE }, { }, }; -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ]; -struct intel_gt *gt = &i915->gt;unsigned int class, inst;int err; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;for (class =0 ; class <=MAX_ENGINE_CLASS ; class++) {
@@ -2420,7 +2416,7 @@ static int live_virtual_bond(void *arg)continue ;for (p = phases; p->name; p++) { - err =bond_virtual_engine (i915, + err =bond_virtual_engine (gt, class, siblings, nsibling, p->flags);if (err) {
@@ -2462,7 +2458,7 @@ int intel_execlists_live_selftests(struct drm_i915_private *i915)if (intel_gt_is_wedged (&i915->gt))return 0 ; -return i915_live_subtests (tests, i915); +return intel_gt_live_subtests (tests, &i915->gt); }static void hexdump (const void *buf,size_t len)
Signature · 6 lines
2.23.0 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 69 lines · Chris Wilson
The execlists selftests are hardware centric and so want to use the gt as its target.
Signed-off-by Chris Wilson <[email protected]>Cc Tvrtko Ursulin <[email protected]>--- drivers/gpu/drm/i915/gt/selftest_lrc.c | 290 ++++++++++++------------- 1 file changed, 143 insertions(+), 147 deletions(-)drivers/gpu/drm/i915/gt/selftest_lrc.c +8
-8@@ -51,20 +51,20 @@ static struct i915_vma *create_scratch(struct intel_gt *gt)static int live_sanitycheck (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_engines_iter it;struct i915_gem_context *ctx;struct intel_context *ce;struct igt_spinner spin;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_CONTEXTS (i915)) +if (!HAS_LOGICAL_RING_CONTEXTS (gt->i915))return 0 ; -if (igt_spinner_init (&spin, &i915->gt)) +if (igt_spinner_init (&spin, gt))return -ENOMEM ; - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx) goto err_spin;@@ -81,13 +81,13 @@ static int live_sanitycheck(void *arg)if (!igt_wait_for_spinner (&spin, rq)) {GEM_TRACE ("spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx; }igt_spinner_end (&spin); -if (igt_flush_test (i915)) { +if (igt_flush_test (gt->i915)) { err = -EIO ; goto err_ctx; }@@ -102,7 +102,7 @@ static int live_sanitycheck(void *arg)return err; } -static int live_unlite_restore (struct drm_i915_private *i915,int prio) +static int live_unlite_restore (struct intel_gt *gt,int prio) {struct intel_engine_cs *engine;struct i915_gem_context *ctx;@@ -115,15 +115,15 @@ static int live_unlite_restore(struct drm_i915_private *i915, int prio)* on the same engine from the same parent context. */ -if (igt_spinner_init (&spin, &i915->gt)) +if (igt_spinner_init (&spin, gt))
drivers/gpu/drm/i915/gt/selftest_lrc.c static int live_unlite_restore(struct drm_i915_private *i915, int prio) · line 126
Quoted 10 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +2
-2return err; - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx) goto err_spin; err =0 ; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {
^^^
Quoted 36 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +4
-4struct intel_context *ce[2 ] = {};struct i915_request *rq[2 ];struct igt_live_test t;@@ -135,7 +135,7 @@ static int live_unlite_restore(struct drm_i915_private *i915, int prio)if (!intel_engine_can_store_dword (engine))continue ; -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ;break ; }@@ -416,7 +416,7 @@ slice_semaphore_queue(struct intel_engine_cs *outer,static int live_timeslice_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct drm_i915_gem_object *obj;struct i915_vma *vma;void *vaddr;@@ -432,11 +432,11 @@ static int live_timeslice_preempt(void *arg)* ready task. */ - obj =i915_gem_object_create_internal (i915,PAGE_SIZE ); + obj =i915_gem_object_create_internal (gt->i915,PAGE_SIZE );if (IS_ERR (obj))return PTR_ERR (obj); - vma =i915_vma_instance (obj, &i915->ggtt.vm,NULL ); + vma =i915_vma_instance (obj, >->ggtt->vm,NULL );if (IS_ERR (vma)) { err =PTR_ERR (vma); goto err_obj;
drivers/gpu/drm/i915/gt/selftest_lrc.c static int live_timeslice_preempt(void *arg) · line 459
Quoted 5 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +1
-1@@ -456,7 +456,7 @@ static int live_timeslice_preempt(void *arg)struct intel_engine_cs *engine;enum intel_engine_id id; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {
^^^
Quoted 54 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +6
-6if (!intel_engine_has_preemption (engine))continue ;@@ -466,7 +466,7 @@ static int live_timeslice_preempt(void *arg)if (err) goto err_pin; -if (igt_flush_test (i915)) { +if (igt_flush_test (gt->i915)) { err = -EIO ; goto err_pin; }@@ -484,7 +484,7 @@ static int live_timeslice_preempt(void *arg)static int live_busywait_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct intel_engine_cs *engine;struct drm_i915_gem_object *obj;@@ -498,19 +498,19 @@ static int live_busywait_preempt(void *arg)* preempt the busywaits used to synchronise between rings. */ - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi)return -ENOMEM ; ctx_hi->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MAX_USER_PRIORITY ); - ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi; ctx_lo->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MIN_USER_PRIORITY ); - obj =i915_gem_object_create_internal (i915,PAGE_SIZE ); + obj =i915_gem_object_create_internal (gt->i915,PAGE_SIZE );if (IS_ERR (obj)) { err =PTR_ERR (obj); goto err_ctx_lo;@@ -522,7 +522,7 @@ static int live_busywait_preempt(void *arg) goto err_obj; } - vma =i915_vma_instance (obj, &i915->ggtt.vm,NULL ); + vma =i915_vma_instance (obj, >->ggtt->vm,NULL );if (IS_ERR (vma)) { err =PTR_ERR (vma); goto err_map;
drivers/gpu/drm/i915/gt/selftest_lrc.c static int live_busywait_preempt(void *arg) · line 535
Quoted 5 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +1
-1@@ -532,7 +532,7 @@ static int live_busywait_preempt(void *arg)if (err) goto err_map; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {
^^^
Quoted 64 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +9
-9struct i915_request *lo, *hi;struct igt_live_test t;u32 *cs;@@ -543,7 +543,7 @@ static int live_busywait_preempt(void *arg)if (!intel_engine_can_store_dword (engine))continue ; -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_vma; }@@ -623,7 +623,7 @@ static int live_busywait_preempt(void *arg)i915_request_add (hi);if (i915_request_wait (lo,0 ,HZ /5 ) <0 ) { -struct drm_printer p =drm_info_printer (i915->drm.dev); +struct drm_printer p =drm_info_printer (gt->i915->drm.dev);pr_err ("%s: Failed to preempt semaphore busywait!\n" , engine->name);@@ -631,7 +631,7 @@ static int live_busywait_preempt(void *arg)intel_engine_dump (engine, &p,"%s\n" , engine->name);GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_vma; }@@ -677,45 +677,45 @@ spinner_create_request(struct igt_spinner *spin,static int live_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct igt_spinner spin_hi, spin_lo;struct intel_engine_cs *engine;enum intel_engine_id id;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (!(i915->caps.scheduler &I915_SCHEDULER_CAP_PREEMPTION )) +if (!(gt->i915->caps.scheduler &I915_SCHEDULER_CAP_PREEMPTION ))pr_err ("Logical preemption supported, but not exposed\n" ); -if (igt_spinner_init (&spin_hi, &i915->gt)) +if (igt_spinner_init (&spin_hi, gt))return -ENOMEM ; -if (igt_spinner_init (&spin_lo, &i915->gt)) +if (igt_spinner_init (&spin_lo, gt)) goto err_spin_hi; - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi) goto err_spin_lo; ctx_hi->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MAX_USER_PRIORITY );
drivers/gpu/drm/i915/gt/selftest_lrc.c spinner_create_request(struct igt_spinner *spin, · line 711
Quoted 10 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +2
-2- ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi; ctx_lo->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MIN_USER_PRIORITY ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {
^^^
Also, i915 local in this function might make sense if you feel like it.
Quoted 59 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +8
-8struct igt_live_test t;struct i915_request *rq;if (!intel_engine_has_preemption (engine))continue ; -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_ctx_lo; }@@ -731,7 +731,7 @@ static int live_preempt(void *arg)if (!igt_wait_for_spinner (&spin_lo, rq)) {GEM_TRACE ("lo spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }@@ -748,7 +748,7 @@ static int live_preempt(void *arg)if (!igt_wait_for_spinner (&spin_hi, rq)) {GEM_TRACE ("hi spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }@@ -776,7 +776,7 @@ static int live_preempt(void *arg)static int live_late_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct igt_spinner spin_hi, spin_lo;struct intel_engine_cs *engine;@@ -784,34 +784,34 @@ static int live_late_preempt(void *arg)enum intel_engine_id id;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (igt_spinner_init (&spin_hi, &i915->gt)) +if (igt_spinner_init (&spin_hi, gt))return -ENOMEM ; -if (igt_spinner_init (&spin_lo, &i915->gt)) +if (igt_spinner_init (&spin_lo, gt)) goto err_spin_hi; - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi) goto err_spin_lo;
drivers/gpu/drm/i915/gt/selftest_lrc.c static int live_late_preempt(void *arg) · line 807
Quoted 10 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +2
-2- ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi;/* Make sure ctx_lo stays before ctx_hi until we trigger preemption. */ ctx_lo->sched.priority =I915_USER_PRIORITY (1 ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {
^^^
Quoted 55 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +7
-8struct igt_live_test t;struct i915_request *rq;if (!intel_engine_has_preemption (engine))continue ; -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_ctx_lo; }@@ -875,7 +875,7 @@ static int live_late_preempt(void *arg) err_wedged:igt_spinner_end (&spin_hi);igt_spinner_end (&spin_lo); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }@@ -885,14 +885,13 @@ struct preempt_client {struct i915_gem_context *ctx; }; -static int preempt_client_init (struct drm_i915_private *i915, -struct preempt_client *c) +static int preempt_client_init (struct intel_gt *gt,struct preempt_client *c) { - c->ctx =kernel_context (i915); + c->ctx =kernel_context (gt->i915);if (!c->ctx)return -ENOMEM ; -if (igt_spinner_init (&c->spin, &i915->gt)) +if (igt_spinner_init (&c->spin, gt)) goto err_ctx;return 0 ;@@ -910,7 +909,7 @@ static void preempt_client_fini(struct preempt_client *c)static int live_nopreempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *engine;struct preempt_client a, b;enum intel_engine_id id;@@ -921,16 +920,16 @@ static int live_nopreempt(void *arg)* that may be being observed and not want to be interrupted. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ;
drivers/gpu/drm/i915/gt/selftest_lrc.c static int live_nopreempt(void *arg) · line 932
Quoted 10 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +3
-3-if (preempt_client_init (i915, &a)) +if (preempt_client_init (gt, &a))return -ENOMEM ; -if (preempt_client_init (i915, &b)) +if (preempt_client_init (gt, &b)) goto err_client_a; b.ctx->sched.priority =I915_USER_PRIORITY (I915_PRIORITY_MAX ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {
^^^
Quoted 44 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +6
-6struct i915_request *rq_a, *rq_b;if (!intel_engine_has_preemption (engine))@@ -990,7 +989,7 @@ static int live_nopreempt(void *arg) goto err_wedged; } -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged; }@@ -1004,14 +1003,14 @@ static int live_nopreempt(void *arg) err_wedged:igt_spinner_end (&b.spin);igt_spinner_end (&a.spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_b; }static int live_suppress_self_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *engine;struct i915_sched_attr attr = { .priority =I915_USER_PRIORITY (I915_PRIORITY_MAX )@@ -1027,28 +1026,28 @@ static int live_suppress_self_preempt(void *arg)* completion event. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;/* presume black blox */ -if (intel_vgpu_active (i915)) +if (intel_vgpu_active (gt->i915))return 0 ;/* GVT forces single port & request submission */
drivers/gpu/drm/i915/gt/selftest_lrc.c static int live_suppress_self_preempt(void *arg) · line 1043
Quoted 10 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +3
-3-if (preempt_client_init (i915, &a)) +if (preempt_client_init (gt, &a))return -ENOMEM ; -if (preempt_client_init (i915, &b)) +if (preempt_client_init (gt, &b)) goto err_client_a; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {
^^^
Quoted 51 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +7
-7struct i915_request *rq_a, *rq_b;int depth;if (!intel_engine_has_preemption (engine))continue ; -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged;intel_engine_pm_get (engine);@@ -1109,7 +1108,7 @@ static int live_suppress_self_preempt(void *arg) }intel_engine_pm_put (engine); -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged; }@@ -1123,7 +1122,7 @@ static int live_suppress_self_preempt(void *arg) err_wedged:igt_spinner_end (&b.spin);igt_spinner_end (&a.spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_b; }@@ -1183,7 +1182,7 @@ static void dummy_request_free(struct i915_request *dummy)static int live_suppress_wait_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct preempt_client client[4 ];struct intel_engine_cs *engine;enum intel_engine_id id;@@ -1196,19 +1195,19 @@ static int live_suppress_wait_preempt(void *arg)* not needlessly generate preempt-to-idle cycles. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (preempt_client_init (i915, &client[0 ]))/* ELSP[0] */ +if (preempt_client_init (gt, &client[0 ]))/* ELSP[0] */ return -ENOMEM ; -if (preempt_client_init (i915, &client[1 ]))/* ELSP[1] */ +if (preempt_client_init (gt, &client[1 ]))/* ELSP[1] */
drivers/gpu/drm/i915/gt/selftest_lrc.c static int live_suppress_wait_preempt(void *arg) · line 1210
Quoted 10 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +3
-3goto err_client_0; -if (preempt_client_init (i915, &client[2 ]))/* head of queue */ +if (preempt_client_init (gt, &client[2 ]))/* head of queue */ goto err_client_1; -if (preempt_client_init (i915, &client[3 ]))/* bystander */ +if (preempt_client_init (gt, &client[3 ]))/* bystander */ goto err_client_2; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {
^^^
Quoted 37 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +4
-4int depth;if (!intel_engine_has_preemption (engine))@@ -1263,7 +1262,7 @@ static int live_suppress_wait_preempt(void *arg)for (i =0 ; i <ARRAY_SIZE (client); i++)igt_spinner_end (&client[i].spin); -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) goto err_wedged;if (engine->execlists.preempt_hang.count) {@@ -1291,14 +1290,14 @@ static int live_suppress_wait_preempt(void *arg) err_wedged:for (i =0 ; i <ARRAY_SIZE (client); i++)igt_spinner_end (&client[i].spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_3; }static int live_chain_preempt (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *engine;struct preempt_client hi, lo;enum intel_engine_id id;@@ -1310,16 +1309,16 @@ static int live_chain_preempt(void *arg)* the previously submitted spinner in B. */ -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ;
drivers/gpu/drm/i915/gt/selftest_lrc.c static int live_chain_preempt(void *arg) · line 1321
Quoted 10 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +3
-3-if (preempt_client_init (i915, &hi)) +if (preempt_client_init (gt, &hi))return -ENOMEM ; -if (preempt_client_init (i915, &lo)) +if (preempt_client_init (gt, &lo)) goto err_client_hi; -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {
^^^
Quoted 72 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +10
-10struct i915_sched_attr attr = { .priority =I915_USER_PRIORITY (I915_PRIORITY_MAX ), };@@ -1350,7 +1349,7 @@ static int live_chain_preempt(void *arg) goto err_wedged; } -if (igt_live_test_begin (&t, i915, __func__, engine->name)) { +if (igt_live_test_begin (&t, gt->i915, __func__, engine->name)) { err = -EIO ; goto err_wedged; }@@ -1388,7 +1387,7 @@ static int live_chain_preempt(void *arg)igt_spinner_end (&hi.spin);if (i915_request_wait (rq,0 ,HZ /5 ) <0 ) {struct drm_printer p = -drm_info_printer (i915->drm.dev); +drm_info_printer (gt->i915->drm.dev);pr_err ("Failed to preempt over chain of %d\n" , count);@@ -1404,7 +1403,7 @@ static int live_chain_preempt(void *arg)i915_request_add (rq);if (i915_request_wait (rq,0 ,HZ /5 ) <0 ) {struct drm_printer p = -drm_info_printer (i915->drm.dev); +drm_info_printer (gt->i915->drm.dev);pr_err ("Failed to flush low priority chain of %d requests\n" , count);@@ -1430,45 +1429,45 @@ static int live_chain_preempt(void *arg) err_wedged:igt_spinner_end (&hi.spin);igt_spinner_end (&lo.spin); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_client_lo; }static int live_preempt_hang (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct i915_gem_context *ctx_hi, *ctx_lo;struct igt_spinner spin_hi, spin_lo;struct intel_engine_cs *engine;enum intel_engine_id id;int err = -ENOMEM ; -if (!HAS_LOGICAL_RING_PREEMPTION (i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (gt->i915))return 0 ; -if (!intel_has_reset_engine (&i915->gt)) +if (!intel_has_reset_engine (gt))return 0 ; -if (igt_spinner_init (&spin_hi, &i915->gt)) +if (igt_spinner_init (&spin_hi, gt))return -ENOMEM ; -if (igt_spinner_init (&spin_lo, &i915->gt)) +if (igt_spinner_init (&spin_lo, gt)) goto err_spin_hi; - ctx_hi =kernel_context (i915); + ctx_hi =kernel_context (gt->i915);if (!ctx_hi) goto err_spin_lo; ctx_hi->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MAX_USER_PRIORITY );
drivers/gpu/drm/i915/gt/selftest_lrc.c static int live_chain_preempt(void *arg) · line 1470
Quoted 10 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +2
-2- ctx_lo =kernel_context (i915); + ctx_lo =kernel_context (gt->i915);if (!ctx_lo) goto err_ctx_hi; ctx_lo->sched.priority =I915_USER_PRIORITY (I915_CONTEXT_MIN_USER_PRIORITY ); -for_each_engine (engine, i915, id) { +for_each_engine (engine, gt->i915, id) {
^^^
Quoted 56 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +7
-7struct i915_request *rq;if (!intel_engine_has_preemption (engine))@@ -1485,7 +1484,7 @@ static int live_preempt_hang(void *arg)if (!igt_wait_for_spinner (&spin_lo, rq)) {GEM_TRACE ("lo spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }@@ -1507,28 +1506,28 @@ static int live_preempt_hang(void *arg) HZ / 10)) {pr_err ("Preemption did not occur within timeout!" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; } -set_bit (I915_RESET_ENGINE + id, &i915->gt.reset.flags); +set_bit (I915_RESET_ENGINE + id, >->reset.flags);intel_engine_reset (engine,NULL ); -clear_bit (I915_RESET_ENGINE + id, &i915->gt.reset.flags); +clear_bit (I915_RESET_ENGINE + id, >->reset.flags); engine->execlists.preempt_hang.inject_hang = false;if (!igt_wait_for_spinner (&spin_hi, rq)) {GEM_TRACE ("hi spinner failed to start\n" );GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto err_ctx_lo; }igt_spinner_end (&spin_hi);igt_spinner_end (&spin_lo); -if (igt_flush_test (i915)) { +if (igt_flush_test (gt->i915)) { err = -EIO ; goto err_ctx_lo; }@@ -1557,7 +1556,7 @@ static int random_priority(struct rnd_state *rnd) }struct preempt_smoke { -struct drm_i915_private *i915; +struct intel_gt *gt;struct i915_gem_context **contexts;struct intel_engine_cs *engine;struct drm_i915_gem_object *batch;
drivers/gpu/drm/i915/gt/selftest_lrc.c static int smoke_crescendo(struct preempt_smoke *smoke, unsigned int flags) · line 1659
Quoted 5 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +1
-1@@ -1657,7 +1656,7 @@ static int smoke_crescendo(struct preempt_smoke *smoke, unsigned int flags)unsigned long count;int err =0 ; -for_each_engine (engine, smoke->i915, id) { +for_each_engine (engine, smoke->gt->i915, id) {
^^^
drivers/gpu/drm/i915/gt/selftest_lrc.c static int smoke_crescendo(struct preempt_smoke *smoke, unsigned int flags) · line 1676
Quoted 9 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +1
-1arg[id] = *smoke; arg[id].engine = engine;if (!(flags &BATCH ))@@ -1674,7 +1673,7 @@ static int smoke_crescendo(struct preempt_smoke *smoke, unsigned int flags) } count =0 ; -for_each_engine (engine, smoke->i915, id) { +for_each_engine (engine, smoke->gt->i915, id) {
^^^
Quoted 13 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +1
-1int status;if (IS_ERR_OR_NULL (tsk[id]))@@ -1691,7 +1690,7 @@ static int smoke_crescendo(struct preempt_smoke *smoke, unsigned int flags)pr_info ("Submitted %lu crescendo:%x requests across %d engines and %d contexts\n" , count, flags, -RUNTIME_INFO (smoke->i915)->num_engines, smoke->ncontext); +RUNTIME_INFO (smoke->gt->i915)->num_engines, smoke->ncontext);return 0 ; }
drivers/gpu/drm/i915/gt/selftest_lrc.c static int smoke_random(struct preempt_smoke *smoke, unsigned int flags) · line 1705
Quoted 5 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +1
-1@@ -1703,7 +1702,7 @@ static int smoke_random(struct preempt_smoke *smoke, unsigned int flags) count =0 ; do { - for_each_engine(smoke->engine, smoke->i915, id) { + for_each_engine(smoke->engine, smoke->gt->i915, id) {
^^^
Quoted 110 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +13
-13struct i915_gem_context *ctx =smoke_context (smoke);int err;@@ -1719,14 +1718,14 @@ static int smoke_random(struct preempt_smoke *smoke, unsigned int flags)pr_info ("Submitted %lu random:%x requests across %d engines and %d contexts\n" , count, flags, -RUNTIME_INFO (smoke->i915)->num_engines, smoke->ncontext); +RUNTIME_INFO (smoke->gt->i915)->num_engines, smoke->ncontext);return 0 ; }static int live_preempt_smoke (void *arg) {struct preempt_smoke smoke = { - .i915 = arg, + .gt = arg, .prng =I915_RND_STATE_INITIALIZER (i915_selftest.random_seed), .ncontext =1024 , };@@ -1736,7 +1735,7 @@ static int live_preempt_smoke(void *arg)u32 *cs;int n; -if (!HAS_LOGICAL_RING_PREEMPTION (smoke.i915)) +if (!HAS_LOGICAL_RING_PREEMPTION (smoke.gt->i915))return 0 ; smoke.contexts = kmalloc_array(smoke.ncontext,@@ -1745,7 +1744,8 @@ static int live_preempt_smoke(void *arg)if (!smoke.contexts)return -ENOMEM ; - smoke.batch =i915_gem_object_create_internal (smoke.i915,PAGE_SIZE ); + smoke.batch = +i915_gem_object_create_internal (smoke.gt->i915,PAGE_SIZE );if (IS_ERR (smoke.batch)) { err =PTR_ERR (smoke.batch); goto err_free;@@ -1762,13 +1762,13 @@ static int live_preempt_smoke(void *arg)i915_gem_object_flush_map (smoke.batch);i915_gem_object_unpin_map (smoke.batch); -if (igt_live_test_begin (&t, smoke.i915, __func__,"all" )) { +if (igt_live_test_begin (&t, smoke.gt->i915, __func__,"all" )) { err = -EIO ; goto err_batch; }for (n =0 ; n < smoke.ncontext; n++) { - smoke.contexts[n] =kernel_context (smoke.i915); + smoke.contexts[n] =kernel_context (smoke.gt->i915);if (!smoke.contexts[n]) goto err_ctx; }@@ -1801,7 +1801,7 @@ static int live_preempt_smoke(void *arg)return err; } -static int nop_virtual_engine(struct drm_i915_private *i915, +static int nop_virtual_engine(struct intel_gt *gt, struct intel_engine_cs **siblings, unsigned int nsibling, unsigned int nctx,@@ -1820,7 +1820,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915,GEM_BUG_ON (!nctx || nctx >ARRAY_SIZE (ctx));for (n =0 ; n < nctx; n++) { - ctx[n] =kernel_context (i915); + ctx[n] =kernel_context (gt->i915);if (!ctx[n]) { err = -ENOMEM ; nctx = n;@@ -1845,7 +1845,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915, } } - err =igt_live_test_begin (&t, i915, __func__, ve[0 ]->engine->name); + err =igt_live_test_begin (&t, gt->i915, __func__, ve[0 ]->engine->name);if (err) goto out;@@ -1892,7 +1892,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915, request[nc]->fence.context, request[nc]->fence.seqno);GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt);break ; } }@@ -1914,7 +1914,7 @@ static int nop_virtual_engine(struct drm_i915_private *i915, prime, div64_u64(ktime_to_ns(times[1]), prime)); out: -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) err = -EIO ;for (nc =0 ; nc < nctx; nc++) {@@ -1927,19 +1927,18 @@ static int nop_virtual_engine(struct drm_i915_private *i915,static int live_virtual_engine (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ];struct intel_engine_cs *engine; -struct intel_gt *gt = &i915->gt;enum intel_engine_id id;
drivers/gpu/drm/i915/gt/selftest_lrc.c static int nop_virtual_engine(struct drm_i915_private *i915, · line 1940
Quoted 10 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +2
-3unsigned int class, inst;int err; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ; -for_each_engine (engine, i915, id) { - err =nop_virtual_engine (i915, &engine,1 ,1 ,0 ); +for_each_engine (engine, gt->i915, id) {
^^^
Quoted 163 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +19
-20+ err =nop_virtual_engine (gt, &engine,1 ,1 ,0 );if (err) {pr_err ("Failed to wrap engine %s: err=%d\n" , engine->name, err);@@ -1961,13 +1960,13 @@ static int live_virtual_engine(void *arg)continue ;for (n =1 ; n <= nsibling +1 ; n++) { - err =nop_virtual_engine (i915, siblings, nsibling, + err =nop_virtual_engine (gt, siblings, nsibling, n,0 );if (err)return err; } - err =nop_virtual_engine (i915, siblings, nsibling, n,CHAIN ); + err =nop_virtual_engine (gt, siblings, nsibling, n,CHAIN );if (err)return err; }@@ -1975,7 +1974,7 @@ static int live_virtual_engine(void *arg)return 0 ; } -static int mask_virtual_engine (struct drm_i915_private *i915, +static int mask_virtual_engine (struct intel_gt *gt,struct intel_engine_cs **siblings,unsigned int nsibling) {@@ -1991,7 +1990,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915,* restrict it to our desired engine within the virtual engine. */ - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx)return -ENOMEM ;@@ -2005,7 +2004,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915,if (err) goto out_put; - err =igt_live_test_begin (&t, i915, __func__, ve->engine->name); + err =igt_live_test_begin (&t, gt->i915, __func__, ve->engine->name);if (err) goto out_unpin;@@ -2036,7 +2035,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915, request[n]->fence.context, request[n]->fence.seqno);GEM_TRACE_DUMP (); -intel_gt_set_wedged (&i915->gt); +intel_gt_set_wedged (gt); err = -EIO ; goto out; }@@ -2052,7 +2051,7 @@ static int mask_virtual_engine(struct drm_i915_private *i915, err =igt_live_test_end (&t); out: -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) err = -EIO ;for (n =0 ; n < nsibling; n++)@@ -2069,13 +2068,12 @@ static int mask_virtual_engine(struct drm_i915_private *i915,static int live_virtual_mask (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ]; -struct intel_gt *gt = &i915->gt;unsigned int class, inst;int err; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;for (class =0 ; class <=MAX_ENGINE_CLASS ; class++) {@@ -2091,7 +2089,7 @@ static int live_virtual_mask(void *arg)if (nsibling <2 )continue ; - err =mask_virtual_engine (i915, siblings, nsibling); + err =mask_virtual_engine (gt, siblings, nsibling);if (err)return err; }@@ -2099,7 +2097,7 @@ static int live_virtual_mask(void *arg)return 0 ; } -static int preserved_virtual_engine (struct drm_i915_private *i915, +static int preserved_virtual_engine (struct intel_gt *gt,struct intel_engine_cs **siblings,unsigned int nsibling) {@@ -2112,7 +2110,7 @@ static int preserved_virtual_engine(struct drm_i915_private *i915,int err =0 ;u32 *cs; - ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx)return -ENOMEM ;@@ -2132,7 +2130,7 @@ static int preserved_virtual_engine(struct drm_i915_private *i915,if (err) goto out_put; - err =igt_live_test_begin (&t, i915, __func__, ve->engine->name); + err =igt_live_test_begin (&t, gt->i915, __func__, ve->engine->name);if (err) goto out_unpin;@@ -2212,9 +2210,8 @@ static int preserved_virtual_engine(struct drm_i915_private *i915,static int live_virtual_preserved (void *arg) { -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ]; -struct intel_gt *gt = &i915->gt;unsigned int class, inst;/* @@ -2223,11 +2220,11 @@ static int live_virtual_preserved(void *arg)* are preserved. */ -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;/* As we use CS_GPR we cannot run before they existed on all engines. */ -if (INTEL_GEN (i915) <9 ) +if (INTEL_GEN (gt->i915) <9 )return 0 ;for (class =0 ; class <=MAX_ENGINE_CLASS ; class++) {@@ -2243,7 +2240,7 @@ static int live_virtual_preserved(void *arg)if (nsibling <2 )continue ; - err =preserved_virtual_engine (i915, siblings, nsibling); + err =preserved_virtual_engine (gt, siblings, nsibling);if (err)return err; }@@ -2251,7 +2248,7 @@ static int live_virtual_preserved(void *arg)return 0 ; } -static int bond_virtual_engine(struct drm_i915_private *i915, +static int bond_virtual_engine(struct intel_gt *gt, unsigned int class, struct intel_engine_cs **siblings, unsigned int nsibling,@@ -2267,13 +2264,13 @@ static int bond_virtual_engine(struct drm_i915_private *i915,GEM_BUG_ON (nsibling >=ARRAY_SIZE (rq) -1 );
drivers/gpu/drm/i915/gt/selftest_lrc.c static int bond_virtual_engine(struct drm_i915_private *i915, · line 2273
Quoted 10 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +2
-2- ctx =kernel_context (i915); + ctx =kernel_context (gt->i915);if (!ctx)return -ENOMEM ; err =0 ; rq[0 ] =ERR_PTR (-ENOMEM ); -for_each_engine (master, i915, id) { +for_each_engine (master, gt->i915, id) {
^^^
Quoted 39 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +4
-5struct i915_sw_fence fence = {};if (master->class == class)@@ -2378,7 +2375,7 @@ static int bond_virtual_engine(struct drm_i915_private *i915, out:for (n =0 ; !IS_ERR (rq[n]); n++)i915_request_put (rq[n]); -if (igt_flush_test (i915)) +if (igt_flush_test (gt->i915)) err = -EIO ;kernel_context_close (ctx);@@ -2395,13 +2392,12 @@ static int live_virtual_bond(void *arg) { "schedule", BOND_SCHEDULE }, { }, }; -struct drm_i915_private *i915 = arg; +struct intel_gt *gt = arg;struct intel_engine_cs *siblings[MAX_ENGINE_INSTANCE +1 ]; -struct intel_gt *gt = &i915->gt;unsigned int class, inst;int err; -if (USES_GUC_SUBMISSION (i915)) +if (USES_GUC_SUBMISSION (gt->i915))return 0 ;for (class =0 ; class <=MAX_ENGINE_CLASS ; class++) {@@ -2420,7 +2416,7 @@ static int live_virtual_bond(void *arg)continue ;for (p = phases; p->name; p++) { - err =bond_virtual_engine (i915, + err =bond_virtual_engine (gt, class, siblings, nsibling, p->flags);if (err) {
drivers/gpu/drm/i915/gt/selftest_lrc.c int intel_execlists_live_selftests(struct drm_i915_private *i915) · line 2464
Quoted 8 lines
drivers/gpu/drm/i915/gt/selftest_lrc.c +1
-1@@ -2462,7 +2458,7 @@ int intel_execlists_live_selftests(struct drm_i915_private *i915)if (intel_gt_is_wedged (&i915->gt))return 0 ; -return i915_live_subtests (tests, i915); +return intel_gt_live_subtests (tests, &i915->gt); }static void hexdump (const void *buf,size_t len)
Not sure if my markers are at all useful, but same condition as previous patches:
Regards,
Tvrtko
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoting Tvrtko Ursulin (2019-10-16 13:50:22)
Quoted 4 lines · Chris Wilson
Not sure if my markers are at all useful, but same condition as previous patches:
I have been leaving gt->i915 as markers for what APIs need to be cleaned up. for_each_engine() is one where I thought a sweep through changing all in one go would be a really nice grand finale, taking a couple of passes through the remaining for_each_engine(i915) to work out if it was meant to be gt-centric, uabi, or context.
-Chris
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 11 lines · Chris Wilson
Quoting Tvrtko Ursulin (2019-10-16 13:50:22)
Quoted 4 lines · Chris Wilson
Not sure if my markers are at all useful, but same condition as previous patches:
I have been leaving
gt->i915as markers for what APIs need to be cleaned up.for_each_engine()is one where I thought a sweep through changing all in one go would be a really nice grand finale, taking a couple of passes through the remainingfor_each_engine(i915)to work out if it was meant to be gt-centric, uabi, or context.
It can be done like that sure, I'll then hold off with my 3/3 patch and update it after you put these ones in. Can have those r-b's in other words as is.
Regards,
Tvrtko
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Patchwork
CI✓ Fi.CI.BAT: success for drm/i915/selftests: Teach execlists to take intel_gt as its argument (rev2)
In reply to Chris Wilson== Series Details ==
== Series Details ==
Series: drm/i915/selftests: Teach execlists to take intel_gt as its argument (rev2)
URL : https://patchwork.freedesktop.org/series/68087/
State : success
== Summary ==
CI Bug Log - changes from CI_DRM_7108 -> Patchwork_14835
====================================================
Summary
-------
**SUCCESS**
No regressions found.
External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/index.html
Possible new issues
-------------------
Here are the unknown changes that may have been introduced in Patchwork_14835:
### IGT changes ###
#### Suppressed ####
The following results come from untrusted machines, tests, or statuses. They do not affect the overall result.
* igt@i915_selftest@live_execlists:
- {fi-icl-guc}: [PASS][1] -> [DMESG-FAIL][2]
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/fi-icl-guc/igt@i915_selftest@live_execlists.html
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/fi-icl-guc/igt@i915_selftest@live_execlists.html
- {fi-icl-u4}: [PASS][3] -> [DMESG-FAIL][4]
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/fi-icl-u4/igt@i915_selftest@live_execlists.html
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/fi-icl-u4/igt@i915_selftest@live_execlists.html
Known issues
------------
Here are the changes found in Patchwork_14835 that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@gem_mmap_gtt@basic-read-write-distinct:
- fi-icl-u3: [PASS][5] -> [DMESG-WARN][6] ([fdo#107724]) +1 similar issue
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/fi-icl-u3/igt@[email protected]
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/fi-icl-u3/igt@[email protected]
* igt@kms_chamelium@hdmi-hpd-fast:
- fi-icl-u2: [PASS][7] -> [FAIL][8] ([fdo#109483])
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/fi-icl-u2/igt@[email protected]
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/fi-icl-u2/igt@[email protected]
- fi-kbl-7500u: [PASS][9] -> [FAIL][10] ([fdo#111045] / [fdo#111096])
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/fi-kbl-7500u/igt@[email protected]
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/fi-kbl-7500u/igt@[email protected]
#### Possible fixes ####
* igt@gem_linear_blits@basic:
- fi-icl-u3: [DMESG-WARN][11] ([fdo#107724]) -> [PASS][12] +1 similar issue
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/fi-icl-u3/igt@[email protected]
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/fi-icl-u3/igt@[email protected]
* igt@i915_selftest@live_execlists:
- fi-skl-6260u: [DMESG-FAIL][13] -> [PASS][14]
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/fi-skl-6260u/igt@i915_selftest@live_execlists.html
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/fi-skl-6260u/igt@i915_selftest@live_execlists.html
- fi-cfl-8109u: [DMESG-FAIL][15] -> [PASS][16]
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/fi-cfl-8109u/igt@i915_selftest@live_execlists.html
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/fi-cfl-8109u/igt@i915_selftest@live_execlists.html
{name}: This element is suppressed. This means it is ignored when computing
the status of the difference (SUCCESS, WARNING, or FAILURE).
[fdo#106107]: https://bugs.freedesktop.org/show_bug.cgi?id=106107
[fdo#107724]: https://bugs.freedesktop.org/show_bug.cgi?id=107724
[fdo#109483]: https://bugs.freedesktop.org/show_bug.cgi?id=109483
[fdo#111045]: https://bugs.freedesktop.org/show_bug.cgi?id=111045
[fdo#111096]: https://bugs.freedesktop.org/show_bug.cgi?id=111096
Participating hosts (53 -> 46)
------------------------------
Missing (7): fi-ilk-m540 fi-hsw-4200u fi-byt-squawks fi-bsw-cyan fi-icl-y fi-byt-clapper fi-bdw-samus
Build changes
-------------
* CI: CI-20190529 -> None
* Linux: CI_DRM_7108 -> Patchwork_14835
CI-20190529: 20190529
CI_DRM_7108: 6087ca54af37aeb0b24ce9533a885194d9cc2be7 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_5231: e293051f8f99c72cb01d21e4b73a5928ea351eb3 @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_14835: b9ae9f250909c406da6cd3e5353b3c78861d351e @ git://anongit.freedesktop.org/gfx-ci/linux
== Linux commits ==
b9ae9f250909 drm/i915/selftests: Teach execlists to take intel_gt as its argument
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/index.html
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Patchwork
CI✓ Fi.CI.IGT: success for drm/i915/selftests: Teach execlists to take intel_gt as its argument (rev2)
In reply to Chris Wilson== Series Details ==
== Series Details ==
Series: drm/i915/selftests: Teach execlists to take intel_gt as its argument (rev2)
URL : https://patchwork.freedesktop.org/series/68087/
State : success
== Summary ==
CI Bug Log - changes from CI_DRM_7108_full -> Patchwork_14835_full
====================================================
Summary
-------
**SUCCESS**
No regressions found.
Possible new issues
-------------------
Here are the unknown changes that may have been introduced in Patchwork_14835_full:
### IGT changes ###
#### Suppressed ####
The following results come from untrusted machines, tests, or statuses. They do not affect the overall result.
* igt@gem_linear_blits@interruptible:
- {shard-tglb}: [PASS][1] -> [INCOMPLETE][2]
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-tglb5/igt@[email protected]
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-tglb1/igt@[email protected]
* {igt@kms_cursor_crc@pipe-d-cursor-256x256-random}:
- {shard-tglb}: NOTRUN -> [FAIL][3]
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-tglb6/igt@[email protected]
* igt@kms_universal_plane@disable-primary-vs-flip-pipe-e:
- {shard-tglb}: NOTRUN -> [SKIP][4] +2 similar issues
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-tglb3/igt@[email protected]
Known issues
------------
Here are the changes found in Patchwork_14835_full that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@gem_ctx_switch@vcs0-heavy-queue:
- shard-apl: [PASS][5] -> [INCOMPLETE][6] ([fdo#103927]) +1 similar issue
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-apl3/igt@[email protected]
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-apl8/igt@[email protected]
* igt@gem_exec_schedule@preempt-contexts-bsd2:
- shard-iclb: [PASS][7] -> [SKIP][8] ([fdo#109276]) +25 similar issues
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb2/igt@[email protected]
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb6/igt@[email protected]
* igt@gem_exec_schedule@preemptive-hang-bsd:
- shard-iclb: [PASS][9] -> [SKIP][10] ([fdo#111325]) +5 similar issues
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb3/igt@[email protected]
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb1/igt@[email protected]
* igt@gem_userptr_blits@sync-unmap-after-close:
- shard-hsw: [PASS][11] -> [DMESG-WARN][12] ([fdo#111870]) +1 similar issue
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-hsw5/igt@[email protected]
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-hsw5/igt@[email protected]
* igt@kms_flip@2x-flip-vs-expired-vblank:
- shard-glk: [PASS][13] -> [FAIL][14] ([fdo#105363])
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-glk6/igt@[email protected]
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-glk7/igt@[email protected]
* igt@kms_flip@dpms-vs-vblank-race-interruptible:
- shard-glk: [PASS][15] -> [FAIL][16] ([fdo#111609])
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-glk5/igt@[email protected]
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-glk9/igt@[email protected]
* igt@kms_flip@flip-vs-suspend-interruptible:
- shard-skl: [PASS][17] -> [INCOMPLETE][18] ([fdo#109507])
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-skl4/igt@[email protected]
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-skl4/igt@[email protected]
* igt@kms_frontbuffer_tracking@fbc-1p-offscren-pri-indfb-draw-render:
- shard-iclb: [PASS][19] -> [FAIL][20] ([fdo#103167]) +4 similar issues
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb5/igt@kms_frontbuffer_tracking@fbc-1p-offscren-pri-indfb-draw-render.html
[20]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb2/igt@kms_frontbuffer_tracking@fbc-1p-offscren-pri-indfb-draw-render.html
* igt@kms_frontbuffer_tracking@fbc-suspend:
- shard-apl: [PASS][21] -> [DMESG-WARN][22] ([fdo#108566]) +3 similar issues
[21]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-apl1/igt@[email protected]
[22]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-apl3/igt@[email protected]
* igt@kms_frontbuffer_tracking@fbcpsr-1p-primscrn-spr-indfb-draw-mmap-wc:
- shard-iclb: [PASS][23] -> [INCOMPLETE][24] ([fdo#106978] / [fdo#107713])
[23]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb8/igt@kms_frontbuffer_tracking@fbcpsr-1p-primscrn-spr-indfb-draw-mmap-wc.html
[24]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb7/igt@kms_frontbuffer_tracking@fbcpsr-1p-primscrn-spr-indfb-draw-mmap-wc.html
* igt@kms_plane_alpha_blend@pipe-c-constant-alpha-min:
- shard-skl: [PASS][25] -> [FAIL][26] ([fdo#108145]) +1 similar issue
[25]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-skl2/igt@[email protected]
[26]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-skl1/igt@[email protected]
* igt@kms_psr@psr2_basic:
- shard-iclb: [PASS][27] -> [SKIP][28] ([fdo#109441]) +2 similar issues
[27]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb2/igt@kms_psr@psr2_basic.html
[28]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb5/igt@kms_psr@psr2_basic.html
* igt@kms_setmode@basic:
- shard-skl: [PASS][29] -> [FAIL][30] ([fdo#99912])
[29]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-skl2/igt@[email protected]
[30]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-skl1/igt@[email protected]
- shard-glk: [PASS][31] -> [FAIL][32] ([fdo#99912])
[31]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-glk2/igt@[email protected]
[32]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-glk4/igt@[email protected]
#### Possible fixes ####
* igt@gem_ctx_isolation@bcs0-s3:
- shard-apl: [DMESG-WARN][33] ([fdo#108566]) -> [PASS][34] +3 similar issues
[33]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-apl7/igt@[email protected]
[34]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-apl3/igt@[email protected]
* igt@gem_exec_schedule@reorder-wide-bsd:
- shard-iclb: [SKIP][35] ([fdo#111325]) -> [PASS][36] +8 similar issues
[35]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb4/igt@[email protected]
[36]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb6/igt@[email protected]
* igt@gem_exec_schedule@smoketest-all:
- {shard-tglb}: [INCOMPLETE][37] ([fdo#111855]) -> [PASS][38]
[37]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-tglb6/igt@[email protected]
[38]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-tglb1/igt@[email protected]
* igt@gem_userptr_blits@map-fixed-invalidate-busy:
- shard-snb: [DMESG-WARN][39] ([fdo#111870]) -> [PASS][40] +1 similar issue
[39]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-snb4/igt@[email protected]
[40]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-snb1/igt@[email protected]
* igt@gem_userptr_blits@map-fixed-invalidate-busy-gup:
- shard-hsw: [DMESG-WARN][41] ([fdo#111870]) -> [PASS][42]
[41]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-hsw4/igt@[email protected]
[42]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-hsw4/igt@[email protected]
* {igt@gem_userptr_blits@stress-purge}:
- shard-apl: [INCOMPLETE][43] ([fdo#103927]) -> [PASS][44]
[43]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-apl1/igt@[email protected]
[44]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-apl8/igt@[email protected]
* igt@kms_cursor_crc@pipe-b-cursor-128x42-sliding:
- shard-kbl: [FAIL][45] ([fdo#103232]) -> [PASS][46]
[45]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-kbl4/igt@[email protected]
[46]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-kbl7/igt@[email protected]
* igt@kms_frontbuffer_tracking@fbc-badstride:
- shard-iclb: [FAIL][47] ([fdo#103167]) -> [PASS][48] +3 similar issues
[47]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb6/igt@[email protected]
[48]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb2/igt@[email protected]
* igt@kms_frontbuffer_tracking@psr-1p-offscren-pri-indfb-draw-render:
- shard-iclb: [INCOMPLETE][49] ([fdo#106978] / [fdo#107713]) -> [PASS][50]
[49]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb7/igt@kms_frontbuffer_tracking@psr-1p-offscren-pri-indfb-draw-render.html
[50]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb2/igt@kms_frontbuffer_tracking@psr-1p-offscren-pri-indfb-draw-render.html
* igt@kms_pipe_crc_basic@suspend-read-crc-pipe-a:
- shard-kbl: [INCOMPLETE][51] ([fdo#103665]) -> [PASS][52]
[51]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-kbl2/igt@[email protected]
[52]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-kbl2/igt@[email protected]
* igt@kms_plane@plane-panning-bottom-right-suspend-pipe-b-planes:
- shard-skl: [INCOMPLETE][53] ([fdo#104108]) -> [PASS][54]
[53]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-skl4/igt@[email protected]
[54]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-skl2/igt@[email protected]
* igt@kms_psr@psr2_cursor_mmap_cpu:
- shard-iclb: [SKIP][55] ([fdo#109441]) -> [PASS][56] +1 similar issue
[55]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb5/igt@kms_psr@psr2_cursor_mmap_cpu.html
[56]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb2/igt@kms_psr@psr2_cursor_mmap_cpu.html
* igt@kms_vblank@pipe-b-ts-continuation-dpms-suspend:
- shard-iclb: [INCOMPLETE][57] ([fdo#107713]) -> [PASS][58]
[57]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb3/igt@[email protected]
[58]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb7/igt@[email protected]
* igt@prime_busy@after-bsd2:
- shard-iclb: [SKIP][59] ([fdo#109276]) -> [PASS][60] +18 similar issues
[59]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb5/igt@[email protected]
[60]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb2/igt@[email protected]
* igt@tools_test@tools_test:
- shard-snb: [SKIP][61] ([fdo#109271]) -> [PASS][62]
[61]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-snb2/igt@tools_test@tools_test.html
[62]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-snb5/igt@tools_test@tools_test.html
#### Warnings ####
* igt@gem_mocs_settings@mocs-reset-bsd2:
- shard-iclb: [FAIL][63] ([fdo#111330]) -> [SKIP][64] ([fdo#109276])
[63]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb4/igt@[email protected]
[64]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb8/igt@[email protected]
* igt@gem_mocs_settings@mocs-settings-bsd2:
- shard-iclb: [SKIP][65] ([fdo#109276]) -> [FAIL][66] ([fdo#111330]) +1 similar issue
[65]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb3/igt@[email protected]
[66]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb4/igt@[email protected]
* igt@kms_content_protection@srm:
- shard-apl: [INCOMPLETE][67] ([fdo#103927]) -> [FAIL][68] ([fdo#110321])
[67]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-apl6/igt@[email protected]
[68]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-apl3/igt@[email protected]
* igt@kms_dp_dsc@basic-dsc-enable-edp:
- shard-iclb: [SKIP][69] ([fdo#109349]) -> [DMESG-WARN][70] ([fdo#107724])
[69]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_7108/shard-iclb5/igt@[email protected]
[70]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/shard-iclb2/igt@[email protected]
{name}: This element is suppressed. This means it is ignored when computing
the status of the difference (SUCCESS, WARNING, or FAILURE).
[fdo#103167]: https://bugs.freedesktop.org/show_bug.cgi?id=103167
[fdo#103232]: https://bugs.freedesktop.org/show_bug.cgi?id=103232
[fdo#103665]: https://bugs.freedesktop.org/show_bug.cgi?id=103665
[fdo#103927]: https://bugs.freedesktop.org/show_bug.cgi?id=103927
[fdo#104108]: https://bugs.freedesktop.org/show_bug.cgi?id=104108
[fdo#105363]: https://bugs.freedesktop.org/show_bug.cgi?id=105363
[fdo#106978]: https://bugs.freedesktop.org/show_bug.cgi?id=106978
[fdo#107713]: https://bugs.freedesktop.org/show_bug.cgi?id=107713
[fdo#107724]: https://bugs.freedesktop.org/show_bug.cgi?id=107724
[fdo#108145]: https://bugs.freedesktop.org/show_bug.cgi?id=108145
[fdo#108566]: https://bugs.freedesktop.org/show_bug.cgi?id=108566
[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#109276]: https://bugs.freedesktop.org/show_bug.cgi?id=109276
[fdo#109349]: https://bugs.freedesktop.org/show_bug.cgi?id=109349
[fdo#109441]: https://bugs.freedesktop.org/show_bug.cgi?id=109441
[fdo#109507]: https://bugs.freedesktop.org/show_bug.cgi?id=109507
[fdo#110321]: https://bugs.freedesktop.org/show_bug.cgi?id=110321
[fdo#110548]: https://bugs.freedesktop.org/show_bug.cgi?id=110548
[fdo#111325]: https://bugs.freedesktop.org/show_bug.cgi?id=111325
[fdo#111330]: https://bugs.freedesktop.org/show_bug.cgi?id=111330
[fdo#111609]: https://bugs.freedesktop.org/show_bug.cgi?id=111609
[fdo#111855]: https://bugs.freedesktop.org/show_bug.cgi?id=111855
[fdo#111870]: https://bugs.freedesktop.org/show_bug.cgi?id=111870
[fdo#99912]: https://bugs.freedesktop.org/show_bug.cgi?id=99912
Participating hosts (11 -> 11)
------------------------------
No changes in participating hosts
Build changes
-------------
* CI: CI-20190529 -> None
* Linux: CI_DRM_7108 -> Patchwork_14835
CI-20190529: 20190529
CI_DRM_7108: 6087ca54af37aeb0b24ce9533a885194d9cc2be7 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_5231: e293051f8f99c72cb01d21e4b73a5928ea351eb3 @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_14835: b9ae9f250909c406da6cd3e5353b3c78861d351e @ git://anongit.freedesktop.org/gfx-ci/linux
piglit_4509: fdc5a4ca11124ab8413c7988896eec4c97336694 @ git://anongit.freedesktop.org/piglit
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_14835/index.html
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx