Commit 840291a7 authored by Chris Wilson's avatar Chris Wilson

drm/i915/selftests: Tidy prng constructor for client blits

Since we only initialise the prng once within the scope of the selftest,
we can use the default initialiser.
Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
Cc: Matthew Auld <matthew.auld@intel.com>
Reviewed-by: default avatarMatthew Auld <matthew.auld@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20201202130406.18461-1-chris@chris-wilson.co.uk
parent 348fb0cb
...@@ -20,13 +20,11 @@ static int __igt_client_fill(struct intel_engine_cs *engine) ...@@ -20,13 +20,11 @@ static int __igt_client_fill(struct intel_engine_cs *engine)
{ {
struct intel_context *ce = engine->kernel_context; struct intel_context *ce = engine->kernel_context;
struct drm_i915_gem_object *obj; struct drm_i915_gem_object *obj;
struct rnd_state prng; I915_RND_STATE(prng);
IGT_TIMEOUT(end); IGT_TIMEOUT(end);
u32 *vaddr; u32 *vaddr;
int err = 0; int err = 0;
prandom_seed_state(&prng, i915_selftest.random_seed);
intel_engine_pm_get(engine); intel_engine_pm_get(engine);
do { do {
const u32 max_block_size = S16_MAX * PAGE_SIZE; const u32 max_block_size = S16_MAX * PAGE_SIZE;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment