Aaron Williams | b2ea818 | 2020-06-30 12:08:56 +0200 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0+ |
| 2 | /* |
| 3 | * Copyright (C) 2020 Marvell International Ltd. |
| 4 | */ |
| 5 | |
| 6 | #include <cpu_func.h> |
| 7 | |
Stefan Roese | 5e297f8 | 2020-08-24 13:04:41 +0200 | [diff] [blame] | 8 | /* Octeon memory write barrier */ |
| 9 | #define CVMX_SYNCW asm volatile ("syncw\nsyncw\n" : : : "memory") |
| 10 | |
Aaron Williams | b2ea818 | 2020-06-30 12:08:56 +0200 | [diff] [blame] | 11 | void flush_dcache_range(ulong start_addr, ulong stop) |
| 12 | { |
Stefan Roese | 5e297f8 | 2020-08-24 13:04:41 +0200 | [diff] [blame] | 13 | /* Flush all pending writes */ |
| 14 | CVMX_SYNCW; |
Aaron Williams | b2ea818 | 2020-06-30 12:08:56 +0200 | [diff] [blame] | 15 | } |
| 16 | |
| 17 | void flush_cache(ulong start_addr, ulong size) |
| 18 | { |
| 19 | } |
| 20 | |
| 21 | void invalidate_dcache_range(ulong start_addr, ulong stop) |
| 22 | { |
Stefan Roese | 5e297f8 | 2020-08-24 13:04:41 +0200 | [diff] [blame] | 23 | /* Don't need to do anything for OCTEON */ |
Aaron Williams | b2ea818 | 2020-06-30 12:08:56 +0200 | [diff] [blame] | 24 | } |