Skip to content

Commit 0a1584e

Browse files
Dr. David Alan GilbertAndi Shyti
authored andcommitted
drm/i915: Remove unused intel_ring_cacheline_align
The last use of intel_ring_cacheline_align() was removed in 2017 by commit afa8ce5 ("drm/i915: Nuke legacy flip queueing code") Remove it. Signed-off-by: Dr. David Alan Gilbert <[email protected]> Signed-off-by: Tvrtko Ursulin <[email protected]> Reviewed-by: Andi Shyti <[email protected]> Signed-off-by: Andi Shyti <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent 64420d2 commit 0a1584e

File tree

2 files changed

+0
-25
lines changed

2 files changed

+0
-25
lines changed

drivers/gpu/drm/i915/gt/intel_ring.c

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -308,30 +308,6 @@ u32 *intel_ring_begin(struct i915_request *rq, unsigned int num_dwords)
308308
return cs;
309309
}
310310

311-
/* Align the ring tail to a cacheline boundary */
312-
int intel_ring_cacheline_align(struct i915_request *rq)
313-
{
314-
int num_dwords;
315-
void *cs;
316-
317-
num_dwords = (rq->ring->emit & (CACHELINE_BYTES - 1)) / sizeof(u32);
318-
if (num_dwords == 0)
319-
return 0;
320-
321-
num_dwords = CACHELINE_DWORDS - num_dwords;
322-
GEM_BUG_ON(num_dwords & 1);
323-
324-
cs = intel_ring_begin(rq, num_dwords);
325-
if (IS_ERR(cs))
326-
return PTR_ERR(cs);
327-
328-
memset64(cs, (u64)MI_NOOP << 32 | MI_NOOP, num_dwords / 2);
329-
intel_ring_advance(rq, cs + num_dwords);
330-
331-
GEM_BUG_ON(rq->ring->emit & (CACHELINE_BYTES - 1));
332-
return 0;
333-
}
334-
335311
#if IS_ENABLED(CONFIG_DRM_I915_SELFTEST)
336312
#include "selftest_ring.c"
337313
#endif

drivers/gpu/drm/i915/gt/intel_ring.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ struct intel_ring *
1616
intel_engine_create_ring(struct intel_engine_cs *engine, int size);
1717

1818
u32 *intel_ring_begin(struct i915_request *rq, unsigned int num_dwords);
19-
int intel_ring_cacheline_align(struct i915_request *rq);
2019

2120
unsigned int intel_ring_update_space(struct intel_ring *ring);
2221

0 commit comments

Comments
 (0)