NVIDIA DRIVE OS Linux API Reference

5.1.3.0 Release

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
cache.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2010-2017, NVIDIA CORPORATION. All rights reserved.
3  *
4  * NVIDIA CORPORATION and its licensors retain all intellectual property
5  * and proprietary rights in and to this software, related documentation
6  * and any modifications thereto. Any use, reproduction, disclosure or
7  * distribution of this software and related documentation without an express
8  * license agreement from NVIDIA CORPORATION is strictly prohibited.
9  */
10 
17 #ifndef INCLUDED_CACHE_H
18 #define INCLUDED_CACHE_H
19 
20 #define CACHE_WRITEBACK_INVALIDATE (1)
21 #define CACHE_WRITEBACK (2)
22 #define CACHE_INVALIDATE (3)
23 
24 #define DO_NOT_DISABLE_CACHE (0)
25 #define DISABLE_CACHE (1)
26 
27 #ifndef __ASSEMBLY__
28 
29 #include <nvcommon.h>
30 
97 void QbDataCacheWritebackInvalidateRange(const void *const pStart, NvU32 TotalLength);
98 
105 void QbDataCacheWritebackRange(const void *const pStart, NvU32 TotalLength);
106 
111 void QbDataCacheWriteback(void);
112 
117 
122 
130 void QbDataCacheInvalidateRange(const void *const pStart, NvU32 TotalLength);
131 
132 
136 void QbInstrCacheInvalidate(void);
137 
145 void QbInstrCacheInvalidateRange(const void *const pStart, NvU32 TotalLength);
146 
151 void QbFlushWriteCombineBuffer(void);
152 
158 void QbEnableDataCache(void);
159 
163 void QbDisableDataCache(void);
164 
165 /*
166  * Invalidate any stale entries in instruction cache.
167  * Enable instruction cache.
168  */
169 void QbInitInstructionCache(void);
170 
177 void QbEnableInstructionCache(void);
178 
182 void QbDisableInstructionCache(void);
183 
187 void QbInvalidateTLB(void);
188 
189 /*
190  * Invalidate instruction and data caches.
191  * Invalidate TLB.
192  */
193 void QbInvalidateCaches(void);
194 
195 #endif // !__ASSEMBLY__
196 
197 #endif // INCLUDED_CACHE_H
198 
void QbEnableInstructionCache(void)
IMPORTANT: This function gets called very early when bss is not initialized.
void QbInvalidateCaches(void)
void QbDataCacheWritebackInvalidate(void)
Writes back the entire data cache to main memory.
void QbInstrCacheInvalidate(void)
Invalidates instruction cache.
void QbDataCacheWriteback(void)
Writes back the entire data cache to main memory, then invalidates the cache.
void QbEnableDataCache(void)
QbEnableDataCache()
void QbDataCacheWritebackRange(const void *const pStart, NvU32 TotalLength)
Writes back a region of the data cache to main memory.
void QbDisableDataCache(void)
Disables data caches.
void QbDataCacheWritebackInvalidateRange(const void *const pStart, NvU32 TotalLength)
Writes back a region of the data cache to main memory, then invalidates the region.
void QbInstrCacheInvalidateRange(const void *const pStart, NvU32 TotalLength)
Invalidates a region of the instruction cache.
void QbFlushWriteCombineBuffer(void)
Drains the write bufffer.
void QbInvalidateTLB(void)
Invalidates TLB for EL2.
void QbDataCacheDisableWritebackInvalidate(void)
Disables data cache.
void QbInitInstructionCache(void)
void QbDataCacheInvalidateRange(const void *const pStart, NvU32 TotalLength)
Invalidates a region of the data cache.
void QbDisableInstructionCache(void)
Disables instruction caches.