Skip to content

Commit

Permalink
[ARM] fix constant values of MAX_DMA_ADDRESS
Browse files Browse the repository at this point in the history
Since 8d5796d, we have allowed
PAGE_OFFSET to be configurable, so a constant virtual address
for MAX_DMA_ADDRESS is buggy.  It should be defined in terms of
PAGE_OFFSET rather than a constant virtual address.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Russell King authored and Russell King committed Nov 29, 2008
1 parent b9c7802 commit c72e005
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 10 deletions.
2 changes: 1 addition & 1 deletion arch/arm/mach-h720x/include/mach/memory.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,6 @@
* If you set this, you must also set ISA_DMA_THRESHOLD and setup a DMA
* zone if this does not cover all possible RAM.
*/
#define MAX_DMA_ADDRESS 0xd0000000
#define MAX_DMA_ADDRESS (PAGE_OFFSET + SZ_256M)

#endif
8 changes: 0 additions & 8 deletions arch/arm/mach-s3c2410/include/mach/memory.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,4 @@

#define PHYS_OFFSET UL(0x30000000)

/*
* This is the maximum DMA address(physical address) that can be DMAd to.
* Err, no, this is a virtual address. And you must set ISA_DMA_THRESHOLD
* and setup a DMA zone if this restricts the amount of RAM which is
* capable of DMA.
*/
#define MAX_DMA_ADDRESS 0x40000000

#endif
2 changes: 1 addition & 1 deletion arch/arm/mach-shark/include/mach/memory.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ static inline void __arch_adjust_zones(int node, unsigned long *zone_size, unsig
__arch_adjust_zones(node, size, holes)

#define ISA_DMA_THRESHOLD (PHYS_OFFSET + SZ_4M - 1)
#define MAX_DMA_ADDRESS 0xC0400000
#define MAX_DMA_ADDRESS (PAGE_OFFSET + SZ_4M)

#endif

Expand Down

0 comments on commit c72e005

Please sign in to comment.