Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp1823234rwb; Fri, 28 Jul 2023 16:01:08 -0700 (PDT) X-Google-Smtp-Source: APBJJlG9Dqs7q5KAoPFGZKHs6/kPKSKF1Cu/NIItig2Ni4hCB/Y5OYAbv3T43sm/RG1z9WnkcfVl X-Received: by 2002:a05:6a21:3e05:b0:133:2a73:fdd5 with SMTP id bk5-20020a056a213e0500b001332a73fdd5mr2701366pzc.32.1690585268243; Fri, 28 Jul 2023 16:01:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690585268; cv=none; d=google.com; s=arc-20160816; b=w9HolI+aJEKKf/aWBV+sNKrJUkXtIs9tHqa5TxT2s78wTsuOx+Hg/tXOKb5JEozMhg OgQJeH/7NsMduCPw2TMlmFRdYfuq2I38m8EjpEiel7GuimpPjZ0DjvaRqKkSz05bmW/m 1jUFqRbYp4S1WkKhn4UUdXCqp/aGr8wNiU3TRJbWjvGhXGvGVLX5yy+h5XUfY0l5lpnN vD//FBO9LfYdalUmEWeGywldSMIbkw6p1AJ6I9YawG51Pb0y+c/Z/5eB0tcCvFgmPj9c enFgAYM8tp3u7J6RAHRu6zK9qwD8DpHU72//ZJ3f+I30LKECWjhyBhcSCx+tHUM/fLZ8 6wGg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=X2WhoRj0lwDKacxOziWBDjdJtIWuF0uoNKyCx6NeZN8=; fh=v4poGVaZcpEYnVDOBIfIgv6ezOWZ2qWKwsf/JKkr1s8=; b=AF0Q61MLPJJ0XQmjIKUXqW2lTdGElbphBWIb0pBjCPniz7aLneb2+jOQ5wmgjE2VGl WhVTH2NPOpuAq2uceVYUc7UOBRTwqTaAukaqXowWLY2bPsoq5JFVuQ97t+eoupALhIGS 7cwZn4eR0dW8UJhA5/AgsuFDDlbH+WkCiFXH4390vd6vkO013YSmvI0RM0P9BMFVocFU Z93VhxZDPqfdtoJ5WMvhcTaqJY5pVh613NQN/STz+5Aiaolg4kfjOswert/kxmf0BPiR zpuUUhqTM48LzNEdH1FxMIHp/8AJdUb6X3OA9GMEhrmP8R6cWr4nJgiJIh9h2XcksjS1 1fgQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=WKjeCM2T; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id lc7-20020a170902fa8700b001b873b80747si3607389plb.39.2023.07.28.16.00.54; Fri, 28 Jul 2023 16:01:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=WKjeCM2T; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233684AbjG1VuA (ORCPT + 99 others); Fri, 28 Jul 2023 17:50:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37002 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231397AbjG1Vt7 (ORCPT ); Fri, 28 Jul 2023 17:49:59 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 73EA9123 for ; Fri, 28 Jul 2023 14:49:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1690580958; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=X2WhoRj0lwDKacxOziWBDjdJtIWuF0uoNKyCx6NeZN8=; b=WKjeCM2T0iPHoUrWgKRg5i1rqwtD2kKhdMR67flpwh0gjBucbhqBQfpOEwQRT7VLonVvS3 9wrg3+u1k9pql86fvuQ9AMVPzM+j4q/areFd5nV59iyay+HDyDOmlX/Rot1+rOBIKqo9p5 rsvE+fWQNNOvTYeQ31TaVF+dN/PXVgU= Received: from mail-qt1-f200.google.com (mail-qt1-f200.google.com [209.85.160.200]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-115-fzY58KK7O7GVZGM_pUYZrQ-1; Fri, 28 Jul 2023 17:49:17 -0400 X-MC-Unique: fzY58KK7O7GVZGM_pUYZrQ-1 Received: by mail-qt1-f200.google.com with SMTP id d75a77b69052e-405512b12f5so4812161cf.0 for ; Fri, 28 Jul 2023 14:49:17 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690580956; x=1691185756; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=X2WhoRj0lwDKacxOziWBDjdJtIWuF0uoNKyCx6NeZN8=; b=Y77wgkKihaxL2PMDBmEBvrvD3bNmWe+AN6OLX+VPg0HQHgxCIJue8ICA8241RE1tlT EWf8ffGxltQBeDB39dK4eMXEc4y3a96n9XG13ihyhL4gIKARzd7iiRo1hRJE+jiOtvWy i28xCkssvgjGrVPplAMJCH2CmM/I+YtLfaBmnczRIIQWCMXKSuYN3WWw1/1tUpx+u+QL GuXRIuo78J1ya4jif3PACOmZtqSJI0+Tvfq+dik8IZp8pJJVaAZ6uW1Utsp8tWKqVe71 QQlb0KlcPUvPvsja1P1K3bl6myUOg0UsbSZknvj/fKQFYW9rfRjNFv69KZ/0RFowlpfw /sZQ== X-Gm-Message-State: ABy/qLYN61QXjlXXkVRllFG7pOemW/qL9LonwTWPe6HTIWhg23yixK/c vkeWql9VVFs+g2T6Yw9V7g+JAWvL5IO4nlPIXOWuvRRtM5v1oUIcRjm0H/BNh1CyhqguP5H1+Zk Y4I8VHvbPeioWpSaW+FnykLFJ X-Received: by 2002:a05:622a:1812:b0:400:84a9:a09c with SMTP id t18-20020a05622a181200b0040084a9a09cmr783861qtc.6.1690580956618; Fri, 28 Jul 2023 14:49:16 -0700 (PDT) X-Received: by 2002:a05:622a:1812:b0:400:84a9:a09c with SMTP id t18-20020a05622a181200b0040084a9a09cmr783836qtc.6.1690580956269; Fri, 28 Jul 2023 14:49:16 -0700 (PDT) Received: from x1n (cpe5c7695f3aee0-cm5c7695f3aede.cpe.net.cable.rogers.com. [99.254.144.39]) by smtp.gmail.com with ESMTPSA id u18-20020a05622a14d200b003f3937c16c4sm1457623qtx.5.2023.07.28.14.49.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Jul 2023 14:49:15 -0700 (PDT) Date: Fri, 28 Jul 2023 17:49:13 -0400 From: Peter Xu To: John Hubbard Cc: David Hildenbrand , Linus Torvalds , linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, Andrew Morton , liubo , Matthew Wilcox , Hugh Dickins , Jason Gunthorpe Subject: Re: [PATCH v1 0/4] smaps / mm/gup: fix gup_can_follow_protnone fallout Message-ID: References: <20230727212845.135673-1-david@redhat.com> <69a5f457-63b6-2d4f-e5c0-4b3de1e6c9f1@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello, John, On Fri, Jul 28, 2023 at 02:32:12PM -0700, John Hubbard wrote: > On 7/28/23 14:20, Peter Xu wrote: > > On Fri, Jul 28, 2023 at 11:02:46PM +0200, David Hildenbrand wrote: > > > Can we get a simple revert in first (without that FOLL_FORCE special casing > > > and ideally with a better name) to handle stable backports, and I'll > > > follow-up with more documentation and letting GUP callers pass in that flag > > > instead? > > > > > > That would help a lot. Then we also have more time to let that "move it to > > > GUP callers" mature a bit in -next, to see if we find any surprises? > > > > As I raised my concern over the other thread, I still worry numa users can > > be affected by this change. After all, numa isn't so uncommon to me, at > > least fedora / rhel as CONFIG_NUMA_BALANCING_DEFAULT_ENABLED=y. I highly > > suspect that's also true to major distros. Meanwhile all kernel modules > > use gup.. > > > > I'd say we can go ahead and try if we want, but I really don't know why > > that helps in any form to move it to the callers.. with the risk of > > breaking someone. > > It's worth the trouble, in order to clear up this historical mess. It's > helping *future* callers of the API, and future maintenance efforts. Yes > there is some risk, but it seems very manageable. > > The story of how FOLL_NUMA and FOLL_FORCE became entangled was enlightening, > by the way, and now that I've read it I don't want to go back. :) Yeah I fully agree we should hopefully remove the NUMA / FORCE tangling.. even if we want to revert back to the FOLL_NUMA flag we may want to not revive that specific part. I had a feeling that we're all on the same page there. It's more about the further step to make FOLL_NUMA opt-in for GUP. Thanks, -- Peter Xu