mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-29 22:26:44 +07:00
Documentation: update scatterlist struct description in DMA-API-HOWTO
Now we have <asm-generic/scatterlist.h>. Architectures should use it instead of inventing the own scatterlist struct. Let's update the description. Signed-off-by: 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
7cdcc8e476
commit
b02de87161
@ -703,19 +703,10 @@ to "Closing".
|
|||||||
|
|
||||||
1) Struct scatterlist requirements.
|
1) Struct scatterlist requirements.
|
||||||
|
|
||||||
Struct scatterlist must contain, at a minimum, the following
|
Don't invent the architecture specific struct scatterlist; just use
|
||||||
members:
|
<asm-generic/scatterlist.h>. You need to enable
|
||||||
|
CONFIG_NEED_SG_DMA_LENGTH if the architecture supports IOMMUs
|
||||||
struct page *page;
|
(including software IOMMU).
|
||||||
unsigned int offset;
|
|
||||||
unsigned int length;
|
|
||||||
|
|
||||||
The base address is specified by a "page+offset" pair.
|
|
||||||
|
|
||||||
Previous versions of struct scatterlist contained a "void *address"
|
|
||||||
field that was sometimes used instead of page+offset. As of Linux
|
|
||||||
2.5., page+offset is always used, and the "address" field has been
|
|
||||||
deleted.
|
|
||||||
|
|
||||||
2) More to come...
|
2) More to come...
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user