lkml.org 
[lkml]   [2008]   [Mar]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] x86: create array based interface to change page attribute
From
Date
Dave Airlie <airlied@redhat.com> writes:
>
> +#define CPA_FLUSHTLB 1
> +#define CPA_ARRAY 2

I don't think CPA_ARRAY should be a separate case. Rather single
page flushing should be an array with only a single entry. pageattr
is already very complex, no need to make add more special cases.
> +
> + /*
> + * Only flush present addresses:
> + */
> + if (pte && (pte_val(*pte) & _PAGE_PRESENT))
> + clflush_cache_range((void *) *addr, PAGE_SIZE);

Also it is doubtful clflush really makes sense on a large array. Just
doing wbinvd might be faster then. Or perhaps better supporting Self-Snoop
should be revisited, that would at least eliminate it on most Intel
CPUs.

-Andi


\
 
 \ /
  Last update: 2008-03-31 09:27    [W:0.145 / U:0.744 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site