WO2017181851A1 - 一种bios启动方法及装置 - Google Patents

一种bios启动方法及装置 Download PDF

Info

Publication number
WO2017181851A1
WO2017181851A1 PCT/CN2017/079627 CN2017079627W WO2017181851A1 WO 2017181851 A1 WO2017181851 A1 WO 2017181851A1 CN 2017079627 W CN2017079627 W CN 2017079627W WO 2017181851 A1 WO2017181851 A1 WO 2017181851A1
Authority
WO
WIPO (PCT)
Prior art keywords
node
address
space
local
access
Prior art date
Application number
PCT/CN2017/079627
Other languages
English (en)
French (fr)
Inventor
干耶卒
仇连根
李羿
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP17785336.3A priority Critical patent/EP3438816B1/en
Publication of WO2017181851A1 publication Critical patent/WO2017181851A1/zh
Priority to US16/165,398 priority patent/US10719333B2/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44505Configuring for program initiating, e.g. using registry, configuration files
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/0223User address space allocation, e.g. contiguous or non contiguous base addressing
    • G06F12/023Free address space management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F15/00Digital computers in general; Data processing equipment in general
    • G06F15/16Combinations of two or more digital computers each having at least an arithmetic unit, a program unit and a register, e.g. for a simultaneous processing of several programs
    • G06F15/177Initialisation or configuration control
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping
    • G06F9/4403Processor initialisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping
    • G06F9/4405Initialisation of multiprocessor systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping
    • G06F9/4411Configuring for operating with peripheral devices; Loading of device drivers
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/10Providing a specific technical effect
    • G06F2212/1041Resource optimization
    • G06F2212/1044Space efficiency improvement

Definitions

  • the present application relates to the field of computers, and in particular, to a basic input/output system (BIOS) starting method and apparatus.
  • BIOS basic input/output system
  • CC-NUMA Coherence Non-Uniform Memory Access
  • a large-scale CC-NUMA system is generally interconnected by a plurality of separate server boards (node boards) through a Cache Coherence interconnect network to form a large server running only one operating system.
  • large-scale x86 CC-NUMA multi-channel systems usually start with their own BIOS based on 2-way or 4-way LUNs.
  • BIOS startup process the memory is uniformly addressed to configure the address space of the global system.
  • each node is incorporated into a BIOS process for management and startup, and the BIOS is provided to an operating system as a complete multi-way system.
  • the embodiment of the present application provides a BIOS startup method and device, which realizes that the BIOS startup does not affect the available space of the MMIO space and the available memory space in the lower address on the premise of the expansion of the CPU included in the large-scale CC-NUMA system.
  • a BIOS startup method is provided, which is applied to a local node, where the local node is a primary node or a secondary node in a large-scale CC-NUMA system, and the CC-NUMA system includes a primary node and at least one auxiliary node.
  • the method includes:
  • a plurality of nodes are included in a large-scale CC-NUMA system, one of the plurality of nodes is selected as a master node, and the remaining nodes are auxiliary nodes.
  • a secondary node may also be referred to as a secondary node or a non-primary node, which is an alternative concept in this application.
  • MMCFGL The storage space in which the MMCFG space is addressed below the first address
  • MMCFGH The storage space addressed above the first address
  • allocating the local MMCFG space of the node and the address of the MMCFG space in the global access address of the system can be implemented by using a configuration register.
  • the node can allocate a part of space as a local MMCFG space of a node by configuring the MMCFG_Rule (memory mapping configuration space rule) register, and configure MMCFG_Target_LIST (memory) in the space below the first address of the local node.
  • the mapping configuration space target list) register sets the local MMCFG space in the space below the first address configured through the MMCFG_Rule register to the local MMCFG space of the node.
  • configuring the MMCFG_Target_LIST register can be used to set which node of the allocated local MMCFG space corresponds to, which is equivalent to which local MMCFG space is allocated.
  • the node can configure the DRAM Rule (memory addressing rule) register to perform unified memory addressing of the system, and allocate a part of space as the address of the MMCFG space of a node in the global access address of the system, by configuring INTERLEAVE_LIST (memory interleaving)
  • the target list) register sets the address in the system's global access address configured through the DRAM Rule register to the address of the node's MMCFG space in the system's global access address.
  • each node included in the large-scale CC-NUMA system includes at least one Central Processing Unit (CPU) in the MMCFG space of one node (including the local MMCFG space or the global access address of the MMCFG space in the system) In the address), the MMCFG space of each CPU is connected in sequence and is not repeated, and the first address of the MMCFG space of one CPU is the tail address of the MMCFG space of another CPU.
  • CPU Central Processing Unit
  • the space can be allocated as much as possible in the address in the global access address of the system to meet the requirements of the peripheral device of the node.
  • the local node completes the memory initialization by allocating the local MMCFG in the space below the first address of the local access address, and when the system is uniformly addressed in the memory, The MMCFG space of all the nodes is moved at the position of the address in the global access address of the system, and the space below the first address is moved to the space above the first address and can be accessed in the second access mode.
  • the CPU is guaranteed to still be able to access the address of the MMCFG space in the system's global access address.
  • the space saved by the move below the first address can be reserved for devices that can only be used in these spaces (for example, leaving more MMIO space for PCIe cards that can only be accessed under 4GB) , leaving more available memory space for the system to use), even if the number of CPUs included in the CC-NUMA system is constantly expanding, the address of the MMCFG space in the system's global access address may not occupy the space below the first address, thus being able to support More PCIE devices, therefore, under the premise of the expansion of the number of CPUs included in the large-scale CC-NUMA system, the BIOS boot does not affect the available space of the MMIO space and the available memory space in the lower address, which improves the large-scale CC-NUMA system PCIE device and operating system compatibility.
  • the first address can be 4 GB.
  • the first access mode may be a 32-bit mode in an x86 system, in which the maximum address that can be accessed is 4 GB.
  • the address of the MMCFG space of the node in the global access address of the system needs to be allocated to the space where the global access address is above the first address and can be accessed in the second access mode. And currently in the first access mode, therefore, this node has no
  • the method accesses the MMCFG space of the node, and the master node can reserve its local MMCFG. All nodes in the system access the MMCFG space of the master node to perform unified memory addressing of the system, and respectively allocate the MMCFG space of each node in the global system. Access the address in the address.
  • the method may further include:
  • the local MMCFG space of the primary node is reserved for each node in the system to perform system memory unified addressing to allocate the address of each node's MMCFG space in the system's global access address.
  • the local MMCFG space of the primary node below the reserved first address can be used for each node in the system to perform unified memory addressing of the system.
  • the MMCFG space of each node is in the global access address of the system.
  • the address can also be used when some drivers want to access some hardware device configuration registers in the first access mode and can only access the space below the first address to improve system compatibility when accessing MMCFG.
  • the method may further include:
  • a page table is configured, where the page table points to the node that is accessible by the node in the second access mode and cannot be accessed by the node in the first access mode.
  • the method may further include:
  • the page table may be configured in the storage space below the first address, the page The table points to an address space that the node can access in the second access mode and cannot be accessed by the node in the first access mode, and the node can access the MMCFG above the allocated first address by accessing the configured page table. space.
  • the specific content of the page table and the specific location of the page table in the storage space below the first address may be set according to actual requirements, which is not specifically limited in this application.
  • accessing the MMCFG space of the node through the page table in the address space above the first address in the global access address of the system belongs to the protection scope of the present application.
  • the addresses of the MMCFG space of each node in the CC-NUMA system in the global access address of the system do not overlap each other.
  • each node in the CC-NUMA system in the global access address of the system is the address that each node needs to access when accessing the peripheral device, when they do not overlap each other, each node can interfere with each other when accessing the peripheral device. , improve system performance.
  • the address of the MMCFG space of each node in the CC-NUMA system is consecutive in the global access address of the system; wherein the first address of the address of the MMCFG space of one node in the global access address of the system is the MMCFG space of the other node The tail address of the address in the global access address of the system.
  • each node can access the MMCFG space of other nodes, and the nodes are connected to each other, and the access is more regular, even if For unified access.
  • the node is a master node and interacts with at least one other node in the system to complete the node merging of the system to form a complete system, the following process can be implemented:
  • the notification message is used to instruct the auxiliary node to send its own system information to the primary node;
  • Each system message sent by each auxiliary node is received separately, and the node merging of the system is completed to form a complete system.
  • the sixth possible implementation manner of the first aspect provides a specific method for the master node to complete the node merging of the system to form a complete system, so as to achieve the effects of the above various possible implementation manners.
  • node is a secondary node, interacting with at least one other node in the system to complete the node merging of the system to form a complete system, which can be implemented by the following process:
  • the system message is sent to the master node, and the system message is used by the master node to complete the node merging of the system to form a complete system.
  • the seventh possible implementation manner of the first aspect provides a specific method for the master node to complete the node merging of the system to form a complete system, so as to achieve the effects of the above various possible implementation manners.
  • interaction with at least one other node in the system completes the node merging of the system to form a complete system.
  • the node performs BIOS merge after the last access to the CPU register to form a complete system, so that the memory initialization of each node is independent of each other, that is, each node is in parallel. Memory initialization, reduced startup time.
  • a BIOS boot device where the boot device is included in a node, the local node is a master node or an affiliate node in a large-scale CC-NUMA system, and the CC-NUMA system includes a master node. And at least one auxiliary node, the starting device includes:
  • a mode unit configured to control the system to enter a first access mode, where, in the first access mode, a maximum address accessed by the local node is a first address;
  • An allocation unit configured to allocate, in a first access mode, a local memory mapping configuration MMCFG space of the local node in a space where the local access address of the local node is lower than the first address;
  • An initialization unit configured to perform memory initialization by accessing a local MMCFG space of the local node allocated by the allocation unit;
  • the allocating unit is further configured to: after the initialization unit completes the memory initialization, perform memory unified addressing of the system, and allocate an address of the MMCFG space of the local node in a global access address of the system; All or part of the MMCFG space of the local node is in a space where the global access address is above the first address and can be accessed in the second access mode;
  • the allocating unit is further configured to allocate a memory mapped input and output MMIO space to the local node in a global access address of the system;
  • a merging unit configured to interact with at least one other node in the system to complete node merging of the system to form a complete system
  • the mode unit is further configured to control the system to enter a second access mode from the first access mode, wherein, in the second access mode, an address space accessible by the local node is greater than The address space that the node can access in the first access mode.
  • the first address is 4 GB.
  • the allocation unit is specifically configured to:
  • the memory of the system is uniformly addressed by accessing the local MMCFG space of the primary node, and the address of the MMCFG space of the local node in the global access address of the system is allocated.
  • the device also includes:
  • a configuration unit configured to: before the mode unit controls the system to enter the second access mode from the first access mode, in a space where the local access address of the local node is below the first address, a page table, where the page table points to an address space that is accessible by the local node and cannot be accessed by the local node in the first access mode in the second access mode;
  • An access unit configured to: after the mode unit controls the system to enter the second access mode from the first access mode, access the MMCFG space of the local node according to the page table configured by the configuration unit, The address in the system's global access address.
  • the addresses of the MMCFG space of each node in the CC-NUMA system in the global access address of the system do not overlap each other.
  • the address of the MMCFG space of each node in the CC-NUMA system is consecutive in the global access address of the system; wherein the first address of the address of the MMCFG space of one node in the global access address of the system is another
  • the MMCFG space of the node is the tail address of the address in the global access address of the system.
  • the merging unit is specifically configured to:
  • the notification message is used to indicate that the auxiliary node sends its own system information to the primary node;
  • the merging unit is specifically configured to:
  • the system message is used by the master node to complete node merging of the system to form a complete system.
  • the merging unit is specifically configured to:
  • interaction with at least one other node in the system completes the node merging of the system to form a complete system.
  • the apparatus provided by the second aspect or the second aspect of the second aspect which is used to implement the BIOS startup method in the first aspect or the first implementation manner of the first aspect, can achieve the same technical effect.
  • a third aspect provides a BIOS booting apparatus, where the booting apparatus is included in a node, the local node is a master node or an auxiliary node in a large-scale CC-NUMA system, and the CC-NUMA system includes a master node. And at least one auxiliary node, the starting device includes:
  • a processor configured to control the system to enter a first access mode, wherein, in the first access mode, a maximum address accessed by the local node is a first address; Perform the following steps in an access mode:
  • the first address is 4 GB.
  • the processor is specifically configured to:
  • the memory of the system is uniformly addressed by accessing the local MMCFG space of the primary node, and the address of the MMCFG space of the local node in the global access address of the system is allocated.
  • the processor is further used to :
  • a page table Before entering the second access mode from the first access mode, in a space where the local access address of the local node is below the first address, a page table is configured, and the page table points to the first An address space accessible by the local node in the second access mode and not accessible by the local node in the first access mode;
  • the address of the MMCFG space of the local node in the global access address of the system is accessed according to the page table configured by the configuration unit.
  • the addresses of the MMCFG space of each node in the CC-NUMA system in the global access address of the system do not overlap each other.
  • the address of the MMCFG space of each node in the CC-NUMA system is consecutive in the global access address of the system; wherein the global access of the MMCFG space of one node in the system
  • the first address of the address in the address is the end address of the address of the MMCFG space of the other node in the global access address of the system.
  • the processor is specifically configured to:
  • the notification message is used to indicate that the auxiliary node sends its own system information to the primary node;
  • the processor is specifically configured to:
  • the system message is used by the master node to complete node merging of the system to form a complete system.
  • the processor is specifically configured to:
  • interaction with at least one other node in the system completes the node merging of the system to form a complete system.
  • BIOS booting apparatus provided in the second aspect or the third aspect, or any one of the foregoing possible implementation manners, is used to implement the BIOS booting method in the first aspect or the first aspect of the possible implementation, and the same can be achieved.
  • Technical effects are used to implement the BIOS booting method in the first aspect or the first aspect of the possible implementation, and the same can be achieved.
  • the BIOS startup method and device provided by the embodiment of the present application are applied to a primary node or a secondary node in a large-scale CC-NUMA system.
  • the local access address of the local node at the local node is below the first address.
  • the local MMCFG is allocated in the space to complete the memory initialization.
  • some or all of the MMCFG space of the local node is moved at the address of the global access address of the system, and the original address is below the original address.
  • the space is moved to the space above the first address and can be accessed in the second access mode, so that in the second access mode, the CPU is still able to access the address of the MMCFG space in the global access address of the system.
  • the space saved by the move below the first address can be reserved for devices that can only be used in these spaces (for example, leaving more MMIO space for PCIE cards that can only be accessed under 4GB) , leaving more available memory space for the system to use), even if the number of CPUs included in the CC-NUMA system is constantly expanding, the address of the MMCFG space in the system's global access address may not occupy the space below the first address, thus being able to support More PCIE devices, therefore, under the premise of the expansion of the number of CPUs included in the large-scale CC-NUMA system, the BIOS boot does not affect the available space of the MMIO space and the available memory space in the lower address, and improves The compatibility of large-scale CC-NUMA system PCIE devices and operating systems.
  • Figure 1 is a diagram of a large-scale CC-NUMA system architecture
  • FIG. 2 is a schematic diagram of a addressing scheme of a BIOS startup phase provided by the prior art
  • FIG. 3 is a structural diagram of a BIOS boot device according to an embodiment of the present application.
  • FIG. 4 is a schematic flowchart of a BIOS startup method according to an embodiment of the present disclosure
  • FIG. 5 is a schematic diagram of a space addressing of an MMCFG according to an embodiment of the present application.
  • FIG. 6 is a schematic diagram of another MMCFG space addressing according to an embodiment of the present application.
  • FIG. 7 is a schematic diagram of MMIO space addressing according to an embodiment of the present application.
  • FIG. 8 is a schematic diagram of a addressing scheme of a BIOS startup phase according to an embodiment of the present disclosure
  • FIG. 9 is a structural diagram of another BIOS boot device according to an embodiment of the present application.
  • FIG. 10 is a structural diagram of still another BIOS startup apparatus according to an embodiment of the present application.
  • FIG. 1 shows the architecture of a large-scale CC-NUMA system, including nodes 1 through n, each consisting of a processor, memory, peripherals, and other modules. The nodes are connected to each other through a high-speed interconnect to form a complete system. .
  • Each node may include one or more processors (such as x86 CPUs), each CPU corresponding to one or more physical memories, and physical memory as one of the processor devices is performed together with other devices (such as registers, peripheral devices). Unified addressing, each subsequent CPU accesses its corresponding physical memory through the addressed address. How to perform unified addressing and access is a prior art, and this embodiment does not specifically describe. It should be noted that, in FIG. 1, for convenience of illustration, one or more physical memories corresponding to each CPU are not drawn, and only one memory module is used to simply represent each physical memory in the node.
  • the processor in the node realizes various applications of the large-scale CC-NUMA system by connecting with peripheral devices (for example, PCIE devices widely used at present).
  • peripheral devices for example, PCIE devices widely used at present.
  • the number of PCIE devices that the processor can support depends on the size of the MMIO space of the processor.
  • the PCIE device has a configuration space that saves the basic characteristics of the device. Through the configuration of the configuration space, the function of setting the address allocation of the storage space of the PCIE device is completed.
  • the configuration space of the PCIE device is mapped to the physical address space of the memory, that is, the MMCFG space. When a PCIE device needs to be accessed through a processor, access to the PCIE device can be achieved by accessing the MMCFG space.
  • Large-scale x86 CC-NUMA systems usually include multiple gang boards, each of which can typically include 2 or 4 channels (one CPU is called one), and the system is usually designed to be 16-, 32- or 64-way.
  • each node board In the BIOS startup phase, each node board first performs its own BIOS startup, and subsequent node boards are merged to form a complete multi-channel system for providing an operating system.
  • the CPU performs the security authentication (SEC) phase and the initialization before the Extensible Firmware Interface (EFI) (Pre-EFI Initialization, in the early stage of BIOS startup).
  • SEC security authentication
  • EFI Extensible Firmware Interface
  • accessing includes reading and writing to a certain space.
  • "Accessing a certain space” may also be referred to as “accessing an address space” or “accessing an address”. For the convenience of description, these expressions are not strictly distinguished in this embodiment and in the embodiments.
  • the size of the MMCFG space to be used by each node is one segment when the node is started. A total of 8 segments are required; one segment accounts for 256 megabytes (mega bytes, MB), and 32 channels for MMCFG space requires 2 GB (8 x 256 MB).
  • the storage space below 4GB is occupied by 2MB by MMCFG.
  • the MMIO space is only 704MB (3GB+256MB ⁇ 3GB+960MB) for allocation to 32 CPUs. Because the allocation granularity of the MMIO space is at least 16MB, 704MB is allocated to 32 CPUs, and each CPU can only allocate 16MB of MMIO space. In this case, for some PCIE devices that require more than 8MB of MMIO space, each CPU can support up to one similar PCIE device, which limits the application of the product; if there is a PCIE card that requires more than 16MB of MMIO space, the CPU will not be able to Support has affected the compatibility of PCIE devices. With the increase in the number of x86 large-scale CC-NUMA system processors, the MMCFG space under 4GB is increased, which squeezes the space of MMIO and the address space of available memory below 4G, which limits the use of PCIE devices.
  • the BIOS startup method provided by the embodiment of the present application is used for BIOS startup of a node in a large-scale CC-NUMA system, and the startup method may be performed by a BIOS startup device, which may include a large-scale CC-NUMA system.
  • a BIOS startup device which may include a large-scale CC-NUMA system.
  • a part or all of a processor of a node; wherein the nodes in the large-scale CC-NUMA system may be a master node or an affiliate node.
  • the primary node refers to a node that can perform unified control management in the subsequent node merging step, and other nodes except the primary node are called secondary nodes.
  • the BIOS startup device is located in the local node (ie, "local node") in the CC-NUMA system, and the node may be the primary node or any one of the secondary nodes in the CC-NUMA system.
  • the BIOS boot device may include some or all of the processors in the node.
  • the BIOS boot device in this embodiment includes a processor 301, a memory 302, and a communication bus 303.
  • the processor 301 may be one or more CPUs in the node for executing a corresponding program by reading the stored program code of the memory;
  • the memory 302 may include physical memory corresponding to one or more CPUs and some non-volatile storage media (such as flash, disk, etc.) for storing program code and various data generated during the running of the program;
  • non-volatile storage media such as flash, disk, etc.
  • the communication bus 303 is used to complete communication between the processor and the memory and other devices (not shown in FIG. 3).
  • the communication bus may be an Industry Standard Architecture (ISA) bus, and an external device interconnection (Peripheral Component). , PCI) bus or extended Industry Standard Architecture (EISA) bus.
  • ISA Industry Standard Architecture
  • PCI Peripheral Component
  • EISA Extended Industry Standard Architecture
  • the bus 303 can be divided into an address bus, a data bus, a control bus, and the like. For ease of representation, only one thick line is shown in Figure 3, but it does not mean that there is only one bus or one type of bus.
  • a BIOS startup method is performed by the node, including:
  • the "access mode" refers to a manner in which a processor (CPU) is addressed by a bus of a certain number of bits.
  • the prior art is usually addressed by a 32-bit or 64-bit bus.
  • the maximum space that can be addressed by the first access mode is smaller than the maximum space that can be addressed by the second access mode to be described later.
  • the first access mode is a 32-bit access mode, that is, addressing through a 32-bit bus, and the maximum addressing space (that is, the "first address" in step S401) is 4 GB, correspondingly,
  • the second access mode can be an access mode of 64 bits or other bits (larger than 32 bits).
  • the local MMCFG space of the local node is allocated in a space where the local access address of the local node is lower than the first address.
  • the local MMCFG space of the node is a continuous space. Since the node can include one or more CPUs, when there are multiple CPUs, the local MMCFG space corresponding to these CPUs is a continuous space.
  • the local MMCFG space configured by each node in S402 may have the same address or different addresses.
  • the information may be determined according to actual requirements. Specific restrictions are made.
  • a Boot Strap Processor (BSP) of the main CPU in the node may wake up other CPUs (specifically, wake up one BSP of other CPUs), so that other The CPU performs its own memory initialization.
  • the BSP can be regarded as a core in a CPU. After the CPU is powered on, the core obtains the execution right of the code through the competition.
  • the specific implementation manner is also in the prior art, and is not described here.
  • Memory initialization means that each CPU in the node detects the one or more physical memories corresponding to the connection by reading and writing the local MMCFG space of the node (including the register space of the memory controller) to obtain the connected memory.
  • Basic information (capacity, frequency, timing, etc.), then configure the connected memory (including configuring the memory controller and the memory itself).
  • the main CPU in the node may be The BSP completes the memory initialization of other CPUs by serial (also called “single thread”, by the BSP of the main CPU) or parallel (also called “multithreading", and the BSP of the main CPU wakes up the BSP of other CPUs to complete the memory initialization).
  • serial also called “single thread”
  • parallel also called “multithreading”
  • the BSP of the main CPU wakes up the BSP of other CPUs to complete the memory initialization.
  • the way to proceed The content and implementation process of the memory initialization in this embodiment are all prior art, and are not described in this embodiment.
  • the "global access address" here is a uniformly addressed address, and each CPU of each node accesses various devices (such as registers, peripherals, physical memory, etc.) through this uniformly addressed address.
  • the addresses of the MMCFG spaces of all the nodes in the allocated CC-NUMA system in the global access address do not overlap each other, that is, the MMCFG space of each node is in the global access address.
  • the address is inaccessible.
  • the address of the MMCFG space of each node in the CC-NUMA system is consecutive in the global access address. This way the access is more regular, even in a unified access.
  • the node is allocated in the global access address, and the access address supported by the peripheral of the node is used as the MMIO space of the node.
  • the MMIO space allocated to the node may be below the first address in the global access address of the system, or may be above the first address in the global access address of the system. limited.
  • the system The global access address has a large amount of space in the storage space below the first address that can be allocated as MMIO space.
  • Each node starts from its own and does not communicate with each other. After this step, through mutual interaction between nodes, one of the master nodes can collect information of other nodes, so that the master node can perform unified Control, thus forming a complete system, this process is called "node consolidation.”
  • the process of executing S406 is different, and specifically includes the following two situations:
  • Case 1 the node is the master node.
  • the interaction with at least one other node in the system to complete the node merging of the system to form a complete system may include:
  • the notification message is used to instruct the auxiliary node to send its own system information to the primary node;
  • the BIOS starts and wakes up the secondary node and assigns the corresponding task to the secondary node to execute.
  • each node may be interconnected by some interconnecting chips (also called Node Controllers (NCs)) to complete communication with each other, how to implement the prior art, here is not Let me repeat.
  • NNCs Node Controllers
  • the node is an affiliate node.
  • the interaction with at least one other node in the system to complete the node merging of the system to form a complete system may include:
  • the system message is sent to the master node, and the system message is used by the master node to complete the system node merging to form a complete system.
  • the method may include: after the last access to the central processor CPU register, interact with at least one other node in the system to complete node merging of the system to form a complete system.
  • the second access mode may be a 64-bit mode.
  • the system will enter the second access mode from the first access mode and can address the address above the first address in the global access address of the system.
  • the method may further include:
  • the page table In the space where the local access address of the node is below the first address (4G), the page table is configured, and the page table points to the node that is accessible to the node in the second access mode and cannot be accessed by the node in the first access mode. Address space.
  • SMM System Management Mode
  • the MMCFG space of the node in the global access address of the system is allocated to 4G or more, the MMCFG space cannot be accessed in the SMM, and the system function will be Incomplete, this application establishes a page table in a 32-bit space.
  • the MMCFG space of 4G or more in the global access address of the system can be accessed through the indication of the page table.
  • the BIOS startup method provided by the embodiment of the present application is applied to a primary node or a secondary node in a large-scale CC-NUMA system.
  • the local access address of the local node at the local node is a space below the first address.
  • the local MMCFG is allocated to complete the memory initialization.
  • some or all of the MMCFG space of the node is in the system.
  • the position of the address in the office access address is moved, and the space below the first address is moved to the space above the first address and can be accessed in the second access mode, so that in the second access mode, the CPU is guaranteed.
  • the address of the MMCFG space in the system's global access address is still accessible.
  • the space saved by the move below the first address can be reserved for devices that can only be used in these spaces (for example, leaving more MMIO space for PCIE cards that can only be accessed under 4GB) , leaving more available memory space for the system to use), even if the number of CPUs included in the CC-NUMA system is constantly expanding, the address of the MMCFG space in the system's global access address may not occupy the space below the first address, thus being able to support More PCIE devices, therefore, under the premise of the expansion of the number of CPUs included in the large-scale CC-NUMA system, the BIOS boot does not affect the available space of the MMIO space and the available memory space in the lower address, which improves the large-scale CC-NUMA system PCIE device and operating system compatibility.
  • the present embodiment specifically describes step S402 in the first embodiment.
  • the example node includes four CPUs, which are respectively recorded as CPU0, CPU1, CPU2, and CPU3, and allocate a local kilometer (KB) space of MMCFG space for each CPU.
  • the allocation results are as follows: CPU0 allocates 2G to 2G+64M MMCFG space; CPU1 allocates 2G+64M to 2G+64M+64M MMCFG space; the rest and so on.
  • the local MMCFG space of the four CPUs is continuous, and when the CPU0 accesses the address of 2G+64M, it accesses the MMCFG space of the CPU1, and the CPU1 control and status register (CSR) register can be operated.
  • CPU1 accesses the 2G address, it accesses the MMCFG space of CPU0 and operates the CSR register of CPU0.
  • the rest are analogous. Any CPU that implements this node can access the CSR registers of the remaining CPUs in the node.
  • the local MMCFG space allocated to the node can be implemented through a configuration register.
  • the node can allocate a space as a local MMCFG space of a node by configuring the MMCFG_Rule register in the space where the local access address of the node is below the first address, and set the local MMCFG allocated by configuring the MMCFG_Rule register by configuring the MMCFG_Target_LIST register. Space is the local MMCFG space of the node.
  • MMCFG_Rule is a register for setting the MMCFG space in the CPU.
  • the base address of the specified address of the Base Address field of the MMCFG_Rule register is set by the BIOS code, and the Length field specifies the space.
  • the size, Rule Enable specifies whether the rule is valid.
  • the Package0-7 field segment of the MMCFG_Target_LIST register specifies the Node ID Node ID corresponding to the MMCFG space to implement which local MMCFG space the allocated local MMCFG space is.
  • the following illustrates an example of how the local MMCFG space of the allocated node of FIG. 5 is implemented by a configuration register.
  • the implementation process is to configure the CPU registers eax, xmm2, xmm3, xmm4, xmm5.
  • the specific setup process can be as follows:
  • the base address of the local MMCFG space allocated to the node in the above example is 2 GB, which is only an example, and is not specifically limited to the value of the Base Address. In practical applications, the base address can be transformed according to actual needs.
  • step S404 in the above embodiment specifically describes step S404 in the above embodiment.
  • the node can allocate the address of the MMCFG space in the global access address by configuring the DRAM Rule register.
  • the address of the MMCFG space allocated in the global access address through the DRAM Rule register can be set to the MMCFG of the node by configuring the INTERLEAVE_LIST register. space.
  • the DRAM Rule register is used for address allocation from 0MB address to the maximum addressable space of the memory.
  • the space upper limit address is specified by setting the Limit field of the DRAM_RULE_0 ⁇ 19 register, and the attr field specifies whether the space is used for the DRAM or the MMCFG space.
  • the RULE_ENABLE field specifies whether the rule effectively allocates the memory space of the CPU in the node.
  • the large-scale CC-NUMA system is a 32-channel system
  • the first access mode is a 32-bit mode
  • the first address is 4 GB
  • the node is a Node0 node
  • the Node0 includes 4 CPUs
  • the global access address is 4 GB.
  • the above location allocates a total of 256 MB of MMCFG space for the CPU of Node0. After switching to the 64-bit mode, the CSR of the MMCFG space access CPU of Node0 in the global access address is read.
  • the contents of the configuration register are as shown in Table 1 below, and the Node0 is allocated 32 terabytes (Trillion byte, TB) + 4 GB to 32 TB + 4 GB + 256 MB of 256 MB of the address of the MMCFG space in the global access address, and the MMCFG of the other nodes.
  • the address of the space in the global access address is 32TB+4GB+256MB ⁇ 32TB+4GB+2GB.
  • the address of the MMCFG space of 8 nodes in the large-scale CC-NUMA system allocated by this example in the global access address is as shown in FIG. 6.
  • the MMCFG space allocated to the nodes in the system is the base address 32T+4G in the global access address, which is only an example, and is not specifically limited to the value of the base address. In practical applications, the base address can be transformed according to actual needs.
  • Table 1 includes the register configuration of the MMCFG space in the global access address of the node in the distribution system, and includes other register configurations; the configuration of other registers is configured according to system rules, and Table 1 is only an example, not specific limited.
  • register configuration of Table 1 is merely an example, and an example of assigning an address in the global access address of the MMCFG space through the configuration register is not specifically limited to this process.
  • the address of the MMCFG space of the local node in the global access address of the system needs to be allocated to the space where the global access address is above the first address and can be accessed in the second access mode, and Currently in the first access mode, therefore, the node cannot access the MMCFG space of the node at this time, the master node can reserve its local MMCFG, and all the nodes in the system access the MMCFG space of the master node to perform unified memory addressing of the system. , respectively, assign the address of each node's MMCFG space in the system's global access address.
  • the method may further include:
  • the local MMCFG space of the primary node is reserved for each node in the system to perform system memory unified addressing to allocate the address of each node's MMCFG space in the system's global access address.
  • the local MMCFG space of the primary node below the reserved first address is used, except that each node in the system can perform unified memory addressing of the system to allocate the address of each node's MMCFG space in the global access address of the system. It is also possible to use some drivers to access some hardware device configuration registers in the first access mode and only use the space below the first address to improve system compatibility when accessing MMCFG.
  • the first access mode is a 32-bit mode
  • the reserved local MMCFG space of the master node below 4 GB, in addition to being used for each node in the system for performing memory unified addressing allocation of the system.
  • the address of the MMCFG space of each node is in the global access address of the system. It can also be used when some drivers want to access some hardware device configuration registers in 32-bit mode and can only access the space below 4GB. System compatibility when MMCFG.
  • the manner of accessing the MMCFG includes multiple (register mode, port mode, etc.), and some of the access modes only support spatial access below the first address (for example, port mode), and therefore, the reserved primary node below the first address
  • the local MMCFG space can balance the access modes that only support spatial access below the first address, and improve system compatibility when accessing MMCFG.
  • step S405 in the above embodiment.
  • the MMIO space of each node can be uniformly addressed in the address space below the first address in the global access address of the system by configuring the MMIO Rule0 ⁇ 15, MMIO_Target_LIST_0, MMIO_Target_LIST_1 registers, thereby greatly improving the PCIE of the multi-channel system. Device compatibility.
  • the MMIO Rule register is used to allocate MMIO space for each CPU.
  • the space address is specified by setting the Base address field of the MMIO Rule register, and the Limit address field specifies the space upper address.
  • Rule_Enable specifies whether the rule is valid.
  • the MMIO_Target_LIST_0 register field segment Package0 to 7 By configuring the MMIO_Target_LIST_0 register field segment Package0 to 7 to specify which node the MMIO interval set by the MMIO_RULE register belongs to, it is represented by the node ID Node ID.
  • the size of the MMIO space can be freely adjusted between the CPUs.
  • the base address of the MMIO space can also be changed below the first address in the global access address of the system, or can be changed above the first address in the global access address of the system. This application does not specifically limit this.
  • the MMIO space is allocated to the four CPUs of the node 0 in the 32-channel CC-NUMA system in the space below 4 GB in the global access address of the system; wherein, the node 0 is allocated 2GB+256MB ⁇ 2GB+640MB total 384MB MMIO space, the contents of each domain segment of the configured MMIO_RULE register are shown in Table 2, the example is assigned The MMIO space is shown in Figure 7.
  • the configuration of MMIO_RULE0 to MMIO_RULE3 is used to allocate MMIO space for node 0
  • the configuration of MMIO_RULE4 ⁇ MMIO_RULE6 is configured according to system rules, and the MMIO interval set by MMIO_RULE register is specified by configuring MMIO_Target_LIST_0 register field segment Package4 ⁇ 6 Pointing to the NC, so that the subsequent processing by the NC, thereby achieving interconnection between nodes.
  • register configuration of Table 2 is merely an example, and an example of allocating MMIO space to a storage space of 4 GB or less in the global access address of the system through the configuration register is not specifically limited to this process.
  • the large-scale CC-NUMA system is 32 channels, and the 4-way performs BIOS startup based on one node.
  • the solution of the present application is executed, and after the unified addressing, the global access address of the system is The result of the allocation can be as shown in FIG.
  • the embodiment of the present application provides another BIOS startup device 90.
  • the startup device 90 is included in the node, and the local node is a primary node or a secondary node in the CC-NUMA system, and the CC is
  • the -NUMA system includes a primary node and at least one secondary node.
  • the starting device 90 can include:
  • the mode unit 901 is configured to control the system to enter the first access mode, where the maximum address accessed by the local node is the first address in the first access mode.
  • the allocating unit 902 is configured to allocate a local MMCFG space of the local node in a space where the local access address of the local node is lower than the first address in the first access mode.
  • the initializing unit 903 is configured to perform memory initialization by accessing the local MMCFG space of the local node allocated by the allocating unit 902.
  • the allocating unit 902 is further configured to: after the initialization unit 903 completes the memory initialization, perform unified memory addressing of the system, and allocate an address of the MMCFG space of the node in the global access address of the system; wherein, the MMCFG space of the node is all Or a portion of the space where the global access address is above the first address and can be accessed in the second access mode.
  • the allocating unit 902 is further configured to allocate an MMIO space for the node in a global access address of the system.
  • the merging unit 904 is configured to interact with at least one other node in the system to complete the system.
  • the nodes are merged to form a complete system.
  • the first address may be 4 GB.
  • the allocating unit 902 can be specifically configured to:
  • the memory of the system By accessing the local MMCFG space of the master node, the memory of the system is uniformly addressed and the address of the MMCFG space of the node in the global access address of the system is allocated.
  • the activation device 90 may further include:
  • the configuration unit 905 is configured to: before the mode unit 901 controls the system to enter the second access mode from the first access mode, configure a page table in a space where the local access address of the local node is below the first address, and the page table points to In the second access mode, the address space that the local node can access and cannot access in the first access mode.
  • the access unit 906 is configured to: after the mode unit 901 controls the system to enter the second access mode from the first access mode, access the MMCFG space of the local node in the global access address of the system according to the page table configured by the configuration unit 905. address.
  • the addresses of the MMCFG space of each node in the CC-NUMA system in the global access address of the system do not overlap each other.
  • the address of the MMCFG space of each node in the CC-NUMA system is consecutive in the global access address of the system; wherein, the first address of the address of the MMCFG space of one node in the global access address of the system Is the tail address of the address of the MMCFG space of another node in the global access address of the system.
  • the local node is the primary node
  • the merging unit 904 is specifically configured to:
  • the notification message is used to indicate that the auxiliary node sends its own system information to the primary node;
  • the local node is the auxiliary node
  • the merging unit 904 is specifically configured to:
  • the system message is used by the master node to complete node merging of the system to form a complete system.
  • the merging unit 904 can be specifically configured to:
  • interaction with at least one other node in the system completes the node merging of the system to form a complete system.
  • the disclosed system, apparatus, and method may be implemented in other manners.
  • the device embodiments described above are merely illustrative.
  • the division of the unit is only a logical function division.
  • there may be another division manner for example, multiple units or components may be combined or Can be integrated into another system, or some features can be ignored or not executed.
  • the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interface, device or unit, and may be in an electrical, mechanical or other form.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may be physically included separately, or two or more location units may be integrated into one unit.
  • the above integrated unit can be implemented in the form of hardware or in the form of hardware plus software functional units.
  • the above-described integrated unit implemented in the form of a software functional unit can be stored in a computer readable storage medium.
  • the software functional unit described above is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, server, or network device, etc.) to perform portions of the steps of the methods described in various embodiments of the present application.
  • the foregoing storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, and the like, which can store program codes. .

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Stored Programmes (AREA)
  • Bus Control (AREA)
  • Memory System Of A Hierarchy Structure (AREA)

Abstract

一种BIOS启动方法及装置,涉及计算机领域,实现在大规模的CC-NUMA系统包含的CPU数量扩展的前提下,BIOS启动不影响MMIO空间及可用内存空间在系统全局访问地址中第一地址以下的占用容量。具体方案包括:通过在第一访问模式下,本节点在本节点的本地访问地址为第一地址以下的空间中分配本地MMCFG完成内存初始化,在进行系统的内存统一编址时,将部分或全部的本节点的MMCFG空间在系统的全局访问地址中的地址的位置进行搬移,由原来第一地址以下的空间搬移到第一地址以上且能够在第二访问模式下被访问到的空间。

Description

一种BIOS启动方法及装置
本申请要求于2016年04月20日提交中国专利局、申请号为201610248616.X、发明名称为“一种BIOS启动方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及计算机领域,尤其涉及一种基本输入/输出系统(Basic Input/Output System,BIOS)启动方法及装置。
背景技术
随着科技的发展,高性能服务器越来越多的应用到科学研究和企业经营活动中。其中,x86大规模的缓存一致性非均匀访存架构(Cache Coherence Non-Uniform Memory Access,CC-NUMA)系统凭借高性能,高扩展性和易于编程的环境等特点,得到了广泛应用。
大规模的CC-NUMA系统一般由多个单独的服务器主板(节点板)通过Cache Coherence互联网络进行互联,组成只运行一个操作系统的一台大型服务器。一般情况下,大规模x86的CC-NUMA多路系统通常先基于2路或者4路的节点板进行各自BIOS的启动,在各自BIOS启动过程中内存统一编址配置全局系统的地址空间,后续再在BIOS流程的某一阶段,将各个节点纳入一个BIOS流程中进行管理和启动,BIOS成完整的多路系统提供给一个操作系统。
在早期的BIOS启动过程中,由于CPU运行在32比特(bit)模式下,只能寻址到4千兆字节(KilomegaByte,GB)的地址空间,又由于在内存初始化时,每个节点板都需要访问内存映射配置(Memory Mapped config,MMCFG)空间,就需要将MMCFG空间的空间编址在4GB以下的位置。
但是,随着大规模的CC-NUMA系统包含的中央处理器(Central Processing Unit,CPU)数量的增加,每个CPU占用的MMCFG空间大小固定,4GB以下的位置的MMCFG空间随之增加,由于4GB以下的位置地址容量固定且有限,一方面导致内存映射输入输出(Memory Mapped Input/Output,MMIO)空间随之减少,较少的MMIO空间限制了总线和接口标准(Peripheral Component Interface Express,PCIE)设备的数量、功能,造成大规模的CC-NUMA系统产品的PCIE设备兼容性不高。另一方面导致4GB以下可用内存的地址空间随之减少,过低的可用内存可能会引起操作系统无法启动的兼容性问题。
发明内容
本申请实施例提供一种BIOS启动方法及装置,实现在大规模的CC-NUMA系统包含的CPU数量扩展的前提下,BIOS启动不影响MMIO空间及可用内存空间在低位地址中的可用空间,以提高大规模的CC-NUMA系 统PCIE设备及操作系统的兼容性。
为达到上述目的,本申请采用如下技术方案:
第一方面,提供一种BIOS启动方法,应用于本节点,所述本节点为大规模CC-NUMA系统中的主节点或者附属节点,所述CC-NUMA系统包括一个主节点及至少一个附属节点,所述方法包括:
进入第一访问模式,其中,在所述第一访问模式下,所述本节点访问的最大地址为第一地址,在所述第一访问模式下执行如下步骤:
在所述本节点的本地访问地址为所述第一地址以下的空间中,分配所述本节点的本地内存映射配置MMCFG空间;
通过访问所述本节点的本地MMCFG空间进行内存初始化;
在完成内存初始化后,进行所述系统的内存统一编址分配所述本节点的MMCFG空间在所述系统的全局访问地址中的地址;其中,所述本节点的MMCFG空间全部或部分在所述全局访问地址为第一地址以上且能够在第二访问模式下被访问到的空间;
在所述系统的全局访问地址中为所述本节点分配内存映射输入输出MMIO空间;
与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统;
进入所述第二访问模式,其中,在所述第二访问模式下,所述本节点所能访问到的地址空间大于在所述第一访问模式下所述本节点所能访问到的地址空间。
其中,在大规模CC-NUMA系统中包括多个节点,多个节点中的一个节点被选择为主节点,其余节点则为附属节点。
在实际应用中,附属节点也可以称之为从节点或者非主节点,在本申请中为可替换的同一概念。
需要说明的是,对于大规模CC-NUMA系统中确定主节点及附属节点的过程,本申请不再进行赘述。
其中,MMCFG空间编址在第一地址以下的存储空间称之为MMCFGL,编址在第一地址以上的存储空间称之为MMCFGH。
具体的,分配本节点的本地MMCFG空间及MMCFG空间在系统的全局访问地址中的地址,都可以通过配置寄存器来实现。
其中,本节点可以通过配置MMCFG_Rule(内存映射配置空间规则)寄存器,在本节点的本地访问地址为第一地址以下的空间中,分配一部分空间作为一个节点的本地MMCFG空间,可以通过配置MMCFG_Target_LIST(内存映射配置空间目标清单)寄存器设置通过MMCFG_Rule寄存器配置的第一地址以下的空间中的本地MMCFG空间为本节点的本地MMCFG空间。
需要说明的是,配置MMCFG_Target_LIST寄存器,可以用于设置分配的本地MMCFG空间对应哪个节点,也就相当于为哪个节点分配的本地MMCFG空间。
其中,本节点可以通过配置DRAM Rule(内存编址规则)寄存器,进行系统的内存统一编址,分配一部分空间作为一个节点的MMCFG空间在系统的全局访问地址中的地址,通过配置INTERLEAVE_LIST(内存交织目标清单)寄存器设置通过DRAM Rule寄存器配置的在系统的全局访问地址中的地址为本节点的MMCFG空间在系统的全局访问地址中的地址。
其中,大规模CC-NUMA系统包括的每个节点中,均包括至少一个中央处理器(Central Processing Unit,CPU),在一个节点的MMCFG空间(包括本地MMCFG空间或MMCFG空间在系统的全局访问地址中的地址)中,每个CPU的MMCFG空间依次连接且不重复,一个CPU的MMCFG空间的首地址为另一个CPU的MMCFG空间的尾地址。
具体的,在根据本节点外围设备的需求,为本节点分配MMIO时,可以在系统的全局访问地址中的地址中任意位置,分配尽量大的空间以满足本节点外围设备的需求。
这样一来,在第一访问模式下,本节点通过在本节点的本地访问地址为第一地址以下的空间中分配本地MMCFG完成内存初始化后,在进行系统的内存统一编址时,将部分或全部的本节点的MMCFG空间在系统的全局访问地址中的地址的位置进行搬移,由原来第一地址以下的空间搬移到第一地址以上且能够在第二访问模式下被访问到的空间,这样,在第二访问模式下,保证CPU仍然能够访问MMCFG空间在系统的全局访问地址中的地址。同时,位于第一地址以下的、通过搬移节省出来的空间,就可以留给一些只能在这些空间使用的设备(例如,留出更多的MMIO空间给只能在4GB以下访问的PCIe卡使用,留出更多的可用内存空间供系统使用),即使CC-NUMA系统包含的CPU数量不断扩展,MMCFG空间在系统的全局访问地址中的地址可以不占用第一地址以下的空间,从而能够支持更多的PCIE设备,因此,实现了在大规模的CC-NUMA系统包含的CPU数量扩展的前提下,BIOS启动不影响MMIO空间及可用内存空间在低位地址中的可用空间,提高了大规模的CC-NUMA系统PCIE设备及操作系统的兼容性。
结合第一方面,在第一方面的第一种可能的实现方式中,
所述第一地址可以为4GB。
其中,第一访问模式可以为x86系统中的32位模式,在该模式下,能够访问的最大地址即为4GB。
由此可知,在x86系统中的32位模式下,如上述第一方面一样,通过上述第一种可能的实现方式,可以留出更多4GB以下的空间供节点的外设(如PCIE卡)使用,提高了大规模的CC-NUMA系统对外设的兼容性。
结合第一方面或第一方面的第一种可能的实现方式,在第一方面的第二种可能的实现方式中,
在进行系统的内存统一编址时,需要将本节点的MMCFG空间在系统的全局访问地址中的地址分配在在全局访问地址为第一地址以上且能够在第二访问模式下被访问到的空间,而当前在第一访问模式,因此,此时本节点无 法访问本节点的MMCFG空间,主节点可以将其本地MMCFG保留,系统中的所有节点通过访问主节点的MMCFG空间,进行系统的内存统一编址,分别分配每个节点的MMCFG空间在系统的全局访问地址中的地址。
进一步的,若所述本节点为主节点,在通过访问本节点的本地MMCFG空间进行内存初始化后,所述方法还可以包括:
保留主节点的本地MMCFG空间,用于系统内的每个节点进行系统的内存统一编址分配每个节点的MMCFG空间在系统的全局访问地址中的地址。
由此可知,保留的第一地址以下的主节点的本地MMCFG空间,除了可以用于系统内的每个节点进行系统的内存统一编址分配每个节点的MMCFG空间在系统的全局访问地址中的地址,还可以当有一些驱动程序要在第一访问模式下访问一些硬件设备配置寄存器,只能访问第一地址以下的空间时使用,用于提高访问MMCFG时的系统兼容性。
结合第一方面或第一方面的第一种可能的实现方式或第一方面的第二种可能的实现方式,在第一方面的第三种可能的实现方式中,
在进入第二访问模式之前,所述方法还可以包括:
在本节点的本地访问地址为第一地址以下的空间中,配置页表,所述页表指向在第二访问模式中本节点所能访问到且在第一访问模式下本节点不能访问到的地址空间;
在进入所述第二访问模式后,所述方法还可以包括:
按照页表访问本节点的MMCFG空间在系统的全局访问地址中的地址。
具体的,在进入至第二访问模式后,才支持访问分配第一地址以上的MMCFG空间,要实现访问第一地址以上的空间,可以在第一地址以下的存储空间中配置页表,该页表指向在第二访问模式中本节点所能访问到且在第一访问模式下本节点不能访问到的地址空间,节点通过访问配置的页表,即可访问到分配的第一地址以上的MMCFG空间。
其中,对于页表的具体内容以及页表在第一地址以下存储空间中的具体位置,可以根据实际需求设定,本申请对此不进行具体限定。凡是在大规模CC-NUMA系统中,通过页表访问本节点的MMCFG空间在系统的全局访问地址中第一地址以上的地址空间,都属于本申请的保护范围。
这样一来,在上述第一方面的第三种可能的实现方式中,通过配置页表以访问上述第一方面或任一种可能的实现方式中分配的第一地址以上的地址,可以更好的实现上述第一方面或任一种可能的实现方式的效果。
结合第一方面或第一方面的第一种可能的实现方式至第一方面的第三种可能的实现方式中任一项,在第一方面的第四种可能的实现方式中,
CC-NUMA系统中每个节点的MMCFG空间在系统的全局访问地址中的地址相互不重叠。
由于CC-NUMA系统中每个节点的MMCFG空间在系统的全局访问地址中的地址是各个节点访问外设时需要访问的地址,当相互不重叠时,可以在访问外设时各个节点相互不干扰,提高了系统性能。
结合第一方面或第一方面的第一种可能的实现方式至第一方面的第四种可能的实现方式中任一项,在第一方面的第五种可能的实现方式中,
CC-NUMA系统中每个节点的MMCFG空间在系统的全局访问地址中的地址连续;其中,一个节点的MMCFG空间在所述系统的全局访问地址中的地址的首地址是另一个节点的MMCFG空间在所述系统的全局访问地址中的地址的尾地址。
当CC-NUMA系统中每个节点的MMCFG空间在系统的全局访问地址中的地址相互连续时,各个节点可以访问到其他节点的MMCFG空间,进行节点的相互连通,而且访问起来更有规律,即便于统一访问。
结合第一方面或第一方面的第一种可能的实现方式至第一方面的第五种可能的实现方式中任一项,在第一方面的第六种可能的实现方式中,
若本节点为主节点,与所述系统中的至少一个其他节点进行交互,完成系统的节点合并,构成完整系统,可以通过下述过程实现:
向CC-NUMA系统中每一个附属节点发送通知消息,通知消息用于指示附属节点向主节点发送自身的系统信息;
分别接收每一个附属节点发送的各自的系统消息,完成系统的节点合并,构成完整系统。
第一方面的第六种可能的实现方式提供了主节点完成系统的节点合并,构成完整系统的具体方法,以达到上述各种可能的实现方式的效果。
结合第一方面或第一方面的第一种可能的实现方式至第一方面的第六种可能的实现方式中任一项,在第一方面的第七种可能的实现方式中,
若本节点为附属节点,与所述系统中的至少一个其他节点进行交互,完成系统的节点合并,构成完整系统,可以通过下述过程实现:
终止自身的BIOS流程;
接收主节点发送的用于指示附属节点向主节点发送自身系统信息的通知消息;
向主节点发送自身的系统消息,系统消息用于主节点完成系统的节点合并,构成完整系统。
第一方面的第七种可能的实现方式提供了主节点完成系统的节点合并,构成完整系统的具体方法,以达到上述各种可能的实现方式的效果。
结合第一方面或第一方面的第一种可能的实现方式至第一方面的第七种可能的实现方式中任一项,在第一方面的第八种可能的实现方式中,
所述与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统,可以通过下述过程实现:
在最后一次访问CPU寄存器之后,与系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统。
这样一来,通过第一方面的第八种可能的实现方式,本节点在最后一次访问CPU寄存器之后,进行BIOS合并,构成完整系统,使得各个节点内存初始化均相互独立,也就是说各个节点并行的进行内存初始化,减少了启动 时间。
第二方面,提供一种BIOS启动装置,所述启动装置包括于本节点,所述本节点为大规模CC-NUMA系统中的主节点或者附属节中,所述CC-NUMA系统包括一个主节点及至少一个附属节点,所述启动装置包括:
模式单元,用于控制所述系统进入第一访问模式,其中,在所述第一访问模式下,所述本节点访问的最大地址为第一地址;
分配单元,用于在所述第一访问模式下,在所述本节点的本地访问地址为所述第一地址以下的空间中,分配所述本节点的本地内存映射配置MMCFG空间;
初始化单元,用于通过访问所述分配单元分配的所述本节点的本地MMCFG空间进行内存初始化;
所述分配单元还用于,在所述初始化单元完成内存初始化后,进行所述系统的内存统一编址分配所述本节点的MMCFG空间在所述系统的全局访问地址中的地址;其中,所述本节点的MMCFG空间全部或部分在所述全局访问地址为第一地址以上且能够在第二访问模式下被访问到的空间;
所述分配单元还用于,在所述系统的全局访问地址中为所述本节点分配内存映射输入输出MMIO空间;
合并单元,用于与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统;
所述模式单元还用于,控制所述系统从所述第一访问模式进入第二访问模式,其中,在所述第二访问模式下,所述本节点所能访问到的地址空间大于在所述第一访问模式下所述本节点所能访问到的地址空间。
结合第二方面,在第二方面的第一种可能的实现方式中,
所述第一地址为4GB。
结合第二方面或第二方面的第一种可能的实现方式,在第二方面的第二种可能的实现方式中,
所述分配单元具体用于:
通过访问所述主节点的本地MMCFG空间,进行所述系统的内存统一编址分配所述本节点的MMCFG空间在所述系统的全局访问地址中的地址。
结合第二方面或第二方面的第一种可能的实现方式或第二方面的第二种可能的实现方式,在第二方面的第三种可能的实现方式中,
所述装置还包括:
配置单元,用于在所述模式单元控制所述系统从所述第一访问模式进入所述第二访问模式之前,在所述本节点的本地访问地址为所述第一地址以下的空间中,配置页表,所述页表指向在所述第二访问模式中所述本节点所能访问到且在所述第一访问模式下所述本节点不能访问到的地址空间;
访问单元,用于在所述模式单元控制所述系统从所述第一访问模式进入所述第二访问模式后,按照所述配置单元配置的页表访问所述本节点的MMCFG空间在所述系统的全局访问地址中的地址。
结合第二方面或第二方面的第一种可能的实现方式至第二方面的第三种可能的实现方式中任一项,在第二方面的第四种可能的实现方式中,
所述CC-NUMA系统中每个节点的MMCFG空间在所述系统的全局访问地址中的地址相互不重叠。
结合第二方面或第二方面的第一种可能的实现方式至第二方面的第四种可能的实现方式中任一项,在第二方面的第五种可能的实现方式中,
所述CC-NUMA系统中每个节点的MMCFG空间在所述系统的全局访问地址中的地址连续;其中,一个节点的MMCFG空间在所述系统的全局访问地址中的地址的首地址是另一个节点的MMCFG空间在所述系统的全局访问地址中的地址的尾地址。
结合第二方面或第二方面的第一种可能的实现方式至第二方面的第五种可能的实现方式中任一项,在第二方面的第六种可能的实现方式中,
若所述本节点为所述主节点,所述合并单元具体用于:
向所述CC-NUMA系统中每一个附属节点发送通知消息,所述通知消息用于指示附属节点向所述主节点发送自身的系统信息;
分别接收所述每一个附属节点发送的各自的系统消息,完成所述系统的节点合并,构成完整系统。
结合第二方面或第二方面的第一种可能的实现方式至第二方面的第六种可能的实现方式中任一项,在第二方面的第七种可能的实现方式中,
若所述本节点为所述附属节点,所述合并单元具体用于:
终止自身的BIOS流程;
接收所述主节点发送的用于指示附属节点向所述主节点发送自身系统信息的通知消息;
向所述主节点发送自身的系统消息,所述系统消息用于所述主节点完成所述系统的节点合并,构成完整系统。
结合第二方面或第二方面的第一种可能的实现方式至第二方面的第七种可能的实现方式中任一项,在第二方面的第八种可能的实现方式中,
所述合并单元具体用于:
在最后一次访问中央处理器CPU寄存器之后,与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统。
第二方面或者第二方面任一种可能的实现方式提供的装置,用于实现第一方面或第一方面任一种可能的实现方式中的BIOS启动方法,可以达到相同的技术效果。
第三方面,提供一种BIOS启动装置,所述启动装置包括于本节点,所述本节点为大规模CC-NUMA系统中的主节点或者附属节中,所述CC-NUMA系统包括一个主节点及至少一个附属节点,所述启动装置包括:
处理器,用于控制所述系统进入第一访问模式,其中,在所述第一访问模式下,所述本节点访问的最大地址为第一地址;所述处理器还用于在所述第一访问模式下执行如下步骤:
在所述本节点的本地访问地址为所述第一地址以下的空间中,分配所述本节点的本地内存映射配置MMCFG空间;
通过访问所述本节点的本地MMCFG空间进行内存初始化;
在完成内存初始化后,进行所述系统的内存统一编址分配所述本节点的MMCFG空间在所述系统的全局访问地址中的地址;其中,所述本节点的MMCFG空间全部或部分在所述全局访问地址为第一地址以上且能够在第二访问模式下被访问到的空间;
在所述系统的全局访问地址中为所述本节点分配内存映射输入输出MMIO空间;
与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统;
控制所述系统从所述第一访问模式进入第二访问模式,其中,在所述第二访问模式下,所述本节点所能访问到的地址空间大于在所述第一访问模式下所述本节点所能访问到的地址空间。
结合第三方面,在第三方面的第一种可能的实现方式中,
所述第一地址为4GB。
结合第三方面或第三方面的第一种可能的实现方式,在第三方面的第二种可能的实现方式中,
所述处理器具体用于:
通过访问所述主节点的本地MMCFG空间,进行所述系统的内存统一编址分配所述本节点的MMCFG空间在所述系统的全局访问地址中的地址。
结合第三方面或第三方面的第一种可能的实现方式或第三方面的第二种可能的实现方式,在第三方面的第三种可能的实现方式中,所述处理器还用于:
在从所述第一访问模式进入所述第二访问模式之前,在所述本节点的本地访问地址为所述第一地址以下的空间中,配置页表,所述页表指向在所述第二访问模式中所述本节点所能访问到且在所述第一访问模式下所述本节点不能访问到的地址空间;
在从所述第一访问模式进入所述第二访问模式后,按照所述配置单元配置的页表访问所述本节点的MMCFG空间在所述系统的全局访问地址中的地址。
结合第三方面或第三方面的第一种可能的实现方式至第三方面的第三种可能的实现方式中任一项,在第三方面的第四种可能的实现方式中,
所述CC-NUMA系统中每个节点的MMCFG空间在所述系统的全局访问地址中的地址相互不重叠。
结合第三方面或第三方面的第一种可能的实现方式至第三方面的第四种可能的实现方式中任一项,在第三方面的第五种可能的实现方式中,
所述CC-NUMA系统中每个节点的MMCFG空间在所述系统的全局访问地址中的地址连续;其中,一个节点的MMCFG空间在所述系统的全局访问 地址中的地址的首地址是另一个节点的MMCFG空间在所述系统的全局访问地址中的地址的尾地址。
结合第三方面或第三方面的第一种可能的实现方式至第三方面的第五种可能的实现方式中任一项,在第三方面的第六种可能的实现方式中,
若所述本节点为所述主节点,所述处理器具体用于:
向所述CC-NUMA系统中每一个附属节点发送通知消息,所述通知消息用于指示附属节点向所述主节点发送自身的系统信息;
分别接收所述每一个附属节点发送的各自的系统消息,完成所述系统的节点合并,构成完整系统。
结合第三方面或第三方面的第一种可能的实现方式至第三方面的第六种可能的实现方式中任一项,在第三方面的第七种可能的实现方式中,
若所述本节点为所述附属节点,所述处理器具体用于:
终止自身的BIOS流程;
接收所述主节点发送的用于指示附属节点向所述主节点发送自身系统信息的通知消息;
向所述主节点发送自身的系统消息,所述系统消息用于所述主节点完成所述系统的节点合并,构成完整系统。
结合第三方面或第三方面的第一种可能的实现方式至第三方面的第七种可能的实现方式中任一项,在第三方面的第八种可能的实现方式中,
所述处理器具体用于:
在最后一次访问中央处理器CPU寄存器之后,与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统。
上述第二方面或第三方面或上述任一种可能的实现方式提供的BIOS启动装置,用于实现第一方面或第一方面任一种可能的实现方式中的BIOS启动方法,可以达到相同的技术效果。
本申请实施例提供的BIOS启动方法及装置,应用于大规模CC-NUMA系统中的主节点或者附属节点,通过在第一访问模式下,本节点在本节点的本地访问地址为第一地址以下的空间中分配本地MMCFG完成内存初始化,在进行系统的内存统一编址时,将部分或全部的本节点的MMCFG空间在系统的全局访问地址中的地址的位置进行搬移,由原来第一地址以下的空间搬移到第一地址以上且能够在第二访问模式下被访问到的空间,这样,在第二访问模式下,保证CPU仍然能够访问MMCFG空间在系统的全局访问地址中的地址。同时,位于第一地址以下的、通过搬移节省出来的空间,就可以留给一些只能在这些空间使用的设备(例如,留出更多的MMIO空间给只能在4GB以下访问的PCIE卡使用,留出更多的可用内存空间供系统使用),即使CC-NUMA系统包含的CPU数量不断扩展,MMCFG空间在系统的全局访问地址中的地址可以不占用第一地址以下的空间,从而能够支持更多的PCIE设备,因此,实现了在大规模的CC-NUMA系统包含的CPU数量扩展的前提下,BIOS启动不影响MMIO空间及可用内存空间在低位地址中的可用空间,提高 了大规模的CC-NUMA系统PCIE设备及操作系统的兼容性。
附图说明
图1为一种大规模CC-NUMA系统架构图;
图2为现有技术提供的BIOS启动阶段编址方案示意图;
图3为本申请实施例提供的一种BIOS启动装置结构图;
图4为本申请实施例提供的一种BIOS启动方法流程示意图;
图5为本申请实施例提供的一种MMCFG空间编址示意图;
图6为本申请实施例提供的另一种MMCFG空间编址示意图;
图7为本申请实施例提供的一种MMIO空间编址示意图;
图8为本申请实施例提供的一种BIOS启动阶段编址方案示意图;
图9为本申请实施例提供的另一种BIOS启动装置结构图;
图10为本申请实施例提供的再一种BIOS启动装置结构图。
具体实施方式
大规模的CC-NUMA系统一般由多个单独的服务器主板通过缓存一致性(Cache Coherence)互联网络进行互联,组成只运行一个操作系统的一台大型服务器。图1示出的是大规模CC-NUMA系统的架构,包括节点1至节点n,每个节点由处理器,内存,外围设备和其他模块组成,节点之间通过高速互联来组成一个完整的系统。
其中,每个节点可以包括一个或多个处理器(如x86CPU),每个CPU对应一个或多个物理内存,物理内存作为处理器的设备之一跟其他设备(如寄存器、外围设备)一起进行统一编址,后续各个CPU通过编址后的地址来访问各自对应的物理内存。如何进行统一编址及访问都为现有技术,本实施例不进行具体介绍。需要说明的是,在图1中,为了方便示意,并没有画出每个CPU对应的一个或多个物理内存,而只用一个内存模块来简单表示节点中的各个物理内存。
其中,节点中的处理器通过与外围设备(例如:现阶段广泛使用的PCIE设备)连接,实现大规模CC-NUMA系统的多种应用。处理器可以支持的PCIE设备的数量,取决于该处理器的MMIO空间的大小。
PCIE设备都有一个配置空间,保存了设备的基本特性信息,通过对配置空间的配置,完成PCIE设备存储空间的地址分配等功能设置工作。把PCIE设备的配置空间映射至内存的物理地址空间即MMCFG空间。在需要通过处理器访问PCIE设备时,通过访问MMCFG空间,即可实现对PCIE设备的访问。
大规模x86的CC-NUMA系统通常包括多个节点板,每个节点板通常可以包括2路或4路(一个CPU称为一路),系统总共通常设计成16路、32路或者64路。在BIOS启动阶段,每个节点板先进行各自BIOS启动,后续各路节点板进行节点合并,构成完整的多路系统提供给一个操作系统。CPU在BIOS启动早期,执行安全认证(Security,SEC)阶段及在可扩展固件接口(Extensible Firmware Interface,EFI)前的初始化(Pre-EFI Initialization, PEI)阶段的绝大部分时间(除末期)里,运行在32位模式下,只能寻址到内存中4GB(2^32)以内的物理地址空间;x86CPU已经将CPU绝大多数配置寄存器当做PCI标准寄存器(即x86CPU将集成的内存控制器以PCIE设备的方式进行管理,系统中的软件可以像访问PCIE标准寄存器的方式一样访问内存控制器的寄存器),此阶段需执行快速互联接口(Quick Path Interconnect,QPI)初始化程序以及进行内存初始化,这些操作都需要访问MMCFG空间,又由于此时系统运行在32位模式下,就需要将MMCFG空间的空间配置在4GB以下的位置,使得CPU能够访问到。需要说明的是,本实施例及以下各实施例中,“访问”某个空间包括对某个空间的读以及写。“访问某个空间”也可以称为“访问某个地址空间”,或者“访问某个地址”,为了说明方便,本实施例及以及各实施例中并不严格区分这些表述。
以大规模CC-NUMA系统为32路为例,假设该节点为4路(即包括4个CPU),则该节点启动时,每个节点需使用的MMCFG空间的大小为一个segment(分段),共需要8个segment;一个segment占256兆字节(mega bytes,MB),32路的MMCFG空间则需要2GB(8×256MB)。
那么,在4GB以下为各个节点分配256MB大小的MMCFG空间,共2GB大小,地址空间分配如下图2所示。
根据图2所示的地址空间的分配,4GB以下的存储空间被MMCFG占用2GB,再保证系统功能所需之后,MMIO空间只有704MB(3GB+256MB~3GB+960MB)可供分配给32颗CPU使用;由于MMIO空间的分配粒度最小为16MB,704MB分配给32颗CPU使用,每个CPU只能分配16MB的MMIO空间。在这种情况下,对于需要MMIO空间超过8MB的部分PCIE设备,每个CPU最多能支持1个类似的PCIE设备,限制了产品的应用;若存在需要MMIO空间超过16MB的PCIE卡,CPU将不能支持,影响了PCIE设备的兼容性。随着x86大规模CC-NUMA系统处理器数量的增加,占用的4GB以下的MMCFG空间随之增加,挤压了MMIO的空间和4G以下的可用内存的地址空间,限制了PCIE设备的使用。
本申请实施例提供的BIOS启动方法用于大规模CC-NUMA系统中的一个节点的BIOS启动,该启动方法可以由BIOS启动装置来执行,该BIOS启动装置可以包括大规模CC-NUMA系统中的一个节点的部分或全部处理器;其中,所述大规模CC-NUMA系统中的节点可以为主节点或者附属节点。其中,主节点是指能够在后续节点合并步骤中进行统一控制管理的节点,除主节点外的其他节点称为附属节点。
本申请实施例中,BIOS启动装置位于CC-NUMA系统中的本节点(即“本地节点”),本节点可以为CC-NUMA系统中的主节点或者任意一个附属节点。BIOS启动装置可以包括本节点中的部分或全部处理器。如图3所示,本实施例中的BIOS启动装置包括处理器301、存储器302以及通信总线303。
处理器301可以是本节点中的一个或多个CPU,用于通过读取存储器的存储的程序代码执行相应的程序;
存储器302可以包括跟一个或多个CPU分别对应的物理内存及一些非易失性存储介质(如flash、磁盘等),用于存储程序代码以及程序运行过程中所产生的各种数据;
通信总线303用于完成处理器与存储器及其他设备(图3中未示出)之间的通信,通信总线可以是工业标准体系结构(Industry Standard Architecture,ISA)总线、外部设备互连(Peripheral Component,PCI)总线或扩展工业标准体系结构(Extended Industry Standard Architecture,EISA)总线等。该总线303可以分为地址总线、数据总线、控制总线等。为便于表示,图3中仅用一条粗线表示,但并不表示仅有一根总线或一种类型的总线。
实施例一
参见图4,本申请实施例一种BIOS启动方法,由本节点执行,包括:
S401、进入第一访问模式,在第一访问模式下,本节点访问的最大地址为第一地址;在第一访问模式下执行如下S402至S407的步骤;
本实施例中,“访问模式”是指处理器(CPU)通过一定位数的总线进行寻址的方式,例如,现有技术通常通过32位或者64位总线进行寻址。本实施例中,第一访问模式所能寻址到的最大空间要小于后文所要介绍到的第二访问模式所能寻址到的最大空间。例如,本实施例中,第一访问模式为32位访问模式,即通过32位总线进行寻址,最大寻址空间(也即步骤S401中的“第一地址”)为4GB,相应地,第二访问模式可以是64位或者其他位数(比32位大)的访问模式。
S402、在本节点的本地访问地址为第一地址以下的空间中,分配本节点的本地MMCFG空间;
其中,本节点的本地MMCFG空间为连续的空间。由于本节点可以包括一个或多个CPU,当有多个CPU时,这些CPU所对应的本地MMCFG空间为连续的空间。
可选的,一个大规模CC-NUMA系统中,每个节点在S402中分配置的本地MMCFG空间,地址可以相同,也可以不同;在实际应用中,可以根据实际需求确定,本申请对此不进行具体限定。
S403、通过访问本节点的本地MMCFG空间进行内存初始化;
可选的,在执行S403进行内存初始化时,可以是本节点中的主CPU的一个自引导处理器(Boot Strap Processor,BSP)唤醒其他CPU(具体也是唤醒其他CPU中的一个BSP),让其他CPU来进行各自的内存初始化。其中,BSP可认为是一个CPU中的一个核,该核在CPU上电后通过竞争方式获得代码的执行权,具体实现方式也属于现有技术,这里不再赘述。
内存初始化即本节点中的每个CPU通过读写本节点的本地MMCFG空间(包括内存控制器的寄存器空间)的方式,对连接自身对应的一个或多个物理内存进行侦测,获取连接的内存的基本信息(容量、频率、时序等),然后对连接的内存进行配置(包括配置内存控制器以及内存本身)。
可选的,在执行S403进行内存初始化时,可以是本节点中的主CPU的 BSP通过串行(也称“单线程”,由主CPU的BSP来完成其他CPU的内存初始化)或并行(也称“多线程”,由主CPU的BSP唤醒其他CPU的BSP去完成内存初始化)的方式进行。本实施例对于内存初始化的内容及实现过程均为现有技术,本实施例不再赘述。
S404、在完成内存初始化后,进行系统的内存统一编址,分配本节点的MMCFG空间在系统的全局访问地址中的地址;其中,本节点的MMCFG空间全部或部分在全局访问地址为第一地址以上且能够在第二访问模式下被访问到的空间;
这里的“全局访问地址”是个统一编址的地址,各个节点的各个CPU都通过这个统一编址的地址来访问各种设备(如寄存器、外设、物理内存等)。
进一步的,在进行内存统一编址时,分配的CC-NUMA系统中所有节点的MMCFG空间在全局访问地址中的地址相互不重叠,也就是说,每个节点的MMCFG空间在全局访问地址中的地址不可访问冲突。
进一步的,CC-NUMA系统中每个节点的MMCFG空间在全局访问地址中的地址连续。这样访问起来更有规律,即便于统一访问。
S405、在系统的全局访问地址中为本节点分配MMIO空间;
具体的,可以根据节点连接的外设支持的访问地址,为本节点分配在全局访问地址中,本节点的外设支持的访问地址,作为本节点的MMIO空间。
可选的,为本节点分配的MMIO空间,可以在系统的全局访问地址中第一地址以下,或者,也可以在系统的全局访问地址中第一地址以上,本申请实施例对此不进行具体限定。
进一步的,由于系统中节点的MMCFG空间在全局访问地址中的地址已经部分或全部配置在系统的全局访问地址为第一地址以上且能够在第二访问模式下被访问到的空间,因此,系统的全局访问地址第一地址以下的存储空间中有大量的空间可分配为MMIO空间。
S406、与系统中的至少一个其他节点进行交互,完成系统的节点合并,构成完整系统;
各个节点一开始都是各自启动的,并没有相互联系,进行本步骤后,通过节点间的相互交互,可以让其中一个主节点收集到其他各节点的信息,从而可以让主节点来进行统一的控制,从而构成一个完整的系统,这个过程称之为“节点合并”。
可选的,当本节点的类型不同时,执行S406的过程也不同,具体可以包括下述两种情况:
情况1、所述本节点为主节点。
在情况1中,所述与系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统,可以包括:
向本节点所在的大规模CC-NUMA系统中每一个附属节点发送通知消息,所述通知消息用于指示附属节点向所述主节点发送自身的系统信息;
分别接收所述每一个附属节点发送的各自的系统消息,并继续执行剩下 的BIOS启动,并在后续唤醒附属节点并分配相应的任务让附属节点执行。
在另一实施例中,各个节点之间可以通过一些互联芯片(也称节点控制器(Node Controller,NC))来进行互联,以完成相互之间的通信,如何实现为现有技术,这里不再赘述。
情况2、所述本节点为附属节点。
在情况2中,所述与系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统,可以包括:
终止自身的BIOS启动流程,并等待主CPU唤醒,分配相应的任务并执行;
接收主节点发送的用于指示附属节点向主节点发送自身系统信息的通知消息;
向主节点发送自身的系统消息,系统消息用于主节点完成系统节点合并,构成完整系统。
需要说明的是,本申请实施例对于节点合并的过程不进行具体赘述。
进一步可选的,在执行S406时,可以包括:在最后一次访问中央处理器CPU寄存器之后,与系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统。
进一步的,在完成节点合并之后,所有控制将移交至主节点的主CPU的BSP。
S407、进入第二访问模式,在第二访问模式下,本节点所能访问到的地址空间大于在第一访问模式下本节点所能访问到的地址空间。
优选的,在x86系统中,第二访问模式可以为64位模式。
在BIOS阶段中的PEI阶段后期,系统将从第一访问模式进入第二访问模式,可以寻址到系统的全局访问地址中第一地址以上的地址。
可选的,在执行S407之前,所述方法还可以包括:
在本节点的本地访问地址为第一地址(4G)以下的空间中,配置页表,页表指向在第二访问模式中本节点所能访问到且在第一访问模式下本节点不能访问到的地址空间。
示例性的,由于系统管理模式(System Manage Mode,SMM)只支持32位,把节点的MMCFG空间在系统的全局访问地址中的地址分配在4G以上后,SMM中无法访问MMCFG空间,系统功能将不完整,本申请通过在32位空间中建立页表,当进入到64位模式时,通过页表的指示就可以访问在系统的全局访问地址中4G以上的MMCFG空间。
配置页表及通过页表访问系统的全局访问地址中第一地址以上MMCFG空间为现有技术,本实施例不再赘述。
本申请实施例提供的BIOS启动方法,应用于大规模CC-NUMA系统中的主节点或者附属节点,通过在第一访问模式下,本节点在本节点的本地访问地址为第一地址以下的空间中分配本地MMCFG完成内存初始化,在进行系统的内存统一编址时,将部分或全部的本节点的MMCFG空间在系统的全 局访问地址中的地址的位置进行搬移,由原来第一地址以下的空间搬移到第一地址以上且能够在第二访问模式下被访问到的空间,这样,在第二访问模式下,保证CPU仍然能够访问MMCFG空间在系统的全局访问地址中的地址。同时,位于第一地址以下的、通过搬移节省出来的空间,就可以留给一些只能在这些空间使用的设备(例如,留出更多的MMIO空间给只能在4GB以下访问的PCIE卡使用,留出更多的可用内存空间供系统使用),即使CC-NUMA系统包含的CPU数量不断扩展,MMCFG空间在系统的全局访问地址中的地址可以不占用第一地址以下的空间,从而能够支持更多的PCIE设备,因此,实现了在大规模的CC-NUMA系统包含的CPU数量扩展的前提下,BIOS启动不影响MMIO空间及可用内存空间在低位地址中的可用空间,提高了大规模的CC-NUMA系统PCIE设备及操作系统的兼容性。
实施例二
基于上述各实施例,本实施例对实施例一中的步骤S402进行具体说明。
示例性的,如图5所示,示例本节点中包括4个CPU,分别记录为CPU0、CPU1、CPU2、CPU3,为每一个CPU分配64千字节(kilobyte,KB)大小的本地MMCFG空间,分配结果如下:CPU0分配2G~2G+64M的MMCFG空间;CPU1分配2G+64M~2G+64M+64M的MMCFG空间;其余依此类推。
这样一来,4个CPU的本地MMCFG空间连续,CPU0访问2G+64M的地址时就会访问到CPU1的MMCFG空间,则可以操作CPU1的控制与状态寄存器(Control and Status Register,CSR)寄存器。CPU1访问2G的地址时就会访问到CPU0的MMCFG空间,操作CPU0的CSR寄存器。其余类推。实现本节点任意CPU可以访问节点内其余CPU的CSR寄存器。
具体的,分配本节点的本地MMCFG空间,可以通过配置寄存器来实现。
其中,本节点可以通过配置MMCFG_Rule寄存器在本节点的本地访问地址为第一地址以下的空间中,分配一段空间作为一个节点的本地MMCFG空间,通过配置MMCFG_Target_LIST寄存器,设置通过配置MMCFG_Rule寄存器分配的本地MMCFG空间为本节点的本地MMCFG空间。
示例性的,MMCFG_Rule是CPU中用于设置MMCFG空间的寄存器,在BIOS启动阶段通过BIOS代码设置MMCFG_Rule寄存器的Base Address(基地址)域段指定空间的起始地址,Length(长度)域段指定空间的大小、Rule Enable(规则使能)指定该规则是否有效。
MMCFG_Target_LIST寄存器的Package0~7域段指定MMCFG空间对应的节点标识Node ID,以实现分配的本地MMCFG空间是哪个节点的本地MMCFG空间。
示例性的,下面举例说明图5示例的分配的本节点的本地MMCFG空间,如何通过配置寄存器实现。具体的,其实现过程是对CPU的寄存器eax,xmm2,xmm3,xmm4,xmm5进行配置。
具体的设置过程可以如下:
mov eax,DEFAULT_COLDBOOT_MMCFG_TARGET_LIST
movd xmm2,eax
mov eax,DEFAULT_COLDBOOT_MMCFG_RULE
movd xmm3,eax
mov eax,DEFAULT_COLDBOOT_IIO_BUS_NUMS
movd xmm4,eax
mov eax,DEFAULT_COLDBOOT_UNCORE_BUS_NUMS
movd xmm5,eax
需要说明的是,上述示例中为本节点分配的本地MMCFG空间的基地址(Base Address)为2GB,仅为举例说明,并不是对Base Address的取值的具体限定。在实际应用中,基地址可以根据实际需求变换。
还需要说明的是,上述示例仅以举例的形式说明S402的一种实现手段,并不是对S402的执行方式的具体限定。
实施例三
基于上述各实施例,本实施例对上述实施例中的步骤S404进行具体说明。
示例性的,本节点可以通过配置DRAM Rule寄存器,分配MMCFG空间在全局访问地址中的地址,可以通过配置INTERLEAVE_LIST寄存器设置通过DRAM Rule寄存器分配的MMCFG空间在全局访问地址中的地址为本节点的MMCFG空间。
其中,DRAM Rule寄存器用于从0MB地址至内存最大可寻址空间的地址分配。
具体的,通过设置DRAM_RULE_0~19寄存器的Limit域段指定空间上限地址,attr域段指定空间用于DRAM还是MMCFG空间,RULE_ENABLE域段指定该规则是否有效分配节点内CPU的内存空间。
示例性的,以大规模CC-NUMA系统为32路系统,第一访问模式为32位模式,第一地址为4GB,本节点为Node0节点,Node0中包括4颗CPU,在全局访问地址中4GB以上的位置为Node0的CPU分配共256MB的MMCFG空间。当切换到64bit模式后,读取全局访问地址中Node0的MMCFG空间存取CPU的CSR。
具体的,配置寄存器内容如下表1示意,为Node0分配了32太字节(Trillion byte,TB)+4GB~32TB+4GB+256MB共256MB的MMCFG空间在全局访问地址中的地址,其他节点的MMCFG空间在全局访问地址中的地址为32TB+4GB+256MB~32TB+4GB+2GB。该示例分配的大规模CC-NUMA系统中8个节点的MMCFG空间在全局访问地址中的地址如图6所示。
表1
Figure PCTCN2017079627-appb-000001
Figure PCTCN2017079627-appb-000002
需要说明的是,上述示例中为系统中的节点分配的MMCFG空间在全局访问地址中的基地址32T+4G,仅为举例说明,并不是对基地址的取值的具体限定。在实际应用中,基地址可以根据实际需求变换。
其中,表1中除了包括分配系统中节点的MMCFG空间在全局访问地址中的寄存器配置,还包括其他寄存器配置;其他寄存器的配置,是根据系统规则配置的,表1只是举例说明,并不是具体限定。
需要说明的是,表1的寄存器配置,只是以举例的形式,对通过配置寄存器在分配MMCFG空间在全局访问地址中的地址的示例说明,并不是对此过程的具体限定。
示例性的,通过对INTERLEAVE_LIST_0~N寄存器的Package0~7域段设置,用于指定对每个DRAM_RULE寄存器分配的MMCFG空间指向的节点标识Node ID。
还需要说明的是,上述示例仅以举例的形式说明S404的一种实现手段,并不是对S404的执行方式的具体限定。
进一步的,在执行S404时,需要将本节点的MMCFG空间在系统的全局访问地址中的地址分配在在全局访问地址为第一地址以上且能够在第二访问模式下被访问到的空间,而当前在第一访问模式,因此,此时本节点无法访问本节点的MMCFG空间,主节点可以将其本地MMCFG保留,系统中的所有节点通过访问主节点的MMCFG空间,进行系统的内存统一编址,分别分配每个节点的MMCFG空间在系统的全局访问地址中的地址。
进一步的,若所述本节点为主节点,在执行S404之前,所述方法还可以包括:
保留主节点的本地MMCFG空间,用于系统内的每个节点进行系统的内存统一编址分配每个节点的MMCFG空间在系统的全局访问地址中的地址。
进一步的,保留的第一地址以下的主节点的本地MMCFG空间,除了可以用于系统内的每个节点进行系统的内存统一编址分配每个节点的MMCFG空间在系统的全局访问地址中的地址,还可以当有一些驱动程序要在第一访问模式下访问一些硬件设备配置寄存器,只能访问第一地址以下的空间时使用,用于提高访问MMCFG时的系统兼容性。
具体的,假设第一地址为4GB以下,第一访问模式为32位模式,保留的4GB以下的主节点的本地MMCFG空间,除了可以用于系统内的每个节点进行系统的内存统一编址分配每个节点的MMCFG空间在系统的全局访问地址中的地址,还可以当有一些驱动程序要在32位模式下访问一些硬件设备配置寄存器只能访问4GB以下空间时使用,很好的提高了访问MMCFG时的系统兼容性。
具体的,访问MMCFG的方式包括多种(寄存器方式、端口方式等等),其中一些访问方式仅支持第一地址以下的空间访问(例如端口方式),因此,保留的第一地址以下的主节点的本地MMCFG空间,可以兼顾这些仅支持第一地址以下的空间访问的访问方式,提高了访问MMCFG时的系统兼容性。
实施例四
基于上述各实施例,本实施例对上述实施例中的步骤S405进行具体说明。
示例性的,可以通过配置MMIO Rule0~15,MMIO_Target_LIST_0,MMIO_Target_LIST_1寄存器将各个节点的MMIO空间在系统的全局访问地址中第一地址以下的地址空间中,进行统一编址,大大提高多路系统的PCIE设备兼容性。
其中,MMIO Rule寄存器用于为每个CPU分配MMIO空间。通过设置MMIO Rule寄存器的Base address域段指定空间基地址,Limit address域段指定空间上限地址,Rule_Enable指定该规则是否有效。
通过配置MMIO_Target_LIST_0寄存器域段Package0~7指定MMIO_RULE寄存器设置的MMIO区间属于哪个节点,用节点标识Node ID体现。
需要说明的是,各个CPU间可以自由调整MMIO空间大小,MMIO空间的基地址亦可以在系统的全局访问地址中第一地址以下变化,也可以在系统的全局访问地址中第一地址以上变化,本申请对此均不进行具体限定。
示例性的,假设第一访问模式为32位模式,在系统的全局访问地址中4GB以下的空间,为32路CC-NUMA系统中节点0的4个CPU分配MMIO空间;其中,为节点0分配了2GB+256MB~2GB+640MB共384MB的MMIO空间,配置的MMIO_RULE寄存器各域段内容如表2所示,该示例分配的 MMIO空间如图7所示。
表2
寄存器标识 Base address Limita ddress Enable
MMIO_RULE6 2GB+976MB 2GB+992MB 1
MMIO_RULE5 2GB+960MB 2GB+976MB 1
MMIO_RULE4 2GB+640MB 2GB+960MB 1
MMIO_RULE3 2GB+608MB 2GB+640MB 1
MMIO_RULE2 2GB+576MB 2GB+608MB 1
MMIO_RULE1 2GB+512MB 2GB+576MB 1
MMIO_RULE0 2GB+256MB 2GB+512MB 1
其中,在表2中,MMIO_RULE0至MMIO_RULE3的配置,用于为节点0分配MMIO空间,MMIO_RULE4~MMIO_RULE6的配置是根据系统规则配置,且通过配置MMIO_Target_LIST_0寄存器域段Package4~6指定MMIO_RULE寄存器设置的MMIO区间指向NC,使得后续由NC来进行处理,从而实现节点间的互连。
需要说明的是,表2的寄存器配置,只是以举例的形式,对通过配置寄存器在系统的全局访问地址中4GB以下的存储空间分配MMIO空间的示例说明,并不是对此过程的具体限定。
示例性的,以大规模CC-NUMA系统为32路,4路基于一个节点进行BIOS启动,根据上述S401~S405中的示例,执行本申请的方案,统一编址后,系统的全局访问地址的分配结果可以如图8所示。
实施例五
基于上述各实施例,本申请实施例提供另一种BIOS启动装置90,所述启动装置90包括于本节点,所述本节点为CC-NUMA系统中的主节点或者附属节点中,所述CC-NUMA系统包括一个主节点及至少一个附属节点。
如图9所示,所述启动装置90可以包括:
模式单元901,用于控制所述系统进入第一访问模式,其中,在所述第一访问模式下,所述本节点访问的最大地址为第一地址。
分配单元902,用于在第一访问模式下,在本节点的本地访问地址为所述第一地址以下的空间中,分配本节点的本地MMCFG空间。
初始化单元903,用于通过访问分配单元902分配的本节点的本地MMCFG空间进行内存初始化。
所述分配单元902还用于,在初始化单元903完成内存初始化后,进行系统的内存统一编址,分配本节点的MMCFG空间在系统的全局访问地址中的地址;其中,本节点的MMCFG空间全部或部分在全局访问地址为第一地址以上且能够在第二访问模式下被访问到的空间。
所述分配单元902还用于,在系统的全局访问地址中为本节点分配MMIO空间。
合并单元904,用于与系统中的至少一个其他节点进行交互,完成系统 的节点合并,构成完整系统。
优选的,所述第一地址可以为4GB。
进一步的,所述分配单元902具体可以用于:
通过访问主节点的本地MMCFG空间,进行系统的内存统一编址分配本节点的MMCFG空间在系统的全局访问地址中的地址。
如图10所示,所述启动装置90还可以包括:
配置单元905,用于在模式单元901控制系统从第一访问模式进入所述第二访问模式之前,在本节点的本地访问地址为第一地址以下的空间中,配置页表,页表指向在第二访问模式中所述本节点所能访问到且在第一访问模式下本节点不能访问到的地址空间。
访问单元906,用于在所述模式单元901控制系统从第一访问模式进入第二访问模式后,按照配置单元905配置的页表访问本节点的MMCFG空间在所述系统的全局访问地址中的地址。
进一步的,所述CC-NUMA系统中每个节点的MMCFG空间在所述系统的全局访问地址中的地址相互不重叠。
进一步的,所述CC-NUMA系统中每个节点的MMCFG空间在所述系统的全局访问地址中的地址连续;其中,一个节点的MMCFG空间在所述系统的全局访问地址中的地址的首地址是另一个节点的MMCFG空间在所述系统的全局访问地址中的地址的尾地址。
可选的,所述本节点为所述主节点,所述合并单元904具体可以用于:
向所述CC-NUMA系统中每一个附属节点发送通知消息,所述通知消息用于指示附属节点向所述主节点发送自身的系统信息;
分别接收所述每一个附属节点发送的各自的系统消息,完成系统的节点合并,构成完整系统。
可选的,所述本节点为所述附属节点,所述合并单元904具体用于:
终止自身的BIOS流程;
接收所述主节点发送的用于指示附属节点向所述主节点发送自身系统信息的通知消息;
向所述主节点发送自身的系统消息,所述系统消息用于所述主节点完成所述系统的节点合并,构成完整系统。
进一步的,所述合并单元904具体可以用于:
在最后一次访问CPU寄存器之后,与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统。
跟前述实施例一样,通过本申请实施例,可以留出更多4GB以下的空间供节点的外设(如PCIE卡)使用,提高了大规模的CC-NUMA系统对外设的兼容性。
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理包括,也可以两个或两个以上的位置单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用硬件加软件功能单元的形式实现。
上述以软件功能单元的形式实现的集成的单元,可以存储在一个计算机可读取存储介质中。上述软件功能单元存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例所述方法的部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。
最后应说明的是:以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围。

Claims (18)

  1. 一种基本输入/输出系统BIOS启动方法,其特征在于,应用于本节点,所述本节点为大规模缓存一致性非均匀访存架构CC-NUMA系统中的主节点或者附属节点,所述系统包括一个主节点及至少一个附属节点,所述方法包括:
    进入第一访问模式,其中,在所述第一访问模式下,所述本节点访问的最大地址为第一地址,在所述第一访问模式下执行如下步骤:
    在所述本节点的本地访问地址为所述第一地址以下的空间中,分配所述本节点的本地内存映射配置MMCFG空间;
    通过访问所述本节点的本地MMCFG空间进行内存初始化;
    在完成内存初始化后,进行所述系统的内存统一编址分配所述本节点的MMCFG空间在所述系统的全局访问地址中的地址;其中,所述本节点的MMCFG空间全部或部分在所述全局访问地址为第一地址以上且能够在第二访问模式下被访问到的空间;
    在所述系统的全局访问地址中为所述本节点分配内存映射输入输出MMIO空间;
    与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统;
    进入所述第二访问模式,其中,在所述第二访问模式下,所述本节点所能访问到的地址空间大于在所述第一访问模式下所述本节点所能访问到的地址空间。
  2. 根据权利要求1所述的方法,其特征在于,所述第一地址为4千兆字节GB。
  3. 根据权利要求1或2所述的方法,其特征在于,所述进行所述系统的内存统一编址分配所述本节点的MMCFG空间在所述系统的全局访问地址中的地址,包括:
    通过访问所述主节点的本地MMCFG空间,进行所述系统的内存统一编址分配所述本节点的MMCFG空间在所述系统的全局访问地址中的地址。
  4. 根据权利要求1-3任一项所述的方法,其特征在于,在所述进入所述第二访问模式之前,所述方法还包括:
    在所述本节点的本地访问地址为所述第一地址以下的空间中,配置页表,所述页表指向在所述第二访问模式中所述本节点所能访问到且在所述第一访问模式下所述本节点不能访问到的地址空间;
    在所述进入所述第二访问模式后,所述方法还包括:
    按照所述页表访问所述本节点的MMCFG空间在所述系统的全局访问地址中的地址。
  5. 根据权利要求1-4任一项所述的方法,其特征在于,所述CC-NUMA系统中每个节点的MMCFG空间在所述系统的全局访问地址中的地址相互不重叠。
  6. 根据权利要求1-5任一项所述的方法,其特征在于,所述CC-NUMA 系统中每个节点的MMCFG空间在所述系统的全局访问地址中的地址连续;其中,一个节点的MMCFG空间在所述系统的全局访问地址中的地址的首地址是另一个节点的MMCFG空间在所述系统的全局访问地址中的地址的尾地址。
  7. 根据权利要求1-6任一项所述的方法,其特征在于,若所述本节点为所述主节点,所述与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统,包括:
    向所述CC-NUMA系统中每一个附属节点发送通知消息,所述通知消息用于指示附属节点向所述主节点发送自身的系统信息;
    分别接收所述每一个附属节点发送的各自的系统消息,完成所述系统的节点合并,构成完整系统。
  8. 根据权利要求1-7任一项所述的方法,其特征在于,若所述本节点为所述附属节点,所述与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统,包括:
    终止自身的BIOS流程;
    接收所述主节点发送的用于指示附属节点向所述主节点发送自身系统信息的通知消息;
    向所述主节点发送自身的系统消息,所述系统消息用于所述主节点完成所述系统的节点合并,构成完整系统。
  9. 根据权利要求1-8任一项所述的方法,其特征在于,所述与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统,包括:
    在最后一次访问中央处理器CPU寄存器之后,与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统。
  10. 一种基本输入/输出系统BIOS启动装置,其特征在于,所述启动装置包括于本节点,所述本节点为大规模缓存一致性非均匀访存架构CC-NUMA系统中的主节点或者附属节中,所述CC-NUMA系统包括一个主节点及至少一个附属节点,所述启动装置包括:
    模式单元,用于控制所述系统进入第一访问模式,其中,在所述第一访问模式下,所述本节点访问的最大地址为第一地址;
    分配单元,用于在所述第一访问模式下,在所述本节点的本地访问地址为所述第一地址以下的空间中,分配所述本节点的本地内存映射配置MMCFG空间;
    初始化单元,用于通过访问所述分配单元分配的所述本节点的本地MMCFG空间进行内存初始化;
    所述分配单元还用于,在所述初始化单元完成内存初始化后,进行所述系统的内存统一编址分配所述本节点的MMCFG空间在所述系统的全局访问地址中的地址;其中,所述本节点的MMCFG空间全部或部分在所述全局访问地址为第一地址以上且能够在第二访问模式下被访问到的空间;
    所述分配单元还用于,在所述系统的全局访问地址中为所述本节点分配内 存映射输入输出MMIO空间;
    合并单元,用于与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统;
    所述模式单元还用于,控制所述系统从所述第一访问模式进入所述第二访问模式,其中,在所述第二访问模式下,所述本节点所能访问到的地址空间大于在所述第一访问模式下所述本节点所能访问到的地址空间。
  11. 根据权利要求10所述的装置,其特征在于,所述第一地址为4千兆字节GB。
  12. 根据权利要求10或11所述的装置,其特征在于,所述分配单元具体用于:
    通过访问所述主节点的本地MMCFG空间,进行所述系统的内存统一编址分配所述本节点的MMCFG空间在所述系统的全局访问地址中的地址。
  13. 根据权利要求10-12任一项所述的装置,其特征在于,所述装置还包括:
    配置单元,用于在所述模式单元控制所述系统从所述第一访问模式进入所述第二访问模式之前,在所述本节点的本地访问地址为所述第一地址以下的空间中,配置页表,所述页表指向在所述第二访问模式中所述本节点所能访问到且在所述第一访问模式下所述本节点不能访问到的地址空间;
    访问单元,用于在所述模式单元控制所述系统从所述第一访问模式进入所述第二访问模式后,按照所述配置单元配置的页表访问所述本节点的MMCFG空间在所述系统的全局访问地址中的地址。
  14. 根据权利要求10-13任一项所述的装置,其特征在于,所述CC-NUMA系统中每个节点的MMCFG空间在所述系统的全局访问地址中的地址相互不重叠。
  15. 根据权利要求10-14任一项所述的装置,其特征在于,所述CC-NUMA系统中每个节点的MMCFG空间在所述系统的全局访问地址中的地址连续;其中,一个节点的MMCFG空间在所述系统的全局访问地址中的地址的首地址是另一个节点的MMCFG空间在所述系统的全局访问地址中的地址的尾地址。
  16. 根据权利要求10-15任一项所述的装置,其特征在于,若所述本节点为所述主节点,所述合并单元具体用于:
    向所述CC-NUMA系统中每一个附属节点发送通知消息,所述通知消息用于指示附属节点向所述主节点发送自身的系统信息;
    分别接收所述每一个附属节点发送的各自的系统消息,完成所述系统的节点合并,构成完整系统。
  17. 根据权利要求10-16任一项所述的装置,其特征在于,若所述本节点为所述附属节点,所述合并单元具体用于:
    终止自身的BIOS流程;
    接收所述主节点发送的用于指示附属节点向所述主节点发送自身系统信息的通知消息;
    向所述主节点发送自身的系统消息,所述系统消息用于所述主节点完成所述系统的节点合并,构成完整系统。
  18. 根据权利要求10-17任一项所述的装置,其特征在于,所述合并单元具体用于:
    在最后一次访问中央处理器CPU寄存器之后,与所述系统中的至少一个其他节点进行交互,完成所述系统的节点合并,构成完整系统。
PCT/CN2017/079627 2016-04-20 2017-04-06 一种bios启动方法及装置 WO2017181851A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP17785336.3A EP3438816B1 (en) 2016-04-20 2017-04-06 Bios starting method and device
US16/165,398 US10719333B2 (en) 2016-04-20 2018-10-19 BIOS startup method and apparatus

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201610248616.X 2016-04-20
CN201610248616.XA CN105867945B (zh) 2016-04-20 2016-04-20 一种bios启动方法及装置

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US16/165,398 Continuation US10719333B2 (en) 2016-04-20 2018-10-19 BIOS startup method and apparatus

Publications (1)

Publication Number Publication Date
WO2017181851A1 true WO2017181851A1 (zh) 2017-10-26

Family

ID=56633625

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/079627 WO2017181851A1 (zh) 2016-04-20 2017-04-06 一种bios启动方法及装置

Country Status (4)

Country Link
US (1) US10719333B2 (zh)
EP (1) EP3438816B1 (zh)
CN (1) CN105867945B (zh)
WO (1) WO2017181851A1 (zh)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105867945B (zh) * 2016-04-20 2018-11-16 华为技术有限公司 一种bios启动方法及装置
CN107748677A (zh) * 2017-10-17 2018-03-02 岳西县天鹅电子科技有限公司 一种计算机快速启动及执行程序的方法
CN108153553A (zh) * 2018-01-23 2018-06-12 郑州云海信息技术有限公司 一种高端服务器启动方法、系统、装置及计算机存储介质
CN114691223B (zh) * 2022-03-21 2023-08-22 深圳市同泰怡信息技术有限公司 一种通过网络传输bios日志的方法及装置
CN118316778A (zh) * 2024-04-08 2024-07-09 无锡众星微系统技术有限公司 一种用于ib网卡的uar页面分配方法和装置

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060069906A1 (en) * 2003-10-02 2006-03-30 Zolnowsky Jeffrey D Method and apparatus for BIOS determination of network information and diagnostics
CN103475494A (zh) * 2013-09-12 2013-12-25 华为技术有限公司 Cc-numa系统及其启动的方法
CN103530254A (zh) * 2013-10-11 2014-01-22 杭州华为数字技术有限公司 多节点系统的外部设备互联枚举方法和装置
CN105867945A (zh) * 2016-04-20 2016-08-17 华为技术有限公司 一种bios启动方法及装置

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6336185B1 (en) * 1998-09-24 2002-01-01 Phoenix Technologies Ltd. Use of other processors during BIOS boot sequence to minimize boot time
US7392371B2 (en) * 2001-12-20 2008-06-24 Zimmer Vincent J Method and apparatus for using a volume top file to boot firmware modules
US7552319B2 (en) * 2004-06-30 2009-06-23 Intel Corporation Methods and apparatus to manage memory access
US7779244B2 (en) * 2006-12-28 2010-08-17 Intel Corporation Multi-socket boot
US7689755B2 (en) * 2007-03-07 2010-03-30 Intel Corporation Apparatus and method for sharing devices between multiple execution domains of a hardware platform
US7987352B2 (en) * 2007-11-30 2011-07-26 Intel Corporation Booting with sub socket partitioning
US9880858B2 (en) * 2015-06-25 2018-01-30 Dell Products L.P. Systems and methods for reducing BIOS reboots
US10289431B2 (en) * 2016-10-01 2019-05-14 Intel Corporation Technologies for reduced control and status register access latency

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060069906A1 (en) * 2003-10-02 2006-03-30 Zolnowsky Jeffrey D Method and apparatus for BIOS determination of network information and diagnostics
CN103475494A (zh) * 2013-09-12 2013-12-25 华为技术有限公司 Cc-numa系统及其启动的方法
CN103530254A (zh) * 2013-10-11 2014-01-22 杭州华为数字技术有限公司 多节点系统的外部设备互联枚举方法和装置
CN105867945A (zh) * 2016-04-20 2016-08-17 华为技术有限公司 一种bios启动方法及装置

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP3438816A4 *

Also Published As

Publication number Publication date
EP3438816B1 (en) 2021-06-09
EP3438816A1 (en) 2019-02-06
US20190050240A1 (en) 2019-02-14
US10719333B2 (en) 2020-07-21
CN105867945B (zh) 2018-11-16
EP3438816A4 (en) 2019-04-17
CN105867945A (zh) 2016-08-17

Similar Documents

Publication Publication Date Title
WO2017181851A1 (zh) 一种bios启动方法及装置
US9760497B2 (en) Hierarchy memory management
CN112099941B (zh) 实现硬件加速处理的方法、设备和系统
CN112540941B (zh) 一种数据转发芯片及服务器
JP6329318B2 (ja) 情報処理装置
KR101090651B1 (ko) 가상 머신 모니터 및 멀티프로세서 시스템
US8078862B2 (en) Method for assigning physical data address range in multiprocessor system
CN105264506B (zh) 向内存映射配置分配处理器
US8918568B2 (en) PCI express SR-IOV/MR-IOV virtual function clusters
KR100515229B1 (ko) 멀티프로세서 시스템에서 가상화된 물리적 메모리를관리하는 방법 및 시스템
US11467776B1 (en) System supporting virtualization of SR-IOV capable devices
EP4123649A1 (en) Memory module, system including the same, and operation method of memory module
US20180136868A1 (en) Translation bypass by host iommu for systems with virtual iommu
US20190227753A1 (en) System, Apparatus And Method For Sharing A Flash Device Among Multiple Masters Of A Computing Platform
TWI785320B (zh) 裝置內標記資料移動系統、資訊處置系統及用於提供裝置內標記資料移動之方法
US10838861B1 (en) Distribution of memory address resources to bus devices in a multi-processor computing system
US11150928B2 (en) Hypervisor translation bypass
CN116324706A (zh) 分离式存储器池分配
US10936219B2 (en) Controller-based inter-device notational data movement system
US20240126469A1 (en) Apparatus and method for controlling a pooled memory device or a memory expander
JP2018113075A (ja) 情報処理装置
US11281612B2 (en) Switch-based inter-device notational data movement system
EP4276642A1 (en) Computing system including cxl switch, memory device and storage device and operating method thereof
TW202340931A (zh) 具有雜訊鄰居緩解及動態位址範圍分配的直接交換快取
KR20230157187A (ko) Cxl 스위치, 메모리 장치 및 스토리지 장치를 포함하는 컴퓨팅 장치 및 이의 동작 방법

Legal Events

Date Code Title Description
NENP Non-entry into the national phase

Ref country code: DE

WWE Wipo information: entry into national phase

Ref document number: 2017785336

Country of ref document: EP

ENP Entry into the national phase

Ref document number: 2017785336

Country of ref document: EP

Effective date: 20181101

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17785336

Country of ref document: EP

Kind code of ref document: A1