Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp1008424ybe; Fri, 13 Sep 2019 09:38:26 -0700 (PDT) X-Google-Smtp-Source: APXvYqz3wbZXtQEI0gLJ9fP7d87ja9jPGQNp7a+eOySpgzYMCn4u3AHIqHYAHskrdrkz8+8+9CMb X-Received: by 2002:a50:eac5:: with SMTP id u5mr44014962edp.207.1568392706004; Fri, 13 Sep 2019 09:38:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568392705; cv=none; d=google.com; s=arc-20160816; b=LsVdo5dXn4WuBO14gStAFmjSemOzlBYpfhcnRdaQIDnIE2eKsGTtttVH3n5BKq9fB4 nwp5F9EpP33Bup96GbFTZROhTqSfAqON8aZ8mYvOKV1tcnD65saUQKnSFU7k0bz0tqTw 3Rglf7v4zWPOLUhYuEJLuZnuF6PYZrXHn7R6pKD/cej4TgdUFOvbVjJGYP5p2Xi3ksqZ yeRGNy+HSqEZTqursfPlIxSQxXC7iWjXBMD8atzEKR5oegDSSvum+KJztXHwGk0kWZ2h 1AGEj1MkQl+YPYwDe1ZUxu2eyywfi97JOJlr7/ta9ajj29fK5LODbU531GMeVbGNh/rh DZZw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=7FywJW6zdfAuPQkfyRcdHAqkPJ0E674N3dTzE8dArg8=; b=doRtFKEWA8GKiVnBNBDrs1tCl976RYL1ngQJFGJQY7yQKl+1ShvDQs1Z1Rtol475Io lojkYb7W/lY95uXzkcQrfdlQW1vyPxhInxMsC6hkoJnle/PctC6y5tNHTgaaJZGs4VGO NrEesqPKVyNvVuE6HosIG4jOhFkQErZilXrpPx+wQxuAB+BvQzBk1R5z32+VbqDw8u1P ydbXDb2fkiRXNKbUozhbPz1hRfaNb7KpZta+4Xqa+1MLzS3tm9rMqa54i+isVZHCQK65 ybAC6nYF3/15oGjjhikINLaAf0gJbQ8oUQSVn+ByojQ54pDaLTbeJl167mwplKP0phHA AveQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=hpe.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id oq3si1816833ejb.220.2019.09.13.09.38.02; Fri, 13 Sep 2019 09:38:25 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=hpe.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2403881AbfIMPPD (ORCPT + 99 others); Fri, 13 Sep 2019 11:15:03 -0400 Received: from mx0b-002e3701.pphosted.com ([148.163.143.35]:20160 "EHLO mx0b-002e3701.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2403864AbfIMPPD (ORCPT ); Fri, 13 Sep 2019 11:15:03 -0400 Received: from pps.filterd (m0134425.ppops.net [127.0.0.1]) by mx0b-002e3701.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id x8DF6YSB028924; Fri, 13 Sep 2019 15:14:18 GMT Received: from g4t3426.houston.hpe.com (g4t3426.houston.hpe.com [15.241.140.75]) by mx0b-002e3701.pphosted.com with ESMTP id 2uyteddhe1-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 13 Sep 2019 15:14:18 +0000 Received: from g4t3433.houston.hpecorp.net (g4t3433.houston.hpecorp.net [16.208.49.245]) by g4t3426.houston.hpe.com (Postfix) with ESMTP id 916FD61; Fri, 13 Sep 2019 15:14:17 +0000 (UTC) Received: from swahl-linux (swahl-linux.americas.hpqcorp.net [10.33.153.21]) by g4t3433.houston.hpecorp.net (Postfix) with ESMTP id 3E90E46; Fri, 13 Sep 2019 15:14:16 +0000 (UTC) Date: Fri, 13 Sep 2019 10:14:15 -0500 From: Steve Wahl To: "Kirill A. Shutemov" Cc: Steve Wahl , Thomas Gleixner , Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , x86@kernel.org, Juergen Gross , Brijesh Singh , Jordan Borgner , Feng Tang , linux-kernel@vger.kernel.org, Baoquan He , russ.anderson@hpe.com, dimitri.sivanich@hpe.com, mike.travis@hpe.com Subject: Re: [PATCH] x86/boot/64: Make level2_kernel_pgt pages invalid outside kernel area. Message-ID: <20190913151415.GG7834@swahl-linux> References: <20190906212950.GA7792@swahl-linux> <20190909081414.5e3q47fzzruesscx@box> <20190910142810.GA7834@swahl-linux> <20190911002856.mx44pmswcjfpfjsb@box.shutemov.name> <20190911200835.GD7834@swahl-linux> <20190912101917.mbobjvkxhfttxddd@box> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190912101917.mbobjvkxhfttxddd@box> User-Agent: Mutt/1.12.1 (2019-06-15) X-HPE-SCL: -1 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.70,1.0.8 definitions=2019-09-13_07:2019-09-11,2019-09-13 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 clxscore=1015 malwarescore=0 mlxlogscore=999 phishscore=0 bulkscore=0 adultscore=0 suspectscore=0 mlxscore=0 lowpriorityscore=0 priorityscore=1501 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-1908290000 definitions=main-1909130152 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Sep 12, 2019 at 01:19:17PM +0300, Kirill A. Shutemov wrote: > On Wed, Sep 11, 2019 at 03:08:35PM -0500, Steve Wahl wrote: > > Thank you for your time looking into this with me! > > With all this explanation the original patch looks sane to me. > > But I would like to see more information from this thread in the commit > message and some comments in the code on why it's crucial not to map more > than needed. I am working on this. > I think we also need to make it clear that this is workaround for a broken > hardware: speculative execution must not trigger a halt. I think the word broken is a bit loaded here. According to the UEFI spec (version 2.8, page 167), "Regions that are backed by the physical hardware, but are not supposed to be accessed by the OS, must be returned as EfiReservedMemoryType." Our interpretation is that includes speculative accesses. I'd lean more toward "tightening of adherence to the spec required by some particular hardware." Does that work for you? --> Steve Wahl -- Steve Wahl, Hewlett Packard Enterprise