Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\kernel\cpu\mtrr\cyrix.c Create Date:2022-07-28 08:07:00
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:cyrix_set_arr

Proto:static void cyrix_set_arr(unsigned int reg, unsigned long base, unsigned long size, mtrr_type type)

Type:void

Parameter:

TypeParameterName
unsigned intreg
unsigned longbase
unsigned longsize
mtrr_typetype
184  arr = CX86_ARR_BASE + (reg << 1) + reg
187  If reg >= 7 Then size >>= 6
190  size &= 0x7fff
191  When size cycle If reg < 7 Then
197  arr_type = 1
198  Break
199  Case type == MTRR_TYPE_WRCOMB
200  arr_type = 9
201  Break
202  Case type == #define MTRR_TYPE_ 3
203  arr_type = 24
204  Break
205  Default
206  arr_type = 8
207  Break
209  Else
212  arr_type = 0
213  Break
214  Case type == MTRR_TYPE_WRCOMB
215  arr_type = 8
216  Break
217  Case type == #define MTRR_TYPE_ 3
218  arr_type = 25
219  Break
220  Default
221  arr_type = 9
222  Break
226  Since we are disabling the cache don't allow any interrupts,* they would run extremely slow and would only increase the pain.* The caller must ensure that local interrupts are disabled and* are reenabled after post_set() has been called.
228  base <<= PAGE_SHIFT determines the page size
229  setCx86(arr + 0, ((unsignedchar * ) & base)[3])
230  setCx86(arr + 1, ((unsignedchar * ) & base)[2])
231  setCx86(arr + 2, (((unsignedchar * ) & base)[1]) | arr_size)
232  setCx86(CX86_RCR_BASE + reg, arr_type)
234  post_set()
Caller
NameDescribe
cyrix_set_all