diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2019-11-07 21:39:29 +0000 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2019-11-08 10:17:41 +0000 |
commit | a8c9a7f52ec5a4b36ce183efd5fda4e4fd90ec45 (patch) | |
tree | debf727251f993185db786505cec57db652f4e96 /drivers/gpu/drm/i915/gt | |
parent | ab11a9270a91c833b9b4e3975443f529d1c7cf17 (diff) |
drm/i915/selftests: Complete transition to a real struct file mock
Since drm provided us with a real struct file we can use for our
anonymous internal clients (mock_file), complete our transition to using
that as the primary interface (and not the mocked up struct drm_file we
previous were using).
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Matthew Auld <matthew.auld@intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20191107213929.23286-1-chris@chris-wilson.co.uk
Diffstat (limited to 'drivers/gpu/drm/i915/gt')
-rw-r--r-- | drivers/gpu/drm/i915/gt/selftest_context.c | 8 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/gt/selftest_hangcheck.c | 16 | ||||
-rw-r--r-- | drivers/gpu/drm/i915/gt/selftest_workarounds.c | 4 |
3 files changed, 14 insertions, 14 deletions
diff --git a/drivers/gpu/drm/i915/gt/selftest_context.c b/drivers/gpu/drm/i915/gt/selftest_context.c index a5688f7d9073..14ba6ceb9177 100644 --- a/drivers/gpu/drm/i915/gt/selftest_context.c +++ b/drivers/gpu/drm/i915/gt/selftest_context.c @@ -289,7 +289,7 @@ static int live_active_context(void *arg) struct intel_engine_cs *engine; struct i915_gem_context *fixme; enum intel_engine_id id; - struct drm_file *file; + struct file *file; int err = 0; file = mock_file(gt->i915); @@ -313,7 +313,7 @@ static int live_active_context(void *arg) } out_file: - mock_file_put(file); + fput(file); return err; } @@ -399,7 +399,7 @@ static int live_remote_context(void *arg) struct intel_engine_cs *engine; struct i915_gem_context *fixme; enum intel_engine_id id; - struct drm_file *file; + struct file *file; int err = 0; file = mock_file(gt->i915); @@ -423,7 +423,7 @@ static int live_remote_context(void *arg) } out_file: - mock_file_put(file); + fput(file); return err; } diff --git a/drivers/gpu/drm/i915/gt/selftest_hangcheck.c b/drivers/gpu/drm/i915/gt/selftest_hangcheck.c index cdaaee4432b2..d155c9374453 100644 --- a/drivers/gpu/drm/i915/gt/selftest_hangcheck.c +++ b/drivers/gpu/drm/i915/gt/selftest_hangcheck.c @@ -380,8 +380,8 @@ static int igt_reset_nop(void *arg) struct i915_gem_context *ctx; unsigned int reset_count, count; enum intel_engine_id id; - struct drm_file *file; IGT_TIMEOUT(end_time); + struct file *file; int err = 0; /* Check that we can reset during non-user portions of requests */ @@ -439,7 +439,7 @@ static int igt_reset_nop(void *arg) err = igt_flush_test(gt->i915); out: - mock_file_put(file); + fput(file); if (intel_gt_is_wedged(gt)) err = -EIO; return err; @@ -452,7 +452,7 @@ static int igt_reset_nop_engine(void *arg) struct intel_engine_cs *engine; struct i915_gem_context *ctx; enum intel_engine_id id; - struct drm_file *file; + struct file *file; int err = 0; /* Check that we can engine-reset during non-user portions */ @@ -535,7 +535,7 @@ static int igt_reset_nop_engine(void *arg) err = igt_flush_test(gt->i915); out: - mock_file_put(file); + fput(file); if (intel_gt_is_wedged(gt)) err = -EIO; return err; @@ -700,8 +700,8 @@ static int active_engine(void *data) struct intel_engine_cs *engine = arg->engine; struct i915_request *rq[8] = {}; struct i915_gem_context *ctx[ARRAY_SIZE(rq)]; - struct drm_file *file; unsigned long count = 0; + struct file *file; int err = 0; file = mock_file(engine->i915); @@ -752,7 +752,7 @@ static int active_engine(void *data) } err_file: - mock_file_put(file); + fput(file); return err; } @@ -1302,7 +1302,7 @@ static int igt_reset_evict_ppgtt(void *arg) struct intel_gt *gt = arg; struct i915_gem_context *ctx; struct i915_address_space *vm; - struct drm_file *file; + struct file *file; int err; file = mock_file(gt->i915); @@ -1325,7 +1325,7 @@ static int igt_reset_evict_ppgtt(void *arg) i915_vm_put(vm); out: - mock_file_put(file); + fput(file); return err; } diff --git a/drivers/gpu/drm/i915/gt/selftest_workarounds.c b/drivers/gpu/drm/i915/gt/selftest_workarounds.c index 5c69ec5c5ef9..d5d1e1a32187 100644 --- a/drivers/gpu/drm/i915/gt/selftest_workarounds.c +++ b/drivers/gpu/drm/i915/gt/selftest_workarounds.c @@ -711,7 +711,7 @@ static int live_dirty_whitelist(void *arg) struct intel_engine_cs *engine; struct i915_gem_context *ctx; enum intel_engine_id id; - struct drm_file *file; + struct file *file; int err = 0; /* Can the user write to the whitelisted registers? */ @@ -739,7 +739,7 @@ static int live_dirty_whitelist(void *arg) } out_file: - mock_file_put(file); + fput(file); return err; } |