函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\kernel\aperture_64.c Create Date:2022-07-27 09:52:22
Last Modify:2020-03-17 10:38:51 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:Read a standard AGPv3 bridge header

函数原型:static unsigned int __init read_agp(int bus, int slot, int func, int cap, unsigned int *order)

返回类型:unsigned int

参数:

类型参数名称
intbus
intslot
intfunc
intcap
unsigned int *order
167  打印信息("pci 0000:%02x:%02x:%02x: AGP bridge\n", bus, slot, func)
168  apsizereg等于read_pci_config_16(bus, slot, func, cap + 0x14)
169  如果apsizereg恒等于0xffffffff则
170  打印错误信息("pci 0000:%02x:%02x.%d: APSIZE unreadable\n", bus, slot, func)
172  返回:0
176  old_order等于order
178  apsize等于apsizereg按位与0xfff
180  如果apsize按位与0xff则apsize或等于0xf00
182  nbits等于hweight16(apsize)
183  order等于7减nbits
184  如果((int) * order < 0)则order等于0
187  aper_low等于Direct PCI access. This is used for PCI accesses in early boot beforethe PCI subsystem works.
188  aper_hi等于Direct PCI access. This is used for PCI accesses in early boot beforethe PCI subsystem works.
189  aper等于aper_low按位与1左移22位的值减1的差的反按位或aper_hi左移32位
195  打印信息("pci 0000:%02x:%02x.%d: AGP aperture [bus addr %#010Lx-%#010Lx] (old size %uMB)\n", bus, slot, func, aper, aper + (32ULL << (old_order + 20)) - 1, 32 << old_order)
198  如果aper加32ULL左移20加order位的值大于0x100000000ULL则
199  打印信息("pci 0000:%02x:%02x.%d: AGP aperture size %uMB (APSIZE %#x) is not right, using settings from NB\n", bus, slot, func, 32 << * order, apsizereg)
201  order等于old_order
204  打印信息("pci 0000:%02x:%02x.%d: AGP aperture [bus addr %#010Lx-%#010Lx] (%uMB, APSIZE %#x)\n", bus, slot, func, aper, aper + (32ULL << ( * order + 20)) - 1, 32 << * order, apsizereg)
208  如果非aperture_valid(aper, (32 * 1024 * 1024) << * order, 32 << 20)则返回:0
210  返回:aper
调用者
名称描述
search_agp_bridgeLook for an AGP bridge