Commit 08d90f46 authored by Alexander Gordeev's avatar Alexander Gordeev Committed by Heiko Carstens

s390/mm: fix MAX_DMA_ADDRESS physical vs virtual confusion

MAX_DMA_ADDRESS is defined and treated as a physical address,
whereas it should be virtual.
Reviewed-by: default avatarHeiko Carstens <hca@linux.ibm.com>
Signed-off-by: default avatarAlexander Gordeev <agordeev@linux.ibm.com>
Signed-off-by: default avatarHeiko Carstens <hca@linux.ibm.com>
parent acf00b5e
...@@ -9,6 +9,6 @@ ...@@ -9,6 +9,6 @@
* to DMA. It _is_ used for the s390 memory zone split at 2GB caused * to DMA. It _is_ used for the s390 memory zone split at 2GB caused
* by the 31 bit heritage. * by the 31 bit heritage.
*/ */
#define MAX_DMA_ADDRESS 0x80000000 #define MAX_DMA_ADDRESS __va(0x80000000)
#endif /* _ASM_S390_DMA_H */ #endif /* _ASM_S390_DMA_H */
...@@ -98,7 +98,7 @@ void __init paging_init(void) ...@@ -98,7 +98,7 @@ void __init paging_init(void)
sparse_init(); sparse_init();
zone_dma_bits = 31; zone_dma_bits = 31;
memset(max_zone_pfns, 0, sizeof(max_zone_pfns)); memset(max_zone_pfns, 0, sizeof(max_zone_pfns));
max_zone_pfns[ZONE_DMA] = PFN_DOWN(MAX_DMA_ADDRESS); max_zone_pfns[ZONE_DMA] = virt_to_pfn(MAX_DMA_ADDRESS);
max_zone_pfns[ZONE_NORMAL] = max_low_pfn; max_zone_pfns[ZONE_NORMAL] = max_low_pfn;
free_area_init(max_zone_pfns); free_area_init(max_zone_pfns);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment