Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1206413
| From | Julian Calaby <julian.calaby@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: RFC: prepare for struct scatterlist entries without page backing |
| Date | 2015-08-13 01:40 +0200 |
| Message-ID | <pWNMJ-2tG-1@gated-at.bofh.it> (permalink) |
| References | <pWykF-5Aj-9@gated-at.bofh.it> <pWDDI-4EJ-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Hi, On Wed, Aug 12, 2015 at 10:42 PM, Boaz Harrosh <boaz@plexistor.com> wrote: > On 08/12/2015 10:05 AM, Christoph Hellwig wrote: >> It turns out most DMA mapping implementation can handle SGLs without >> page structures with some fairly simple mechanical work. Most of it >> is just about consistently using sg_phys. For implementations that >> need to flush caches we need a new helper that skips these cache >> flushes if a entry doesn't have a kernel virtual address. >> >> However the ccio (parisc) and sba_iommu (parisc & ia64) IOMMUs seem >> to be operate mostly on virtual addresses. It's a fairly odd concept >> that I don't fully grasp, so I'll need some help with those if we want >> to bring this forward. >> >> Additional this series skips ARM entirely for now. The reason is >> that most arm implementations of the .map_sg operation just iterate >> over all entries and call ->map_page for it, which means we'd need >> to convert those to a ->map_pfn similar to Dan's previous approach. >> > [snip] > > It is a bit of work but is worth while, and accelerating tremendously > lots of workloads. Not like this abomination which only branches > things more and more, and making things fatter and slower. As a random guy reading a big bunch of patches on code I know almost nothing about, parts of this comment really resonated with me: overall, we seem to be adding a lot of if statements to code that appears to be in a hot path. I.e. ~90% of this patch set seems to be just mechanically dropping BUG_ON()s and converting open coded stuff to use accessor functions (which should be macros or get inlined, right?) - and the remaining bit is not flushing if we don't have a physical page somewhere. Would it make sense to split this patch set into a few bits: one to drop all the useless BUG_ON()s, one to convert all the open coded stuff to accessor functions, then another to do the actual page-less sg stuff? Thanks, -- Julian Calaby Email: julian.calaby@gmail.com Profile: http://www.google.com/profiles/julian.calaby/ -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
RFC: prepare for struct scatterlist entries without page backing Christoph Hellwig <hch@lst.de> - 2015-08-12 09:20 +0200
[PATCH 22/31] metag: handle page-less SG entries Christoph Hellwig <hch@lst.de> - 2015-08-12 09:20 +0200
[PATCH 07/31] alpha/pci_iommu: handle page-less SG entries Christoph Hellwig <hch@lst.de> - 2015-08-12 09:20 +0200
[PATCH 28/31] powerpc: handle page-less SG entries Christoph Hellwig <hch@lst.de> - 2015-08-12 09:20 +0200
[PATCH 23/31] sh: handle page-less SG entries Christoph Hellwig <hch@lst.de> - 2015-08-12 09:20 +0200
[PATCH 16/31] s390: handle page-less SG entries Christoph Hellwig <hch@lst.de> - 2015-08-12 09:20 +0200
Re: [PATCH 16/31] s390: handle page-less SG entries Sebastian Ott <sebott@linux.vnet.ibm.com> - 2015-08-12 14:00 +0200
[PATCH 11/31] sparc/iommu: handle page-less SG entries Christoph Hellwig <hch@lst.de> - 2015-08-12 09:20 +0200
[PATCH 03/31] dma-debug: handle page-less SG entries Christoph Hellwig <hch@lst.de> - 2015-08-12 09:30 +0200
[PATCH 06/31] alpha/pci-noop: handle page-less SG entries Christoph Hellwig <hch@lst.de> - 2015-08-12 09:30 +0200
[PATCH 02/31] scatterlist: use sg_phys() Christoph Hellwig <hch@lst.de> - 2015-08-12 09:30 +0200
[PATCH 01/31] scatterlist: add sg_pfn and sg_has_page helpers Christoph Hellwig <hch@lst.de> - 2015-08-12 09:30 +0200
Re: RFC: prepare for struct scatterlist entries without page backing Boaz Harrosh <boaz@plexistor.com> - 2015-08-12 14:50 +0200
Re: RFC: prepare for struct scatterlist entries without page backing Julian Calaby <julian.calaby@gmail.com> - 2015-08-13 01:40 +0200
Re: RFC: prepare for struct scatterlist entries without page backing Christoph Hellwig <hch@lst.de> - 2015-08-13 16:40 +0200
Re: RFC: prepare for struct scatterlist entries without page backing Julian Calaby <julian.calaby@gmail.com> - 2015-08-14 01:50 +0200
Re: RFC: prepare for struct scatterlist entries without page backing Christoph Hellwig <hch@lst.de> - 2015-08-13 16:50 +0200
Re: RFC: prepare for struct scatterlist entries without page backing Boaz Harrosh <boaz@plexistor.com> - 2015-08-13 17:50 +0200
Re: RFC: prepare for struct scatterlist entries without page backing James Bottomley <James.Bottomley@HansenPartnership.com> - 2015-08-12 19:10 +0200
Re: RFC: prepare for struct scatterlist entries without page backing Grant Grundler <grantgrundler@gmail.com> - 2015-08-12 20:00 +0200
csiph-web