All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg-uk2M96/98Pc@public.gmane.org>
To: Christoph Hellwig <hch-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>
Cc: "Wei Hu (Xavier)"
	<xavier.huwei-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>,
	shaobo.xu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org,
	xavier.huwei-WVlzvzqoTvw@public.gmane.org,
	lijun_nudt-9Onoh4P/yGk@public.gmane.org,
	oulijun-hv44wF8Li93QT0dZR+AlfA@public.gmane.org,
	Leon Romanovsky <leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	charles.chenxin-hv44wF8Li93QT0dZR+AlfA@public.gmane.org,
	linuxarm-hv44wF8Li93QT0dZR+AlfA@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-mm-Bw31MaZKKs3YtjvyW6yDsg@public.gmane.org,
	iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org,
	liuyixian-hv44wF8Li93QT0dZR+AlfA@public.gmane.org,
	zhangxiping3-hv44wF8Li93QT0dZR+AlfA@public.gmane.org,
	shaoboxu-WVlzvzqoTvw@public.gmane.org,
	dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org
Subject: Re: [PATCH for-next 2/4] RDMA/hns: Add IOMMU enable support in hip08
Date: Tue, 7 Nov 2017 09:03:29 -0700	[thread overview]
Message-ID: <20171107160329.GF21466@ziepe.ca> (raw)
In-Reply-To: <20171107155805.GA24082-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>

On Tue, Nov 07, 2017 at 07:58:05AM -0800, Christoph Hellwig wrote:
> On Tue, Nov 07, 2017 at 08:48:38AM -0700, Jason Gunthorpe wrote:
> > Can't you just use vmalloc and dma_map that? Other drivers follow that
> > approach..
> 
> You can't easily due to the flushing requirements.  We used to do that
> in XFS and it led to problems.  You need the page allocator + vmap +
> invalidate_kernel_vmap_range + flush_kernel_vmap_range to get the
> cache flushing right.

Yes, exactly something ugly like that.. :\

Jason

WARNING: multiple messages have this Message-ID (diff)
From: Jason Gunthorpe <jgg@ziepe.ca>
To: Christoph Hellwig <hch@infradead.org>
Cc: "Wei Hu (Xavier)" <xavier.huwei@huawei.com>,
	Robin Murphy <robin.murphy@arm.com>,
	Leon Romanovsky <leon@kernel.org>,
	shaobo.xu@intel.com, xavier.huwei@tom.com, lijun_nudt@163.com,
	oulijun@huawei.com, linux-rdma@vger.kernel.org,
	charles.chenxin@huawei.com, linuxarm@huawei.com,
	iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org,
	linux-mm@kvack.org, dledford@redhat.com, liuyixian@huawei.com,
	zhangxiping3@huawei.com, shaoboxu@tom.com
Subject: Re: [PATCH for-next 2/4] RDMA/hns: Add IOMMU enable support in hip08
Date: Tue, 7 Nov 2017 09:03:29 -0700	[thread overview]
Message-ID: <20171107160329.GF21466@ziepe.ca> (raw)
In-Reply-To: <20171107155805.GA24082@infradead.org>

On Tue, Nov 07, 2017 at 07:58:05AM -0800, Christoph Hellwig wrote:
> On Tue, Nov 07, 2017 at 08:48:38AM -0700, Jason Gunthorpe wrote:
> > Can't you just use vmalloc and dma_map that? Other drivers follow that
> > approach..
> 
> You can't easily due to the flushing requirements.  We used to do that
> in XFS and it led to problems.  You need the page allocator + vmap +
> invalidate_kernel_vmap_range + flush_kernel_vmap_range to get the
> cache flushing right.

Yes, exactly something ugly like that.. :\

Jason

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

WARNING: multiple messages have this Message-ID (diff)
From: Jason Gunthorpe <jgg@ziepe.ca>
To: Christoph Hellwig <hch@infradead.org>
Cc: "Wei Hu (Xavier)" <xavier.huwei@huawei.com>,
	Robin Murphy <robin.murphy@arm.com>,
	Leon Romanovsky <leon@kernel.org>,
	shaobo.xu@intel.com, xavier.huwei@tom.com, lijun_nudt@163.com,
	oulijun@huawei.com, linux-rdma@vger.kernel.org,
	charles.chenxin@huawei.com, linuxarm@huawei.com,
	iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org,
	linux-mm@kvack.org, dledford@redhat.com, liuyixian@huawei.com,
	zhangxiping3@huawei.com, shaoboxu@tom.com
Subject: Re: [PATCH for-next 2/4] RDMA/hns: Add IOMMU enable support in hip08
Date: Tue, 7 Nov 2017 09:03:29 -0700	[thread overview]
Message-ID: <20171107160329.GF21466@ziepe.ca> (raw)
In-Reply-To: <20171107155805.GA24082@infradead.org>

On Tue, Nov 07, 2017 at 07:58:05AM -0800, Christoph Hellwig wrote:
> On Tue, Nov 07, 2017 at 08:48:38AM -0700, Jason Gunthorpe wrote:
> > Can't you just use vmalloc and dma_map that? Other drivers follow that
> > approach..
> 
> You can't easily due to the flushing requirements.  We used to do that
> in XFS and it led to problems.  You need the page allocator + vmap +
> invalidate_kernel_vmap_range + flush_kernel_vmap_range to get the
> cache flushing right.

Yes, exactly something ugly like that.. :\

Jason

  parent reply	other threads:[~2017-11-07 16:03 UTC|newest]

Thread overview: 57+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-30  9:28 [PATCH for-next 0/4] Add Features & Code improvements for hip08 Wei Hu (Xavier)
2017-09-30  9:28 ` Wei Hu (Xavier)
2017-09-30  9:28 ` [PATCH for-next 2/4] RDMA/hns: Add IOMMU enable support in hip08 Wei Hu (Xavier)
2017-09-30  9:28   ` Wei Hu (Xavier)
     [not found]   ` <1506763741-81429-3-git-send-email-xavier.huwei-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2017-09-30 16:10     ` Leon Romanovsky
2017-09-30 16:10       ` Leon Romanovsky
2017-10-12 12:31       ` Wei Hu (Xavier)
2017-10-12 12:31         ` Wei Hu (Xavier)
     [not found]         ` <59DF60A3.7080803-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2017-10-12 12:59           ` Robin Murphy
2017-10-12 12:59             ` Robin Murphy
2017-10-12 12:59             ` Robin Murphy
2017-11-01  7:46             ` Wei Hu (Xavier)
2017-11-01  7:46               ` Wei Hu (Xavier)
     [not found]               ` <59F97BBE.5070207-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2017-11-01 12:26                 ` Robin Murphy
2017-11-01 12:26                   ` Robin Murphy
2017-11-01 12:26                   ` Robin Murphy
     [not found]                   ` <fc7433af-4fa7-6b78-6bec-26941a427002-5wv7dgnIgG8@public.gmane.org>
2017-11-07  2:45                     ` Wei Hu (Xavier)
2017-11-07  2:45                       ` Wei Hu (Xavier)
2017-11-07  2:45                       ` Wei Hu (Xavier)
     [not found]                       ` <5A011E49.6060407-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2017-11-07  6:32                         ` Leon Romanovsky
2017-11-07  6:32                           ` Leon Romanovsky
     [not found]                           ` <20171107063209.GA18825-U/DQcQFIOTAAJjI8aNfphQ@public.gmane.org>
2017-11-09  1:17                             ` Wei Hu (Xavier)
2017-11-09  1:17                               ` Wei Hu (Xavier)
2017-11-09  1:17                               ` Wei Hu (Xavier)
2017-11-07 15:48                       ` Jason Gunthorpe
2017-11-07 15:48                         ` Jason Gunthorpe
     [not found]                         ` <20171107154838.GC21466-uk2M96/98Pc@public.gmane.org>
2017-11-07 15:58                           ` Christoph Hellwig
2017-11-07 15:58                             ` Christoph Hellwig
2017-11-07 15:58                             ` Christoph Hellwig
     [not found]                             ` <20171107155805.GA24082-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>
2017-11-07 16:03                               ` Jason Gunthorpe [this message]
2017-11-07 16:03                                 ` Jason Gunthorpe
2017-11-07 16:03                                 ` Jason Gunthorpe
2017-11-09  1:26                               ` Wei Hu (Xavier)
2017-11-09  1:26                                 ` Wei Hu (Xavier)
2017-11-09  1:26                                 ` Wei Hu (Xavier)
2017-11-09  1:30                           ` Wei Hu (Xavier)
2017-11-09  1:30                             ` Wei Hu (Xavier)
2017-11-09  1:30                             ` Wei Hu (Xavier)
2017-11-09  1:36                   ` Wei Hu (Xavier)
2017-11-09  1:36                     ` Wei Hu (Xavier)
2017-10-12 14:54         ` Leon Romanovsky
2017-10-18  8:42       ` Wei Hu (Xavier)
2017-10-18  8:42         ` Wei Hu (Xavier)
     [not found]         ` <59E713EE.5040703-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2017-10-18  9:12           ` Wei Hu (Xavier)
2017-10-18  9:12             ` Wei Hu (Xavier)
     [not found]             ` <59E71AE2.6080202-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2017-10-18 14:23               ` Leon Romanovsky
2017-10-18 14:23                 ` Leon Romanovsky
     [not found] ` <1506763741-81429-1-git-send-email-xavier.huwei-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2017-09-30  9:28   ` [PATCH for-next 1/4] RDMA/hns: Support WQE/CQE/PBL page size configurable feature " Wei Hu (Xavier)
2017-09-30  9:28     ` Wei Hu (Xavier)
2017-09-30  9:29   ` [PATCH for-next 3/4] RDMA/hns: Update the IRRL table chunk size " Wei Hu (Xavier)
2017-09-30  9:29     ` Wei Hu (Xavier)
     [not found]     ` <1506763741-81429-4-git-send-email-xavier.huwei-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
2017-10-01  5:40       ` Leon Romanovsky
2017-10-01  5:40         ` Leon Romanovsky
2017-10-17 11:40         ` Wei Hu (Xavier)
2017-10-17 11:40           ` Wei Hu (Xavier)
2017-09-30  9:29 ` [PATCH for-next 4/4] RDMA/hns: Update the PD&CQE&MTT specification " Wei Hu (Xavier)
2017-09-30  9:29   ` Wei Hu (Xavier)

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171107160329.GF21466@ziepe.ca \
    --to=jgg-uk2m96/98pc@public.gmane.org \
    --cc=charles.chenxin-hv44wF8Li93QT0dZR+AlfA@public.gmane.org \
    --cc=dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=hch-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org \
    --cc=iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
    --cc=leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=lijun_nudt-9Onoh4P/yGk@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-mm-Bw31MaZKKs3YtjvyW6yDsg@public.gmane.org \
    --cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linuxarm-hv44wF8Li93QT0dZR+AlfA@public.gmane.org \
    --cc=liuyixian-hv44wF8Li93QT0dZR+AlfA@public.gmane.org \
    --cc=oulijun-hv44wF8Li93QT0dZR+AlfA@public.gmane.org \
    --cc=shaobo.xu-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org \
    --cc=shaoboxu-WVlzvzqoTvw@public.gmane.org \
    --cc=xavier.huwei-WVlzvzqoTvw@public.gmane.org \
    --cc=xavier.huwei-hv44wF8Li93QT0dZR+AlfA@public.gmane.org \
    --cc=zhangxiping3-hv44wF8Li93QT0dZR+AlfA@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.