mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
Documentation/DMA-API-HOWTO.txt: fix misleading example
See: DMA-API.txt, part Id, DMA_FROM_DEVICE description. Signed-off-by: Michal Miroslaw <mirq-linux@rere.qmqm.pl> Cc: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
91f6cdf86e
commit
3f0fb4e85b
1 changed files with 6 additions and 6 deletions
|
@ -613,13 +613,13 @@ to use the dma_sync_*() interfaces.
|
||||||
pass_to_upper_layers(cp->rx_buf);
|
pass_to_upper_layers(cp->rx_buf);
|
||||||
make_and_setup_new_rx_buf(cp);
|
make_and_setup_new_rx_buf(cp);
|
||||||
} else {
|
} else {
|
||||||
/* Just sync the buffer and give it back
|
/* CPU should not write to
|
||||||
* to the card.
|
* DMA_FROM_DEVICE-mapped area,
|
||||||
|
* so dma_sync_single_for_device() is
|
||||||
|
* not needed here. It would be required
|
||||||
|
* for DMA_BIDIRECTIONAL mapping if
|
||||||
|
* the memory was modified.
|
||||||
*/
|
*/
|
||||||
dma_sync_single_for_device(&cp->dev,
|
|
||||||
cp->rx_dma,
|
|
||||||
cp->rx_len,
|
|
||||||
DMA_FROM_DEVICE);
|
|
||||||
give_rx_buf_to_card(cp);
|
give_rx_buf_to_card(cp);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue