diff options
| author | Richard Henderson <rth@dorothy.sfbay.redhat.com> | 2002-11-03 03:32:53 -0800 |
|---|---|---|
| committer | Richard Henderson <rth@dorothy.sfbay.redhat.com> | 2002-11-03 03:32:53 -0800 |
| commit | 9a43e25fa9d9c80c30a2433078ca92fbfa7734fd (patch) | |
| tree | e3686917be02f95fefafe4f3f0ff17580eee9060 /include | |
| parent | 37e093c18a2e7bb5253aff6d42bc91f3a1380f3d (diff) | |
| parent | 48e7ce94218314de565745911b2e1641c46fa5d3 (diff) | |
Merge with mainline.
Diffstat (limited to 'include')
| -rw-r--r-- | include/asm-alpha/dma.h | 33 | ||||
| -rw-r--r-- | include/asm-alpha/floppy.h | 4 | ||||
| -rw-r--r-- | include/asm-alpha/machvec.h | 2 | ||||
| -rw-r--r-- | include/linux/pci.h | 6 |
4 files changed, 27 insertions, 18 deletions
diff --git a/include/asm-alpha/dma.h b/include/asm-alpha/dma.h index 97daf7d786aa..dc46ba5b4f1c 100644 --- a/include/asm-alpha/dma.h +++ b/include/asm-alpha/dma.h @@ -85,44 +85,47 @@ /* The maximum address for ISA DMA transfer on Alpha XL, due to an hardware SIO limitation, is 64MB. */ -#define ALPHA_XL_MAX_DMA_ADDRESS (IDENT_ADDR+0x04000000UL) +#define ALPHA_XL_MAX_ISA_DMA_ADDRESS 0x04000000UL -/* The maximum address for ISA DMA transfer on RUFFIAN and NAUTILUS, +/* The maximum address for ISA DMA transfer on RUFFIAN, due to an hardware SIO limitation, is 16MB. */ -#define ALPHA_RUFFIAN_MAX_DMA_ADDRESS (IDENT_ADDR+0x01000000UL) -#define ALPHA_NAUTILUS_MAX_DMA_ADDRESS (IDENT_ADDR+0x01000000UL) +#define ALPHA_RUFFIAN_MAX_ISA_DMA_ADDRESS 0x01000000UL /* The maximum address for ISA DMA transfer on SABLE, and some ALCORs, due to an hardware SIO chip limitation, is 2GB. */ -#define ALPHA_SABLE_MAX_DMA_ADDRESS (IDENT_ADDR+0x80000000UL) -#define ALPHA_ALCOR_MAX_DMA_ADDRESS (IDENT_ADDR+0x80000000UL) +#define ALPHA_SABLE_MAX_ISA_DMA_ADDRESS 0x80000000UL +#define ALPHA_ALCOR_MAX_ISA_DMA_ADDRESS 0x80000000UL /* Maximum address for all the others is the complete 32-bit bus address space. */ -#define ALPHA_MAX_DMA_ADDRESS (IDENT_ADDR+0x100000000UL) +#define ALPHA_MAX_ISA_DMA_ADDRESS 0x100000000UL #ifdef CONFIG_ALPHA_GENERIC -# define MAX_DMA_ADDRESS (alpha_mv.max_dma_address) +# define MAX_ISA_DMA_ADDRESS (alpha_mv.max_isa_dma_address) #else # if defined(CONFIG_ALPHA_XL) -# define MAX_DMA_ADDRESS ALPHA_XL_MAX_DMA_ADDRESS +# define MAX_ISA_DMA_ADDRESS ALPHA_XL_MAX_ISA_DMA_ADDRESS # elif defined(CONFIG_ALPHA_RUFFIAN) -# define MAX_DMA_ADDRESS ALPHA_RUFFIAN_MAX_DMA_ADDRESS -# elif defined(CONFIG_ALPHA_NAUTILUS) -# define MAX_DMA_ADDRESS ALPHA_NAUTILUS_MAX_DMA_ADDRESS +# define MAX_ISA_DMA_ADDRESS ALPHA_RUFFIAN_MAX_ISA_DMA_ADDRESS # elif defined(CONFIG_ALPHA_SABLE) -# define MAX_DMA_ADDRESS ALPHA_SABLE_MAX_DMA_ADDRESS +# define MAX_ISA_DMA_ADDRESS ALPHA_SABLE_MAX_DMA_ISA_ADDRESS # elif defined(CONFIG_ALPHA_ALCOR) -# define MAX_DMA_ADDRESS ALPHA_ALCOR_MAX_DMA_ADDRESS +# define MAX_ISA_DMA_ADDRESS ALPHA_ALCOR_MAX_DMA_ISA_ADDRESS # else -# define MAX_DMA_ADDRESS ALPHA_MAX_DMA_ADDRESS +# define MAX_ISA_DMA_ADDRESS ALPHA_MAX_ISA_DMA_ADDRESS # endif #endif +/* If we have the iommu, we don't have any address limitations on DMA. + Otherwise (Nautilus, RX164), we have to have 0-16 Mb DMA zone + like i386. */ +#define MAX_DMA_ADDRESS (alpha_mv.mv_pci_tbi ? \ + ~0UL : IDENT_ADDR + 0x01000000) + /* 8237 DMA controllers */ #define IO_DMA1_BASE 0x00 /* 8 bit slave DMA, channels 0..3 */ #define IO_DMA2_BASE 0xC0 /* 16 bit master DMA, ch 4(=slave input)..7 */ diff --git a/include/asm-alpha/floppy.h b/include/asm-alpha/floppy.h index 88049a927ddd..db527586c23f 100644 --- a/include/asm-alpha/floppy.h +++ b/include/asm-alpha/floppy.h @@ -51,12 +51,12 @@ alpha_fd_dma_setup(char *addr, unsigned long size, int mode, int io) if (bus_addr && (addr != prev_addr || size != prev_size || dir != prev_dir)) { /* different from last time -- unmap prev */ - pci_unmap_single(NULL, bus_addr, prev_size, prev_dir); + pci_unmap_single(isa_bridge, bus_addr, prev_size, prev_dir); bus_addr = 0; } if (!bus_addr) /* need to map it */ - bus_addr = pci_map_single(NULL, addr, size, dir); + bus_addr = pci_map_single(isa_bridge, addr, size, dir); /* remember this one as prev */ prev_addr = addr; diff --git a/include/asm-alpha/machvec.h b/include/asm-alpha/machvec.h index ca6bbf25cb12..5becb8ef34eb 100644 --- a/include/asm-alpha/machvec.h +++ b/include/asm-alpha/machvec.h @@ -34,7 +34,7 @@ struct alpha_machine_vector int nr_irqs; int rtc_port; int max_asn; - unsigned long max_dma_address; + unsigned long max_isa_dma_address; unsigned long irq_probe_mask; unsigned long iack_sc; unsigned long min_io_address; diff --git a/include/linux/pci.h b/include/linux/pci.h index 0d3d8f622b26..b49dd6f113a7 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -643,6 +643,10 @@ void pci_pool_destroy (struct pci_pool *pool); void *pci_pool_alloc (struct pci_pool *pool, int flags, dma_addr_t *handle); void pci_pool_free (struct pci_pool *pool, void *vaddr, dma_addr_t addr); +#if defined(CONFIG_ISA) || defined(CONFIG_EISA) +extern struct pci_dev *isa_bridge; +#endif + #endif /* CONFIG_PCI */ /* Include architecture-dependent settings and functions */ @@ -703,6 +707,8 @@ static inline int pci_enable_wake(struct pci_dev *dev, u32 state, int enable) { #define pci_for_each_dev(dev) \ for(dev = NULL; 0; ) +#define isa_bridge ((struct pci_dev *)NULL) + #else /* |
