swiotlb: add the swiotlb initialization function with iotlb memory
This enables the caller to initialize swiotlb with its own iotlb
memory.
See "swiotlb: swiotlb: add swiotlb_tbl_map_single library function" for
full description of patchset.
[v2: changed ..with_tlb to ..with_tbl]
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Tested-by: Albert Herranz <albert_herranz@yahoo.es>
diff --git a/include/linux/swiotlb.h b/include/linux/swiotlb.h
index 81a4e21..b406261 100644
--- a/include/linux/swiotlb.h
+++ b/include/linux/swiotlb.h
@@ -23,6 +23,7 @@
#define IO_TLB_SHIFT 11
extern void swiotlb_init(int verbose);
+extern void swiotlb_init_with_tbl(char *tlb, unsigned long nslabs, int verbose);
extern void
*swiotlb_alloc_coherent(struct device *hwdev, size_t size,