From: Takashi Iwai <tiwai@suse.de>
To: "Pharaoh ." <pharaoh137@gmail.com>
Cc: alsa-devel@alsa-project.org
Subject: Re: Query regarding snd_pcm_lib_preallocate_pages_for_all()
Date: Wed, 14 Nov 2007 09:14:41 +0100 [thread overview]
Message-ID: <s5hd4udfdla.wl%tiwai@suse.de> (raw)
In-Reply-To: <61445c750711131042qed654b8s17454534fdaa68e7@mail.gmail.com>
At Wed, 14 Nov 2007 00:12:07 +0530,
Pharaoh . wrote:
>
> Hi,
>
> I am trying to use snd_pcm_lib_preallocate_pages_for_all() on an arm based
> platform for preallocating the DMA buffer.
> I am using it as
>
> snd_pcm_lib_preallocate_pages_for_all(pcm,
> SNDRV_DMA_TYPE_DEV,
> NULL,
> 64 * 1024, 64 * 1024);
>
> since I dont know what should be passed as the 3'rd param. I tried passing
> my device pointer i.e. card->dev after
> correctly populating it but I get an error as 'DMA coherent mask in not set'
> and buffer is not allocated.
For ARM, avoid the present buffer-preallocation and mmap functions in
ALSA core. Instead you can allocate the buffers directly via normal
dma_alloc_coherent() in your driver. And, mmap it via
dma_mmap_coherent() by defining the own mmap callback for PCM ops.
See other arm/* drivers for rerecence.
Takashi
next prev parent reply other threads:[~2007-11-14 12:07 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-11-13 18:42 Query regarding snd_pcm_lib_preallocate_pages_for_all() Pharaoh .
2007-11-13 20:31 ` Mitac 8252D hda_intel glv
2007-11-14 8:14 ` Takashi Iwai [this message]
2007-11-14 12:13 ` Query regarding snd_pcm_lib_preallocate_pages_for_all() Pharaoh .
2007-11-14 9:10 ` Takashi Iwai
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=s5hd4udfdla.wl%tiwai@suse.de \
--to=tiwai@suse.de \
--cc=alsa-devel@alsa-project.org \
--cc=pharaoh137@gmail.com \
/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.