summaryrefslogtreecommitdiffstats
path: root/Documentation/sound
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2019-11-05 16:18:56 +0100
committerTakashi Iwai <tiwai@suse.de>2019-11-06 15:47:43 +0100
commitb65f131b8f47b399a0635f028af3888f8c741ae1 (patch)
tree99f0180e7b1698a97bce4509836497cd7621d46c /Documentation/sound
parent6974f8ad44946701779209cb03cd8c6b598c3342 (diff)
downloadlinux-b65f131b8f47b399a0635f028af3888f8c741ae1.tar.bz2
ALSA: docs: Remove snd_dma_pci_data() usage in documentation
The macro will be removed soon later, so update the documentation to reflect that as well. Link: https://lore.kernel.org/r/20191105151856.10785-25-tiwai@suse.de Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'Documentation/sound')
-rw-r--r--Documentation/sound/kernel-api/writing-an-alsa-driver.rst10
1 files changed, 5 insertions, 5 deletions
diff --git a/Documentation/sound/kernel-api/writing-an-alsa-driver.rst b/Documentation/sound/kernel-api/writing-an-alsa-driver.rst
index ba008ce28029..dcb7940435d9 100644
--- a/Documentation/sound/kernel-api/writing-an-alsa-driver.rst
+++ b/Documentation/sound/kernel-api/writing-an-alsa-driver.rst
@@ -1383,7 +1383,7 @@ shows only the skeleton, how to build up the PCM interfaces.
/* pre-allocation of buffers */
/* NOTE: this may fail */
snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_DEV,
- snd_dma_pci_data(chip->pci),
+ &chip->pci->dev,
64*1024, 64*1024);
return 0;
}
@@ -1470,7 +1470,7 @@ buffer. For the pre-allocation, simply call the following:
::
snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_DEV,
- snd_dma_pci_data(chip->pci),
+ &chip->pci->dev,
64*1024, 64*1024);
It will allocate a buffer up to 64kB as default. Buffer management
@@ -3514,7 +3514,7 @@ bus).
::
snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_DEV,
- snd_dma_pci_data(pci), size, max);
+ &pci->dev, size, max);
where ``size`` is the byte size to be pre-allocated and the ``max`` is
the maximum size to be changed via the ``prealloc`` proc file. The
@@ -3700,14 +3700,14 @@ For creating the SG-buffer handler, call
:c:func:`snd_pcm_lib_preallocate_pages()` or
:c:func:`snd_pcm_lib_preallocate_pages_for_all()` with
``SNDRV_DMA_TYPE_DEV_SG`` in the PCM constructor like other PCI
-pre-allocator. You need to pass ``snd_dma_pci_data(pci)``, where pci is
+pre-allocator. You need to pass ``&pci->dev``, where pci is
the :c:type:`struct pci_dev <pci_dev>` pointer of the chip as
well.
::
snd_pcm_lib_preallocate_pages_for_all(pcm, SNDRV_DMA_TYPE_DEV_SG,
- snd_dma_pci_data(pci), size, max);
+ &pci->dev, size, max);
The ``struct snd_sg_buf`` instance is created as
``substream->dma_private`` in turn. You can cast the pointer like: