Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1424167AbdDUSyQ (ORCPT ); Fri, 21 Apr 2017 14:54:16 -0400 Received: from mga07.intel.com ([134.134.136.100]:39125 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1423946AbdDUSyL (ORCPT ); Fri, 21 Apr 2017 14:54:11 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.37,230,1488873600"; d="scan'208";a="1122217369" Subject: Re: [PATCH v2 2/3] x86/mm: Make flush_tlb_mm_range() more predictable To: Andy Lutomirski , x86@kernel.org References: <438f3c3cd04ff7f2da482626d78ec0fd1f35385b.1492798187.git.luto@kernel.org> Cc: linux-kernel@vger.kernel.org, Borislav Petkov , Rik van Riel , Nadav Amit , Michal Hocko , Sasha Levin , Andrew Morton From: Dave Hansen Message-ID: <56bf2b62-ecae-65ab-0ade-3c659bfd640c@intel.com> Date: Fri, 21 Apr 2017 11:54:06 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 MIME-Version: 1.0 In-Reply-To: <438f3c3cd04ff7f2da482626d78ec0fd1f35385b.1492798187.git.luto@kernel.org> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 754 Lines: 16 On 04/21/2017 11:15 AM, Andy Lutomirski wrote: > I'm about to rewrite the function almost completely, but first I > want to get a functional change out of the way. Currently, if > flush_tlb_mm_range() does not flush the local TLB at all, it will > never do individual page flushes on remote CPUs. This seems to be > an accident, and preserving it will be awkward. Let's change it > first so that any regressions in the rewrite will be easier to > bisect and so that the rewrite can attempt to change no visible > behavior at all. > > The fix is simple: we can simply avoid short-circuiting the > calculation of base_pages_to_flush. This looks sane to me. I think it makes things more straightforward. Acked-by: Dave Hansen