From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933423AbcFOU0x (ORCPT ); Wed, 15 Jun 2016 16:26:53 -0400 Received: from mail-pa0-f68.google.com ([209.85.220.68]:34112 "EHLO mail-pa0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932235AbcFOU0u convert rfc822-to-8bit (ORCPT ); Wed, 15 Jun 2016 16:26:50 -0400 Content-Type: text/plain; charset=windows-1252 Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Subject: Re: [PATCH v2] Linux VM workaround for Knights Landing A/D leak From: Nadav Amit In-Reply-To: <5761B630.7020502@linux.intel.com> Date: Wed, 15 Jun 2016 13:26:46 -0700 Cc: "Anaczkowski, Lukasz" , LKML , "linux-mm@kvack.org" , Thomas Gleixner , Ingo Molnar , "ak@linux.intel.com" , "kirill.shutemov@linux.intel.com" , "mhocko@suse.com" , Andrew Morton , "H. Peter Anvin" , "Srinivasappa, Harish" , "Odzioba, Lukasz" , "Andrejczuk, Grzegorz" , "Daniluk, Lukasz" Content-Transfer-Encoding: 8BIT Message-Id: References: <7FB15233-B347-4A87-9506-A9E10D331292@gmail.com> <1465923672-14232-1-git-send-email-lukasz.anaczkowski@intel.com> <76F6D5F2-6723-441B-BD63-52628731F1FF@gmail.com> <613007E2-2A88-4934-9364-A5A66A555305@gmail.com> <5761B630.7020502@linux.intel.com> To: Dave Hansen X-Mailer: Apple Mail (2.3124) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Dave Hansen wrote: > On 06/15/2016 01:04 PM, Nadav Amit wrote: >> Be careful here. According to the SDM when invalidating a huge-page, >> each 4KB page needs to be invalidated separately. In practice, when >> Linux invalidates 2MB/1GB pages it performs a full TLB flush. The >> full flush may not be required on knights landing, and specifically >> for the workaround, but you should check. > > Where do you get that? The SDM says: "they (TLB invalidation operations > invalidate all TLB entries corresponding to the translation specified by > the paging structures.” You are absolutely correct. Last time I write something based on my recollection of the SDM without re-reading again. Sorry. Nadav