Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3DBD7C433DF for ; Thu, 18 Jun 2020 09:28:19 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 10BDF21974 for ; Thu, 18 Jun 2020 09:28:19 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="XF0bDDU6" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 10BDF21974 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=4Ac0IkU1+NtHrp/pF9+FJC3HWMkevkHCyf8HmCRLYrU=; b=XF0bDDU6cDb/0c 3mmzRTLS7V4BrmAnWNUz3vmlxhIzxXCvQkX08tHO4Qt+WQLh5J9zEj9Ox7YKYS7vRu1hpm59Xc4xL 0anFZq7GCiAe7o98uEI3ESvvp5bntfa4m0BcUEiYJE47ikG9bvsB33TYZrxhABO9Myvb4cZvE24MN 8MUGZGu70UXscjbhLpgy4itpa2btzGij0T+l5p3kInzZPAJEF2oAS8TO0FGi+qihUXdNyf8jD54yh uhdDJBSwskFS248UB5M+xvbOMwY6zlh5TGD3dLb+4mXvhOjLhMkyrzhg9zM+krL3YcGvXcEvkzZFg z93pKoT2ltgKY9Z9P/fQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jlqqI-0004nR-PS; Thu, 18 Jun 2020 09:28:18 +0000 Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=noisy.programming.kicks-ass.net) by bombadil.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1jlqqG-0004my-82; Thu, 18 Jun 2020 09:28:16 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id A822D307A66; Thu, 18 Jun 2020 11:28:14 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 96F692059AC5C; Thu, 18 Jun 2020 11:28:14 +0200 (CEST) Date: Thu, 18 Jun 2020 11:28:14 +0200 From: Peter Zijlstra To: Christoph Hellwig Subject: Re: fix a hyperv W^X violation and remove vmalloc_exec Message-ID: <20200618092814.GG576905@hirez.programming.kicks-ass.net> References: <20200618064307.32739-1-hch@lst.de> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20200618064307.32739-1-hch@lst.de> X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-hyperv@vger.kernel.org, Catalin Marinas , x86@kernel.org, Dexuan Cui , linux-kernel@vger.kernel.org, linux-mm@kvack.org, Jessica Yu , Andrew Morton , Will Deacon , Vitaly Kuznetsov , linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Jun 18, 2020 at 08:43:04AM +0200, Christoph Hellwig wrote: > Hi all, > > Dexuan reported a W^X violation due to the fact that the hyper hypercall > page due switching it to be allocated using vmalloc_exec. The problem > is that PAGE_KERNEL_EXEC as used by vmalloc_exec actually sets writable > permissions in the pte. This series fixes the issue by switching to the > low-level __vmalloc_node_range interface that allows specifing more > detailed permissions instead. It then also open codes the other two > callers and removes the somewhat confusing vmalloc_exec interface. Acked-by: Peter Zijlstra (Intel) > Peter noted that the hyper hypercall page allocation also has another > long standing issue in that it shouldn't use the full vmalloc but just > the module space. This issue is so far theoretical as the allocation is > done early in the boot process. I plan to fix it with another bigger > series for 5.9. Thanks! _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel