Received: by 2002:a05:6a10:eb17:0:0:0:0 with SMTP id hx23csp315953pxb; Wed, 8 Sep 2021 01:42:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwbZiJDdi2L/6qi4SAujz/Rc/Po/O/GieHuBugfxjy7mXmQGhj8Dww43himy4FbsqLiu28i X-Received: by 2002:a5e:d60e:: with SMTP id w14mr2330781iom.135.1631090577892; Wed, 08 Sep 2021 01:42:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631090577; cv=none; d=google.com; s=arc-20160816; b=t1EutrndnUQZHZVJz1wUXo9y0/KobN3lJGSQqlekyVF0iS9FlPaJWAufdtpw5jIxgY L2MlCSeSony2afxrdfle0ZNAkdyLWiQ3KgBohRxtkawjGyIqEtmhQNM2BTUm5TjTyutP NdpYcW6u3IQqtu+J7hRUdVrvRHSW1gv8ukFJn9JO3MhVK3OL9TFPsEJUAcsu1DswncUE Tfh1NyrMOdFRK5aOmutRQpM2vl56t3C8R6fYG5xCLGaXMC6NK8+piehjD2n2byY2KVtG IWf9WXL9eYGJSd+TGnSNKjsQg1XFXSo/CJD3Son9H+P1qw+cRi20l16Di4XHdHSByH99 GTqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=QA5c6ee/4LdX9O/lJ4+gekDunPk9QmR1WF15kyKxf30=; b=PLK/9Fz3YtUxPGABK/1y+Y1HT74dQz9a6goCOSBWLWlxi+1Cp+/pZLbZonCvJ1INKR qZzk0sIqwLD2UD7JoEv0WcO0UwMexuCLa/zFcABdrx0gl3pCyDljcuCERw6kMKSKqRwN iGOIhUhPTe95FCg4FSB0MH9ZnGykgsdjbJu9guh3Da7ToN+ItCjsEBfCG/F+d34BQtde mOmMag74SwKmB9ajcS7J2nVmbG8LWIrUctAioFqSVtAUD6U70MYEYMuaLvMQqaJtGzVo QnY7TL+Bw85WPacC+bF+kCjeZq+dS31XPPbBa9Fu/KfpS3VOfCUsuNRrZWC4nH/RSRKo 42XA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@igel-co-jp.20150623.gappssmtp.com header.s=20150623 header.b="s5iU/UvC"; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id 8si1308861jay.69.2021.09.08.01.42.42; Wed, 08 Sep 2021 01:42:57 -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=@igel-co-jp.20150623.gappssmtp.com header.s=20150623 header.b="s5iU/UvC"; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1348281AbhIHInH (ORCPT + 99 others); Wed, 8 Sep 2021 04:43:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36678 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234781AbhIHInA (ORCPT ); Wed, 8 Sep 2021 04:43:00 -0400 Received: from mail-lf1-x12f.google.com (mail-lf1-x12f.google.com [IPv6:2a00:1450:4864:20::12f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5F485C061575 for ; Wed, 8 Sep 2021 01:41:52 -0700 (PDT) Received: by mail-lf1-x12f.google.com with SMTP id h16so3380900lfk.10 for ; Wed, 08 Sep 2021 01:41:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=igel-co-jp.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=QA5c6ee/4LdX9O/lJ4+gekDunPk9QmR1WF15kyKxf30=; b=s5iU/UvCaZBwiUWMfEvWaSDiTOKnXPbBahiZH9wRhygyMPY/h/V/x7OnzNzYQbMfAq tZWNRIzwkd4ka8cRkpCPkTBMpo6gI55CQ/0+dELgOMGyg+E61drtbDbhTnBivikcAoqd 90skABsYsq2PNuAqc8sBBUk0sYxwRr128cf8yERIqx4p6Tn4EHp0pPiYNprX8uT0QBse 6b2XsW/YLAGKsORXRdw9Q5pt+/DMzI//VZRrwB0SRcXYpn4SAGphXKpJeDKRIgrep1qS CLaE0YHxQbyUara2Qn5f7z8y06uoAi90ayLi2YDCbL+IrIW5gswQvS2diI/o3vvv0HL/ 8ZdQ== 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:content-transfer-encoding; bh=QA5c6ee/4LdX9O/lJ4+gekDunPk9QmR1WF15kyKxf30=; b=c0Ih5mQA57SsyitslDaLyxA0VorWEE44C/heFoiVb8RTt/zwavy/fgJ6TSVlw+8zY0 Wnrzjh+IvBi0feALQf/zpgXYnGncK5IF5rOiXoJ/UuBQB8Q7aUC5QWAyKbmodquTwkg6 Q/woAKcQkxv2Povmq/v9bpNcKfxYE8KMHgy9Api9j07cf3eGV8nDrTx48POYkhIL+T4E g0V9N3GHhmAM1Uql3My+puBK/76YevCuM90THcpgV8u1GAlgP3xshWL7BMvxojZISj9c Dd0ENNF8UmOZdl/LQkB3X45Xpw4Mb7fJIKyDV1kKwGq2YF+LY76ntXfrF5NWaEzhpfRI 4d4Q== X-Gm-Message-State: AOAM5306JXdVdIcFDP8xCn6sKlFX3J8uSRvm0jg/PfcWnCOXtkP+YxU5 Zriz4sO4yzaxxuNBaDQ2GUFw/6IpCdc2IqQ3kXQRyg== X-Received: by 2002:a05:6512:139c:: with SMTP id p28mr1806408lfa.523.1631090510774; Wed, 08 Sep 2021 01:41:50 -0700 (PDT) MIME-Version: 1.0 References: <20210908061611.69823-1-mie@igel.co.jp> <20210908061611.69823-2-mie@igel.co.jp> In-Reply-To: From: Shunsuke Mie Date: Wed, 8 Sep 2021 17:41:39 +0900 Message-ID: Subject: Re: [RFC PATCH 1/3] RDMA/umem: Change for rdma devices has not dma device To: Christoph Hellwig Cc: Zhu Yanjun , "Christian K??nig" , Alex Deucher , Daniel Vetter , Doug Ledford , Jason Gunthorpe , Jianxin Xiong , Leon Romanovsky , linux-kernel@vger.kernel.org, linux-rdma@vger.kernel.org, Damian Hobson-Garcia , Takanari Hayama , Tomohito Esaki Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 2021=E5=B9=B49=E6=9C=888=E6=97=A5(=E6=B0=B4) 16:20 Christoph Hellwig : > > On Wed, Sep 08, 2021 at 04:01:14PM +0900, Shunsuke Mie wrote: > > Thank you for your comment. > > > > > > On Wed, Sep 08, 2021 at 03:16:09PM +0900, Shunsuke Mie wrote: > > > > To share memory space using dma-buf, a API of the dma-buf requires = dma > > > > device, but devices such as rxe do not have a dma device. For those= case, > > > > change to specify a device of struct ib instead of the dma device. > > > > > > So if dma-buf doesn't actually need a device to dma map why do we eve= r > > > pass the dma_device here? Something does not add up. > > As described in the dma-buf api guide [1], the dma_device is used by dm= a-buf > > exporter to know the device buffer constraints of importer. > > [1] https://lwn.net/Articles/489703/ > > Which means for rxe you'd also have to pass the one for the underlying > net device. I thought of that way too. In that case, the memory region is constrained b= y the net device, but rxe driver copies data using CPU. To avoid the constraints,= I decided to use the ib device. Thanks,