aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/arc/mm/cache.c31
1 files changed, 16 insertions, 15 deletions
diff --git a/arch/arc/mm/cache.c b/arch/arc/mm/cache.c
index 4135abec3fb0..63e6e6504699 100644
--- a/arch/arc/mm/cache.c
+++ b/arch/arc/mm/cache.c
@@ -113,10 +113,24 @@ static void read_decode_cache_bcr_arcv2(int cpu)
113 } 113 }
114 114
115 READ_BCR(ARC_REG_CLUSTER_BCR, cbcr); 115 READ_BCR(ARC_REG_CLUSTER_BCR, cbcr);
116 if (cbcr.c) 116 if (cbcr.c) {
117 ioc_exists = 1; 117 ioc_exists = 1;
118 else 118
119 /*
120 * As for today we don't support both IOC and ZONE_HIGHMEM enabled
121 * simultaneously. This happens because as of today IOC aperture covers
122 * only ZONE_NORMAL (low mem) and any dma transactions outside this
123 * region won't be HW coherent.
124 * If we want to use both IOC and ZONE_HIGHMEM we can use
125 * bounce_buffer to handle dma transactions to HIGHMEM.
126 * Also it is possible to modify dma_direct cache ops or increase IOC
127 * aperture size if we are planning to use HIGHMEM without PAE.
128 */
129 if (IS_ENABLED(CONFIG_HIGHMEM) || is_pae40_enabled())
130 ioc_enable = 0;
131 } else {
119 ioc_enable = 0; 132 ioc_enable = 0;
133 }
120 134
121 /* HS 2.0 didn't have AUX_VOL */ 135 /* HS 2.0 didn't have AUX_VOL */
122 if (cpuinfo_arc700[cpu].core.family > 0x51) { 136 if (cpuinfo_arc700[cpu].core.family > 0x51) {
@@ -1158,19 +1172,6 @@ noinline void __init arc_ioc_setup(void)
1158 if (!ioc_enable) 1172 if (!ioc_enable)
1159 return; 1173 return;
1160 1174
1161 /*
1162 * As for today we don't support both IOC and ZONE_HIGHMEM enabled
1163 * simultaneously. This happens because as of today IOC aperture covers
1164 * only ZONE_NORMAL (low mem) and any dma transactions outside this
1165 * region won't be HW coherent.
1166 * If we want to use both IOC and ZONE_HIGHMEM we can use
1167 * bounce_buffer to handle dma transactions to HIGHMEM.
1168 * Also it is possible to modify dma_direct cache ops or increase IOC
1169 * aperture size if we are planning to use HIGHMEM without PAE.
1170 */
1171 if (IS_ENABLED(CONFIG_HIGHMEM))
1172 panic("IOC and HIGHMEM can't be used simultaneously");
1173
1174 /* Flush + invalidate + disable L1 dcache */ 1175 /* Flush + invalidate + disable L1 dcache */
1175 __dc_disable(); 1176 __dc_disable();
1176 1177