linuxkpi: Add for_each_sgtable_{sg,page}
Needed by drm-kmod. Reviewed by: bz Obtained from: drm-kmod Sponsored by: Beckhoff Automation GmbH & Co. KG Differential Revision: https://reviews.freebsd.org/D36098
This commit is contained in:
parent
c6890399fc
commit
4370e9f1cf
@ -99,6 +99,12 @@ struct sg_dma_page_iter {
|
||||
#define for_each_sg(sglist, sg, sgmax, iter) \
|
||||
for (iter = 0, sg = (sglist); iter < (sgmax); iter++, sg = sg_next(sg))
|
||||
|
||||
#define for_each_sgtable_sg(sgt, sg, i) \
|
||||
for_each_sg((sgt)->sgl, sg, (sgt)->orig_nents, i)
|
||||
|
||||
#define for_each_sgtable_page(sgt, iter, pgoffset) \
|
||||
for_each_sg_page((sgt)->sgl, iter, (sgt)->orig_nents, pgoffset)
|
||||
|
||||
#define for_each_sgtable_dma_sg(sgt, sg, iter) \
|
||||
for_each_sg((sgt)->sgl, sg, (sgt)->nents, iter)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user