From mboxrd@z Thu Jan 1 00:00:00 1970 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=-5.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 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 60A48C4320E for ; Thu, 26 Aug 2021 05:37:26 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 90A25610C7 for ; Thu, 26 Aug 2021 05:37:25 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 90A25610C7 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=lst.de Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id 9F1788D0002; Thu, 26 Aug 2021 01:37:24 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 9A1AD8D0001; Thu, 26 Aug 2021 01:37:24 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 8B76D8D0002; Thu, 26 Aug 2021 01:37:24 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0166.hostedemail.com [216.40.44.166]) by kanga.kvack.org (Postfix) with ESMTP id 6D5D68D0001 for ; Thu, 26 Aug 2021 01:37:24 -0400 (EDT) Received: from smtpin33.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay05.hostedemail.com (Postfix) with ESMTP id F1F1D1802201C for ; Thu, 26 Aug 2021 05:37:23 +0000 (UTC) X-FDA: 78516123966.33.1519B19 Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by imf30.hostedemail.com (Postfix) with ESMTP id 5DDDAE001983 for ; Thu, 26 Aug 2021 05:37:23 +0000 (UTC) Received: by verein.lst.de (Postfix, from userid 2407) id 22FC06736F; Thu, 26 Aug 2021 07:37:20 +0200 (CEST) Date: Thu, 26 Aug 2021 07:37:19 +0200 From: Christoph Hellwig To: Nicholas Piggin Cc: Andrew Morton , Christoph Hellwig , linux-kernel@vger.kernel.org, linux-mm@kvack.org, Peter Zijlstra Subject: Re: [PATCH 2/2] mm: don't allow executable ioremap mappings Message-ID: <20210826053719.GA17085@lst.de> References: <20210824091259.1324527-1-hch@lst.de> <20210824091259.1324527-3-hch@lst.de> <1629945413.hwbzjjtfbl.astroid@bobo.none> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1629945413.hwbzjjtfbl.astroid@bobo.none> User-Agent: Mutt/1.5.17 (2007-11-01) X-Rspamd-Queue-Id: 5DDDAE001983 Authentication-Results: imf30.hostedemail.com; dkim=none; dmarc=none; spf=none (imf30.hostedemail.com: domain of hch@lst.de has no SPF policy when checking 213.95.11.211) smtp.mailfrom=hch@lst.de X-Rspamd-Server: rspam01 X-Stat-Signature: k6cpwr8t1pi694xjhn3mw76toxzpz7r9 X-HE-Tag: 1629956243-310143 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Thu, Aug 26, 2021 at 12:46:34PM +1000, Nicholas Piggin wrote: > I can't see why this is a problem. powerpcs can but it seems like a bad > idea anyway. > > Any point to a WARN_ON or return -EINVAL? Hmm, maybe that doesn't work > for archs that don't support NX. We could add a check for ones that do > support it though... But that's for another patch. This is the same as we do for regular vmap. I can't remember why we decided on this particular approach, as it's been a while.