mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2025-01-03 20:34:58 +08:00
drm/i915: Use memset64() to prefill the GTT page
Take advantage of optimised memset64() instead of open coding it to prefill the GTT pages. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Link: https://patchwork.freedesktop.org/patch/msgid/20170926095353.11036-1-chris@chris-wilson.co.uk Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
This commit is contained in:
parent
163e8aecd1
commit
4dd504f7d9
@ -481,10 +481,8 @@ static void fill_page_dma(struct i915_address_space *vm,
|
|||||||
const u64 val)
|
const u64 val)
|
||||||
{
|
{
|
||||||
u64 * const vaddr = kmap_atomic(p->page);
|
u64 * const vaddr = kmap_atomic(p->page);
|
||||||
int i;
|
|
||||||
|
|
||||||
for (i = 0; i < 512; i++)
|
memset64(vaddr, val, PAGE_SIZE / sizeof(val));
|
||||||
vaddr[i] = val;
|
|
||||||
|
|
||||||
kunmap_atomic(vaddr);
|
kunmap_atomic(vaddr);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user