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=-2.1 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, 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 CF639C43331 for ; Tue, 12 Nov 2019 20:49:04 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (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 795E92067B for ; Tue, 12 Nov 2019 20:49:04 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=ziepe.ca header.i=@ziepe.ca header.b="AsvHvDs3" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 795E92067B Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ziepe.ca Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Received: from bilbo.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 47CKbf261gzF4YZ for ; Wed, 13 Nov 2019 07:49:02 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=ziepe.ca (client-ip=2607:f8b0:4864:20::844; helo=mail-qt1-x844.google.com; envelope-from=jgg@ziepe.ca; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=ziepe.ca Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=ziepe.ca header.i=@ziepe.ca header.b="AsvHvDs3"; dkim-atps=neutral Received: from mail-qt1-x844.google.com (mail-qt1-x844.google.com [IPv6:2607:f8b0:4864:20::844]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 47CKVv1QL3zF4H2 for ; Wed, 13 Nov 2019 07:44:54 +1100 (AEDT) Received: by mail-qt1-x844.google.com with SMTP id y39so21353579qty.0 for ; Tue, 12 Nov 2019 12:44:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=XIC1APSxWrFcW1GblyShF0CTBN3WBCz4HlbvzX3i8nA=; b=AsvHvDs3axCMUqe+N7mXppqZcG4z4QzjW7DgwuxQQSvowjzw09zSM8n30iqPxyhiVG Xh8VyKwma0MzyaZ4I7in3iXleDEuEusIaoOY6nDlenNeAk67Wg5jNcvcitJtB14ouZSU jEwtlMvkVKE/9wAQOETCpzIOvdkPz6MUeIKWQaYMSrFJbWX7VcVwtA5CNXlEKm0VsyqY ifzvXwANYm60xkTRX8oLmVVhv+FGDqeTm28/AUUM6Qiw102m5SB7HZ3RG7baH2DiI3v+ pcZdlJkq9BzOBgC+D5ynKGUuwhq6rk47T2j6RjHfuuaJ84S/d0bRcfAl5P4tkZR1pUiM WWGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=XIC1APSxWrFcW1GblyShF0CTBN3WBCz4HlbvzX3i8nA=; b=Hs6rRjf4IEfUAnLI+zz4Kvyko+QDPNIxhXVVTrtz/epgoiLGXiwbLie4zbouUCJPSp WvNknkSjLv6YtH/8qKjRdZNb3xXWMWF0PQyQrgaOwAe1VsOnqhEr5X0tgO9j1swlm6G8 Gfq4YzxU/E5/lA/IbIcMyxaxn5eyW4VTJz99QdGzQy8Rp6mbcKFyMUyhmiIO84yvBmgK jEGMI3DGLXG9g5ricyVp7i+SDJ8z+NX6bdtD1rERkmme3doH5m59+Jj2qxmazTAZYDDx Eq1/huIvZkVCYCHFi+Qpnr8U4zNR0M2+yXcYi1CwwJlwTx98i1ADXWaBToEoI3QVslSA Xqrw== X-Gm-Message-State: APjAAAVDOT6DUpWvq8DEUH/9oQybvGgAeCQ6fKcEmaEADKKDZhH04vFD u53tCfoc++Gksyrxj6fAmhngPw== X-Google-Smtp-Source: APXvYqxT1AevYU83mBSAAzVL5cKCr9RO3QTTsZEZsQx1j+Xe2+nGL/UnUh0Po7qNt16fHJ031L5RZg== X-Received: by 2002:ac8:6641:: with SMTP id j1mr34362241qtp.48.1573591490500; Tue, 12 Nov 2019 12:44:50 -0800 (PST) Received: from ziepe.ca (hlfxns017vw-142-162-113-180.dhcp-dynamic.fibreop.ns.bellaliant.net. [142.162.113.180]) by smtp.gmail.com with ESMTPSA id u67sm4906223qkf.115.2019.11.12.12.44.49 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 12 Nov 2019 12:44:49 -0800 (PST) Received: from jgg by mlx.ziepe.ca with local (Exim 4.90_1) (envelope-from ) id 1iUd1t-00047P-Dy; Tue, 12 Nov 2019 16:44:49 -0400 Date: Tue, 12 Nov 2019 16:44:49 -0400 From: Jason Gunthorpe To: John Hubbard Subject: Re: [PATCH v3 11/23] IB/{core,hw,umem}: set FOLL_PIN, FOLL_LONGTERM via pin_longterm_pages*() Message-ID: <20191112204449.GF5584@ziepe.ca> References: <20191112000700.3455038-1-jhubbard@nvidia.com> <20191112000700.3455038-12-jhubbard@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20191112000700.3455038-12-jhubbard@nvidia.com> User-Agent: Mutt/1.9.4 (2018-02-28) X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Michal Hocko , Jan Kara , kvm@vger.kernel.org, linux-doc@vger.kernel.org, David Airlie , Dave Chinner , dri-devel@lists.freedesktop.org, LKML , linux-mm@kvack.org, Paul Mackerras , linux-kselftest@vger.kernel.org, Ira Weiny , Jonathan Corbet , linux-rdma@vger.kernel.org, Christoph Hellwig , Vlastimil Babka , =?utf-8?B?QmrDtnJuIFTDtnBlbA==?= , linux-media@vger.kernel.org, Shuah Khan , linux-block@vger.kernel.org, =?utf-8?B?SsOpcsO0bWU=?= Glisse , Al Viro , Dan Williams , Mauro Carvalho Chehab , bpf@vger.kernel.org, Magnus Karlsson , Jens Axboe , netdev@vger.kernel.org, Alex Williamson , Daniel Vetter , linux-fsdevel@vger.kernel.org, Andrew Morton , linuxppc-dev@lists.ozlabs.org, "David S . Miller" , Mike Kravetz Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" On Mon, Nov 11, 2019 at 04:06:48PM -0800, John Hubbard wrote: > @@ -542,7 +541,7 @@ static int ib_umem_odp_map_dma_single_page( > } > > out: > - put_user_page(page); > + put_page(page); > > if (remove_existing_mapping) { > ib_umem_notifier_start_account(umem_odp); > @@ -639,13 +638,14 @@ int ib_umem_odp_map_dma_pages(struct ib_umem_odp *umem_odp, u64 user_virt, > /* > * Note: this might result in redundent page getting. We can > * avoid this by checking dma_list to be 0 before calling > - * get_user_pages. However, this make the code much more > - * complex (and doesn't gain us much performance in most use > - * cases). > + * get_user_pages. However, this makes the code much > + * more complex (and doesn't gain us much performance in most > + * use cases). > */ > npages = get_user_pages_remote(owning_process, owning_mm, > - user_virt, gup_num_pages, > - flags, local_page_list, NULL, NULL); > + user_virt, gup_num_pages, > + flags, local_page_list, NULL, > + NULL); > up_read(&owning_mm->mmap_sem); This is just whitespace churn? Drop it.. Jason