public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "Nikita V. Youshchenko" <yoush@cs.msu.su>
To: linux-kernel@vger.kernel.org
Cc: stefan@lvk.cs.msu.su
Subject: high-order allocation + highmem + streaming DMA - possible?
Date: Wed, 19 Oct 2011 10:45:40 +0400	[thread overview]
Message-ID: <201110191045.42613@zigzag.lvk.cs.msu.su> (raw)

Hello.

We are writing a driver for a custom PCI device that receives large amount 
of data.

Device is capable of DMAing received data in 64k chunks.

We have been going to:
- use physically-continuous 64k-sized memory areas using alloc_pages() with 
order=4,
- allocate large number of such areas on driver init,
- implement mmap() to map those all to userspace for zero-copy processing,
- use streaming DMA to actually receive data

However I can't find a way to use streaming DMA for large highmem areas.
- pci_map_single() is for linear mapping and can't work with highmem
- pci_map_page() can work with highmem but is limited to one page
- pci_map_sg() is for s/g lists, not for single 64k blocks.

Is there a way to use streaming DMA with large memory areas located in 
highmem?
Or in this situation buffers in highmem can't be used?

Nikita

             reply	other threads:[~2011-10-19  6:51 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-19  6:45 Nikita V. Youshchenko [this message]
2011-10-19 10:24 ` high-order allocation + highmem + streaming DMA - possible? RKK
2011-10-19 10:55   ` Nikita V. Youshchenko

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=201110191045.42613@zigzag.lvk.cs.msu.su \
    --to=yoush@cs.msu.su \
    --cc=linux-kernel@vger.kernel.org \
    --cc=stefan@lvk.cs.msu.su \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox