diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2019-09-26 11:22:14 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2019-09-26 11:22:14 -0700 |
commit | ec56103e18c7590303c69329dd4aaadf8a898c19 (patch) | |
tree | 3c41cc3b905661d909f20375094fe07730fcf160 /drivers/xen/swiotlb-xen.c | |
parent | cbafe18c71028d5e0ee1626b4776fea5d5824a78 (diff) | |
parent | a4098bc6eed5e31e0391bcc068e61804c98138df (diff) | |
download | linux-ec56103e18c7590303c69329dd4aaadf8a898c19.tar.bz2 |
Merge tag 'for-linus-5.4-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip
Pull xen update from Juergen Gross:
"Only two small patches this time:
- a small cleanup for swiotlb-xen
- a fix for PCI initialization for some platforms"
* tag 'for-linus-5.4-rc1-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
xen/pci: reserve MCFG areas earlier
swiotlb-xen: Convert to use macro
Diffstat (limited to 'drivers/xen/swiotlb-xen.c')
-rw-r--r-- | drivers/xen/swiotlb-xen.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/xen/swiotlb-xen.c b/drivers/xen/swiotlb-xen.c index 58c9365fa217..bd3a10dfac15 100644 --- a/drivers/xen/swiotlb-xen.c +++ b/drivers/xen/swiotlb-xen.c @@ -39,6 +39,7 @@ #include <asm/xen/page-coherent.h> #include <trace/events/swiotlb.h> +#define MAX_DMA_BITS 32 /* * Used to do a quick range check in swiotlb_tbl_unmap_single and * swiotlb_tbl_sync_single_*, to see if the memory was in fact allocated by this @@ -115,8 +116,6 @@ static int is_xen_swiotlb_buffer(dma_addr_t dma_addr) return 0; } -static int max_dma_bits = 32; - static int xen_swiotlb_fixup(void *buf, size_t size, unsigned long nslabs) { @@ -136,7 +135,7 @@ xen_swiotlb_fixup(void *buf, size_t size, unsigned long nslabs) p + (i << IO_TLB_SHIFT), get_order(slabs << IO_TLB_SHIFT), dma_bits, &dma_handle); - } while (rc && dma_bits++ < max_dma_bits); + } while (rc && dma_bits++ < MAX_DMA_BITS); if (rc) return rc; |