Re: Excessive TLB flush ranges

Thomas Gleixner
2023-05-16T08:44:12Z

On Tue, May 16 2023 at 09:19, Russell King wrote:
> On Tue, May 16, 2023 at 08:37:18AM +0200, Thomas Gleixner wrote:
>> void flush_tlb_kernel_vas(struct list_head *list, unsigned int num_entries):
>>
>> So that an architecture can decide whether it's worth to do walk the
>> entries or whether it resorts to a flush all.
>
> Is "num_entries" what an arch would want to use? How would it use that?
> It doesn't tell an arch whether there is a large range of many list
> entries, or a single entry covering a large range.

Does it matter?

The total number of entries to flush is what accumulates and at some
architecture specific threshold that becomes more expensive than a full
flush, independent of the range of the individual list entries, no?

Thanks,

tglx