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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 85C42C4332F for ; Mon, 21 Nov 2022 21:33:31 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id E31296B0071; Mon, 21 Nov 2022 16:33:30 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id DE1416B0073; Mon, 21 Nov 2022 16:33:30 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id CD0206B0074; Mon, 21 Nov 2022 16:33:30 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id BE4A56B0071 for ; Mon, 21 Nov 2022 16:33:30 -0500 (EST) Received: from smtpin11.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id 45CA8160CEE for ; Mon, 21 Nov 2022 21:33:30 +0000 (UTC) X-FDA: 80158750980.11.F6C290C Received: from sin.source.kernel.org (sin.source.kernel.org [145.40.73.55]) by imf30.hostedemail.com (Postfix) with ESMTP id 63F0680009 for ; Mon, 21 Nov 2022 21:33:28 +0000 (UTC) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sin.source.kernel.org (Postfix) with ESMTPS id 98D0DCE13D6; Mon, 21 Nov 2022 21:33:23 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9486FC433C1; Mon, 21 Nov 2022 21:33:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1669066401; bh=Dl1R9b0AHghTRfXyys1XgEZQ5J33PnAzaYPtOIHH+zM=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=dwGiAgsGwInbdHDjuP9L+CDahcr5Nn6x2oKNpsogkF0A+fZ06kwUY+t2PFN53uC3n Y3dv4ajua98tlVlDTMUVDpA4w8xZ2vAclcKisv5Px1E/CctRrOTNBxxUybF55iYRjC 8/kiCJOHBIRWIcp9tINmI7Gbyo02sYAX664KKRNA= Date: Mon, 21 Nov 2022 13:33:20 -0800 From: Andrew Morton To: David Hildenbrand Cc: Mike Kravetz , Jason Gunthorpe , linux-kernel@vger.kernel.org, linux-mm@kvack.org, Peter Xu , John Hubbard , syzbot+f0b97304ef90f0d0b1dc@syzkaller.appspotmail.com Subject: Re: [PATCH v1] mm/gup: disallow FOLL_FORCE|FOLL_WRITE on hugetlb mappings Message-Id: <20221121133320.a4e1c70af6ca72f29795fd5f@linux-foundation.org> In-Reply-To: References: <20221031152524.173644-1-david@redhat.com> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit ARC-Authentication-Results: i=1; imf30.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=dwGiAgsG; spf=pass (imf30.hostedemail.com: domain of akpm@linux-foundation.org designates 145.40.73.55 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org; dmarc=none ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1669066408; a=rsa-sha256; cv=none; b=nCF7cRE6HEmWM7SAFPFsU7lzSE8HJS104VXS3L2s+ncZFLy1lGTNSM5KG9AKJie1WN5l/t Qq1qzR77n1dz9ztOo8jZLUT2nEEwMUOKn2GBanjYFilUf75uOQWplTBELKG51B+Lc3okuS GSsqRVVTIVzozlu2aLYEE6CBS9xqMJM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1669066408; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=S611SA/RoecAaGTTC8a7BAlYsn2YQa/XDmOFBDk9MxA=; b=zG735JmIGhUSS0YTnMYupTw017g0w9SeOT7sibr/6xuxMl6agoKRJb/yrXkyMOC91nvg7j BFq+k6eMy9pU+eMYHRo7MKPifX7uh+IGk+oJG72eD212AoSGuDJ1iytKBnUqyvgPaRwp+9 kbci7ubmRu6wNBUn2bPkQoJSaw1sXEo= X-Rspamd-Queue-Id: 63F0680009 X-Rspam-User: Authentication-Results: imf30.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=korg header.b=dwGiAgsG; spf=pass (imf30.hostedemail.com: domain of akpm@linux-foundation.org designates 145.40.73.55 as permitted sender) smtp.mailfrom=akpm@linux-foundation.org; dmarc=none X-Rspamd-Server: rspam06 X-Stat-Signature: o85aguuau69n868aeswdd4omuce98jfp X-HE-Tag: 1669066407-263096 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 Mon, 21 Nov 2022 09:05:43 +0100 David Hildenbrand wrote: > >> MikeK do you have test cases? > > > > Sorry, I do not have any test cases. > > > > I can ask one of our product groups about their usage. But, that would > > certainly not be a comprehensive view. > > With > > https://lkml.kernel.org/r/20221116102659.70287-1-david@redhat.com > > on it's way, the RDMA concern should be gone, hopefully. > > @Andrew, can you queue this one? Thanks. This is all a little tricky. It's not good that 6.0 and earlier permit unprivileged userspace to trigger a WARN. But we cannot backport this fix into earlier kernels because it requires the series "mm/gup: remove FOLL_FORCE usage from drivers (reliable R/O long-term pinning)". Is it possible to come up with a fix for 6.1 and earlier which won't break RDMA?