Yash Shah | 087958a | 2020-02-20 10:45:18 +0530 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0 */ |
Zong Li | 38f5bd2 | 2020-08-31 15:33:50 +0800 | [diff] [blame] | 2 | /* |
| 3 | * Copyright (C) 2020 SiFive |
| 4 | */ |
Yash Shah | 087958a | 2020-02-20 10:45:18 +0530 | [diff] [blame] | 5 | |
| 6 | #ifndef _ASM_RISCV_CACHEINFO_H |
| 7 | #define _ASM_RISCV_CACHEINFO_H |
| 8 | |
| 9 | #include <linux/cacheinfo.h> |
| 10 | |
| 11 | struct riscv_cacheinfo_ops { |
| 12 | const struct attribute_group * (*get_priv_group)(struct cacheinfo |
| 13 | *this_leaf); |
| 14 | }; |
| 15 | |
| 16 | void riscv_set_cacheinfo_ops(struct riscv_cacheinfo_ops *ops); |
Zong Li | 38f5bd2 | 2020-08-31 15:33:50 +0800 | [diff] [blame] | 17 | uintptr_t get_cache_size(u32 level, enum cache_type type); |
| 18 | uintptr_t get_cache_geometry(u32 level, enum cache_type type); |
Yash Shah | 087958a | 2020-02-20 10:45:18 +0530 | [diff] [blame] | 19 | |
| 20 | #endif /* _ASM_RISCV_CACHEINFO_H */ |