Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp227712pxa; Fri, 31 Jul 2020 10:23:38 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxp9k68BUbz/pHp2fzRxM5V2DD4YTv4kYBgEcYw76htbeiwlijDa1XUef9WUup3zaNAwoeM X-Received: by 2002:a17:906:aad2:: with SMTP id kt18mr5157871ejb.537.1596216218066; Fri, 31 Jul 2020 10:23:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596216218; cv=none; d=google.com; s=arc-20160816; b=W66cG3N7JK7BT46KdUaGpPVNm7kh6dw6nrBDG/u5ZMNpKokKtc1AuC7pANWuW6/x1J bK+MbeUVNuYdFcoAC3lXOImQikWYO7Ptqj/T1Z+30AQymEZlc6ijsJsno85cxcM43TvS zZp0cqZi5OtQNR7vweELAO2Kim+8bcMMJgRAuYqHI04c9BsRMQoLtI2SJWfRy0zGmEgK ydiGJwwo63vukBqHtBPP/PNTlKBKq7YPKvcrtHRE7s2hoJ7ILUD0FbLtadspC0l6ruNk qkxGP2pby6WSpuNe0f6jczR+sKXzulxYz06nEQ/CYbs0MbmMrCBX1oSzmjHwao/JNEpP hLzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=CjnDRWhzh4EQDemiUKG1D36APM9tw49b0yekL5D351Y=; b=HbxlKC7BQm/2ntvRfvvE7HQi7uY0j6QOVnUjVdBVea6e2jqdl6XvTA7nWyu1/LabKu qii07lUPfjIMLnXZtfDh2900ToaHLSBwazK1mZkC5h09FGCfiTrQnAN0DD1qxW1FfZC7 hywuG43TwFdX8cq/sTYSL9oTVuDcOdkfrJiuWPK4yZW7QDJumJmLrX2VzaZy7xvpsqeF d0YC90cJOsDUMC7pNwhGxgCUfYiQ4Fs8md80BIQbxNXEMIFU/mGapUifbWlcF/XgDpQf dYildTVNqvDawZhVL4vjkEO6movBBgEyh8sNY6RMfHwsNN5Y8ACj+NGRGafjUfnmV7mA GmBw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=O6eLa1Ii; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ci22si4624686ejb.157.2020.07.31.10.23.15; Fri, 31 Jul 2020 10:23:38 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=O6eLa1Ii; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1733215AbgGaRVV (ORCPT + 99 others); Fri, 31 Jul 2020 13:21:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48928 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732793AbgGaRVU (ORCPT ); Fri, 31 Jul 2020 13:21:20 -0400 Received: from mail-il1-x141.google.com (mail-il1-x141.google.com [IPv6:2607:f8b0:4864:20::141]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 92C13C061574 for ; Fri, 31 Jul 2020 10:21:20 -0700 (PDT) Received: by mail-il1-x141.google.com with SMTP id j9so22566931ilc.11 for ; Fri, 31 Jul 2020 10:21:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=CjnDRWhzh4EQDemiUKG1D36APM9tw49b0yekL5D351Y=; b=O6eLa1IixT5kqe1AFaE+bcjnOe1UcPBmwrKRiFbR0M+ApxONaIjOgTgH0qPy1e+mfI BrJYF48+BZ9GpnD7otmkXOlDe7LuJF5xrz4fXbebvy9H4yWGNQFWtSAOZy/YzdiydJnI a5ogGROvvL52W54SrDcABtpl9OJHBspk06/53PKLOXweg+kONWzZqz92EIoGP7E57tYi dfHR0UsbgWj1gmT6XveGJQ9D1sQUndrUnftF4ByLAeHaJktep1m5xer6vWVXk0Hz47m/ d5I/vhBaQdxcNZBNGoMpqxGjEU+JqlRykRNRCHM9n0pzeWiwocwZ5b35DGHbQpFCf8PK vePQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=CjnDRWhzh4EQDemiUKG1D36APM9tw49b0yekL5D351Y=; b=f+kNswAjw3snaVQLpfVo0Baa1J+XHA3zd2SDkGTDgiEKO5tDbPJbs9pJGDYjqJD75J EGn/d03sYBKRjVvmBq/Rc8qOYW4b8kYQ4Kape6cq1zq2/tHBaiCxg0ycEtd/JbTQHm0M e1tZkdwMJq95/Vw0qZX/vVhQTEc97fzaKBslYGmr60Hk4uUuaydajCdYsBbCMvmR4NO9 61Kvuo0m9q/sgVuYqVv5WlJGWVbwdyN4DFpSohHAxjegOh92I27Rv4bUWX93mHXR393I hotFewYTNWc4o+JM1+WlJiGT15qVqjiEWP/UIj5SaDOxl/8xQ1dI+jdUzugLj6Q0WnJj v4EQ== X-Gm-Message-State: AOAM530LKMbYRo22cUjHyiwk+5cAqX5DWhf3XDIE1fyK2Pyqy1zKwJVN Rx9mmODUUuIkq8J0Ax0eywWLMCGOKlF2kdRxw2OZ+A== X-Received: by 2002:a92:c608:: with SMTP id p8mr4865557ilm.137.1596216079403; Fri, 31 Jul 2020 10:21:19 -0700 (PDT) MIME-Version: 1.0 References: <20200730015755.1827498-1-edumazet@google.com> <20200731171714.GA513060@nvidia.com> In-Reply-To: <20200731171714.GA513060@nvidia.com> From: Eric Dumazet Date: Fri, 31 Jul 2020 10:21:08 -0700 Message-ID: Subject: Re: [PATCH net] RDMA/umem: add a schedule point in ib_umem_get() To: Jason Gunthorpe Cc: Doug Ledford , linux-kernel , Eric Dumazet , linux-rdma Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jul 31, 2020 at 10:17 AM Jason Gunthorpe wrote: > > On Wed, Jul 29, 2020 at 06:57:55PM -0700, Eric Dumazet wrote: > > Mapping as little as 64GB can take more than 10 seconds, > > triggering issues on kernels with CONFIG_PREEMPT_NONE=y. > > > > ib_umem_get() already splits the work in 2MB units on x86_64, > > adding a cond_resched() in the long-lasting loop is enough > > to solve the issue. > > > > Note that sg_alloc_table() can still use more than 100 ms, > > which is also problematic. This might be addressed later > > in ib_umem_add_sg_table(), adding new blocks in sgl > > on demand. > > I have seen some patches in progress to do exactly this, the > motivation is to reduce the memory consumption if a lot of pages are > combined. Nice ;) > > > Signed-off-by: Eric Dumazet > > Cc: Doug Ledford > > Cc: Jason Gunthorpe > > Cc: linux-rdma@vger.kernel.org > > --- > > drivers/infiniband/core/umem.c | 1 + > > 1 file changed, 1 insertion(+) > > Why [PATCH net] ? Sorry, I used a script that I normally use for net submissions, forgot to remove this tag ;) > > Anyhow, applied to rdma for-next Thanks ! > > Thanks, > Jason