A server PCIe resource adaptive configuration method

Through the collaborative interaction between the motherboard-side and component-side CPLDs, adaptive configuration of server PCIe resources is achieved using UBC cables, solving the problems of BIOS customization dependence and low resource utilization in existing technologies, and realizing efficient and stable PCIe resource management.

CN122285577APending Publication Date: 2026-06-26四川华鲲振宇智能科技有限责任公司
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
四川华鲲振宇智能科技有限责任公司
Filing Date
2026-05-28
Publication Date
2026-06-26

AI Technical Summary

Technical Problem

Existing server PCIe resource configuration solutions rely on customized BIOS development, which has a long adaptation cycle and is difficult to meet the needs of rapid hardware iteration. The configuration process is not compatible with general server standards, resulting in low resource utilization. Separate processing of cable status monitoring increases the complexity of operation and maintenance, and there is a risk of system startup failure in complex scenarios.

Method used

By using the native sideband communication channel of the UBC cable, the programmable logic devices (CPLDs) on the motherboard and component sides can negotiate and generate a standardized PCIe resource configuration table. The system completes trusted data acquisition and resource arbitration before BIOS initialization, supports hardware-level write protection locking and dynamic optimization, and achieves full lifecycle management.

Benefits of technology

It achieves no-code adaptation, reduces development and maintenance costs, improves configuration success rate and system stability, supports dynamic optimization and hot-swapping, simplifies operation and maintenance processes, and improves resource utilization.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122285577A_ABST
    Figure CN122285577A_ABST
Patent Text Reader

Abstract

This invention discloses a server PCIe resource adaptive configuration method, relating to the fields of server architecture and PCIe high-speed bus configuration technology. Addressing the problems of existing solutions such as reliance on custom BIOS development, timing incompatibility, lack of resource arbitration, inability to dynamically optimize, and operational redundancy, this invention adopts a fully hardware-coordinated architecture of the motherboard and component-side CPLD. It completes time-division reporting of topology data and four-level hardware trusted verification through the native sideband channel of the UBC cable. Through hardware-based resource conflict arbitration and cross-CPU platform register conversion, the configuration table is generated and locked before BIOS PCIe initialization. Simultaneously, it supports OS runtime load monitoring, incremental bandwidth adjustment, and hot-swappable adaptive configuration, combined with parallel cable status alarms and automatic fault rollback mechanisms. This invention eliminates reliance on custom BIOS, is compatible with standard power-on timings, improves configuration stability and resource utilization in complex scenarios, reduces hardware redundancy and operational costs, and is applicable to general server PCIe resource adaptive management.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of server architecture and PCIe high-speed bus configuration technology, specifically relating to a server PCIe resource adaptive configuration method. Background Technology

[0002] With the rapid development of core data center businesses such as cloud computing, AI high-performance computing, and distributed storage, general-purpose server hardware configurations are becoming increasingly diversified. The combination of PCIe peripherals such as front-panel NVMe hard drives, GPU / FPGA accelerator cards, and I / O expansion modules continues to evolve, placing higher demands on the flexibility of CPU PCIe bus resource allocation, cross-scenario adaptability, industrial-grade operational reliability, full-cycle operation and maintenance efficiency, and resource utilization.

[0003] The mainstream implementation of current server PCIe resource configuration mostly uses UEFI BIOS as the core configuration mechanism, which is usually based on a static configuration mode with a preset hardware topology and resource mapping table. In this mode, adapting to specific hardware configurations often requires simultaneous completion of BIOS customization development and image compilation to achieve PCIe resource allocation in the corresponding scenario.

[0004] However, the above-mentioned solutions still face several technical limitations in practical applications. Their configuration logic heavily relies on customized BIOS development. When hardware configurations are added or changed, it is often necessary to simultaneously modify the BIOS code, recompile, and release the image. This results in a long adaptation cycle, high overall development and maintenance costs, and significant obstacles in achieving code-free universal adaptation, making it difficult to fully meet the rapid iteration needs of hardware configurations. Furthermore, the configuration process of such solutions inherently differs from the UEFIPOST timing of general server standards. The generation of PCIe configuration data typically lags behind the critical stages of BIOS PCIe controller initialization and bus enumeration, often requiring deep adjustments to the BIOS core boot process for successful implementation, thus limiting direct adaptation to general server standard images.

[0005] Furthermore, some existing solutions are still imperfect in terms of hardware-level resource conflict arbitration and end-to-end data trust verification mechanisms. In complex scenarios where the total bandwidth demand of multiple peripherals approaches or exceeds the CPU's available resource limit, the risk of configuration failure or even system startup failure increases, potentially impacting the stable operation of industrial-grade data centers. Moreover, most solutions only support one-time static configuration during power-on, making it difficult to meet the dynamic optimization requirements based on business load or link health status during OS operation, and also difficult to support incremental configuration in hot-swappable scenarios. Their responsiveness to the elastic resource demands of cloud computing scenarios is relatively limited, and there is room for improvement in PCIe resource utilization and overall system energy efficiency. Furthermore, existing solutions typically separate PCIe resource configuration from cable status monitoring, requiring the additional deployment of dedicated communication links, resulting in high hardware redundancy. They also lack sufficient support for precise port-level location of typical faults such as incorrect or missing cable connections, increasing the operational complexity in large-scale deployment scenarios.

[0006] Therefore, there is an urgent need in this field for a method that can reduce the reliance on customized BIOS development, be highly compatible with the standard power-on process of general servers, have hardware-level resource arbitration and end-to-end trusted verification capabilities, and support adaptive management of PCIe resources throughout their entire lifecycle, so as to effectively alleviate the prominent contradiction between existing technical solutions and the core needs of the industry and promote the further improvement of the technical level in this field. Summary of the Invention

[0007] The purpose of this invention is to overcome the shortcomings of the prior art and provide a server PCIe resource adaptive configuration method, including the following steps: S1: The programmable logic device on the motherboard side and the programmable logic device on the external component side complete the interactive negotiation through the native sideband communication channel of the UBC cable, and receive standardized data reported by the component side, which includes component topology information and PCIe link configuration requirements. S2: The programmable logic device on the motherboard side verifies and optimizes the standardized data to generate a standardized PCIe resource configuration table adapted to the current server CPU platform, and performs hardware-level write protection locking on the configuration table; the write protection lock can be unlocked by triggering the fault rollback logic and runtime tuning logic inside the programmable logic device on the motherboard side. After unlocking, only internal logic is allowed to modify the configuration table, and the external access interface always maintains read-only permission. S3: Before the server BIOS executes the PCIe controller initialization process, the programmable logic device on the motherboard side sends a configuration ready signal to the BIOS, opening the standard read interface of the PCIe resource configuration table; S4: The server BIOS obtains the PCIe resource configuration table through the standard read interface and completes the initial configuration of the PCIe resources based on the configuration table.

[0008] Preferably, in step S1, the motherboard-side programmable logic device and the external component-side programmable logic device complete interactive negotiation through the native sideband communication channel of the UBC cable, and receive standardized data reported by the component side containing component topology information and PCIe link configuration requirements, including the following steps: S101: After the server is powered on, the programmable logic device on the motherboard side completes initialization and completes handshake interaction with all external component-side programmable logic devices through the native sideband communication channel of the UBC cable to negotiate and generate a unique session key for this power-on. S102: The motherboard-side programmable logic device allocates an independent reporting time slot and communication baud rate to each external component-side programmable logic device based on the number of connected UBC cables and the fixed timing window of the server BIOS PCIe initialization, and generates a time-sharing scheduling instruction to send to the corresponding component-side programmable logic device. S103: The programmable logic device on the component side collects the component topology information fixed in local non-volatile memory and the PCIe link configuration requirements collected in real time by the hardware registers according to the session key generated by negotiation and the time-sharing scheduling instructions issued. It encapsulates the information into a standardized data frame of fixed length and enters the reporting state of time slot synchronization. S104: The programmable logic device on the motherboard side sends a reporting trigger signal to the corresponding programmable logic device on the component side in the order of the pre-allocated time slots, and synchronously receives the standardized data frames reported by the component side through the native sideband communication channel of the UBC cable, thus completing the standardized data reception of all components during this power-on.

[0009] Preferably, in step S104, when the programmable logic device on the motherboard side receives data, it controls the reporting timing of multiple cables through a hardware backpressure mechanism. Before the current cable data is received and the preliminary frame structure is verified, the reporting trigger signal of other cables is blocked.

[0010] Preferably, the programmable logic device on the motherboard side performing verification processing on the standardized data in step S2 includes the following steps: S201: The programmable logic device on the motherboard side performs frame structure legality verification on the received full set of standardized data frames, and filters out format compliant data frames whose frame header, frame tail, and frame length completely match the preset rules. S202: The programmable logic device on the motherboard side performs data integrity verification on the selected format compliant data frames to confirm that there is no tampering or error during the data transmission process, and obtains a complete and valid data frame; S203: The programmable logic device on the motherboard performs a uniqueness check on the complete and valid data frame that has passed the verification, filters duplicate frames and replays frames to obtain a unique and valid data frame without duplicates. S204: The programmable logic device on the motherboard performs configuration boundary validity verification on the unique valid data frame after deduplication, confirms that the configuration parameters in the frame comply with the hardware security rules of the CPU PCIe controller, and obtains standardized valid data that has passed the full process verification.

[0011] Preferably, the programmable logic device on the motherboard side performing resource optimization processing on the standardized data in step S2 includes the following steps: S205: The programmable logic device on the motherboard side summarizes the total PCIe link bandwidth requirements corresponding to all verified standardized data, and synchronously retrieves the total boundary of available resources of the CPU PCIe root port and the component service priority rules that are pre-configured locally. S206: The programmable logic device on the motherboard side allocates PCIe bandwidth resources to each component in descending order of priority according to the retrieved component priority rules, and generates a preliminary bandwidth allocation result. S207: The programmable logic device on the motherboard side performs a total resource boundary check on the generated preliminary bandwidth allocation result. If the total allocated bandwidth exceeds the total boundary of available CPU PCIe resources, unnecessary bandwidth is cut off from low to high priority until the total allocated bandwidth meets the resource boundary requirements. Finally, an initial PCIe resource configuration table without resource conflicts and in accordance with hardware rules is generated.

[0012] Preferably, the step S2 of generating a standardized PCIe resource configuration table adapted to the current server CPU platform includes the following steps: S208: The programmable logic device on the motherboard side identifies the CPU platform model of the current server through hardware pins; S209: The motherboard-side programmable logic device retrieves the pre-integrated PCIe controller specifications and register mapping rules for the corresponding CPU platform; S210: The motherboard-side programmable logic device converts the original parameters in the initial PCIe resource configuration table into standardized register configuration parameters that can be directly recognized by the corresponding CPU platform, and generates the final PCIe resource configuration table.

[0013] Preferably, in step S3, the motherboard-side programmable logic device sends a configuration ready signal to the BIOS before the server BIOS executes the PCIe controller initialization process, opening the standard read interface of the PCIe resource configuration table, including the following steps: S301: After the programmable logic device on the motherboard side completes the hardware-level write protection lock of the final PCIe resource configuration table, it monitors the power-on startup progress of the server BIOS in real time through the motherboard's dedicated GPIO pins to obtain the BIOS's POST stage node information. S302: Based on the obtained BIOS boot phase node information, the motherboard-side programmable logic device sends a continuously valid high-level configuration ready signal to the BIOS through a dedicated hardware GPIO pin at a fixed timing node before the BIOS enters the PCIe controller initialization and bus enumeration process. S303: The motherboard-side programmable logic device synchronously opens the fixed address standard read interface of the corresponding storage area of ​​the PCIe resource configuration table, locks the interface access permission to read-only, and completes the hardware timing coordination preparation with the BIOS initialization process.

[0014] Preferably, in step S4, the server BIOS obtains the PCIe resource configuration table through the standard read interface and completes the initial configuration of the PCIe resources based on the configuration table, including the following steps: S401: When the server BIOS enters the PCIe controller initialization process, after detecting a continuously valid configuration ready signal, it accesses the designated storage area of ​​the programmable logic device on the motherboard side through the corresponding open standard read interface and reads the PCIe resource configuration table after hardware write protection locking. S402: The server BIOS directly extracts standardized register configuration parameters from the PCIe resource configuration table it reads, without having to perform external hardware topology scanning, device enumeration and configuration mapping matching logic; S403: The server BIOS extracts the standardized register configuration parameters and writes them into the corresponding physical registers of the CPU PCIe controller in a preset order, completing the PCIe root port configuration, bus enumeration, and full-link resource initialization configuration.

[0015] Preferably, the method further includes a cable status intelligent alarm step that is executed in parallel with the PCIe configuration process during the server power-on phase, specifically including the following steps: S501: The server BMC obtains verified component topology information from the independently partitioned storage area of ​​the programmable logic device on the motherboard side through a standard read interface shared with the BIOS. S502: The BMC will match and verify the obtained component topology information with the locally stored UBC physical port-component legal mapping rules one by one, and generate port matching verification results. S503: Based on the generated port matching verification results, BMC accurately identifies three types of abnormal states: missing or incorrect cable insertion, and component hardware failure. It triggers real-time alarms of the corresponding level and synchronously records the entire process abnormal log to the BMC management platform.

[0016] Preferably, the method further includes a dynamic optimization step for the entire lifecycle of PCIe resources in OS runtime, specifically including the following steps: S601: During the normal operation of the server OS, the programmable logic device on the motherboard side collects the negotiation rate, bit error rate, and link status health data of each PCIe link in real time according to a preset cycle, and simultaneously receives the service bandwidth utilization rate and load level data of each component reported by the BMC, and summarizes them to obtain the full operation data of the links and load. S602: When the link health data and component load data meet the preset bandwidth adjustment trigger conditions, the motherboard-side programmable logic device generates an incremental bandwidth adjustment configuration table by combining the link bit error rate, negotiation rate and component load level, and simultaneously completes resource conflict verification and CPU platform adaptation conversion to obtain a legal and valid incremental configuration table and execute write protection locking. S603: The motherboard-side programmable logic device triggers the platform runtime processing flow of the server BIOS and OS kernel through the interrupt signal specified by the ACPI standard, based on the generated lock incremental configuration table. S604: The OS kernel, through the platform runtime processing flow triggered by the system, follows the standard PCIe hot-plug specification to complete the bandwidth increment adjustment, update the local configuration table and synchronize it to the programmable logic device on the motherboard side, thus completing dynamic optimization without restarting or service interruption.

[0017] The beneficial effects of this invention are: 1. This invention moves the PCIe configuration decision-making body from the BIOS to the hardware layer through full hardware collaborative interaction between the motherboard and the component-side programmable logic devices based on the UBC sideband channel. It completes trusted data acquisition, resource arbitration and configuration table generation before BIOS initialization, gets rid of the strong dependence on BIOS customization development and image modification, realizes universality and code-free adaptation in multiple hardware configuration scenarios, and reduces server development and maintenance costs.

[0018] 2. This invention adopts a hardware-level four-level data verification and priority bandwidth pruning mechanism, which can automatically identify and handle multi-component PCIe resource conflicts. At the same time, it achieves multi-CPU platform compatibility through cross-platform register mapping conversion, improves the configuration success rate and system startup stability in complex hardware scenarios, and ensures the industrial-grade reliability of the server under high-density peripheral deployment.

[0019] 3. This invention supports real-time monitoring of OS runtime links and loads, incremental configuration, and hot-plug adaptive adjustment. Combined with parallel monitoring of cable status and automatic fault rollback, it realizes adaptive management of PCIe resources throughout their entire lifecycle from power-on initialization to runtime, improving bus resource utilization while reducing operational complexity and system failure risks. Attached Figure Description

[0020] Figure 1 This is an overall flowchart of the PCIe resource adaptive configuration method provided in the embodiments of the present invention; Figure 2This is a flowchart of PCIe configuration data processing and configuration table generation during the power-on phase provided in an embodiment of the present invention; Figure 3 This is a flowchart for dynamic optimization of PCIe resources throughout their entire lifecycle in OS runtime, provided in an embodiment of the present invention. Detailed Implementation

[0021] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described content is only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative effort are within the scope of protection of this application.

[0022] The features and effects of the present invention will be further described in detail below with reference to embodiments.

[0023] In one feasible implementation, such as Figure 1 As shown, a server PCIe resource adaptive configuration method is provided, including the following steps: Step S1: The programmable logic device on the motherboard side and the programmable logic device on the external component side complete the interactive negotiation through the native sideband communication channel of the UBC cable, and receive the standardized data reported by the component side, which includes component topology information and PCIe link configuration requirements. Step S2: The programmable logic device on the motherboard side verifies and optimizes the standardized data to generate a standardized PCIe resource configuration table adapted to the current server CPU platform, and performs hardware-level write protection locking on the configuration table; the write protection lock can be unlocked by triggering the fault rollback logic and runtime optimization logic inside the programmable logic device on the motherboard side. After unlocking, only internal logic is allowed to modify the configuration table, and the external access interface always maintains read-only permission. Step S3: Before the server BIOS executes the PCIe controller initialization process, the programmable logic device on the motherboard side sends a configuration ready signal to the BIOS, opening the standard read interface of the PCIe resource configuration table; Step S4: The server BIOS obtains the PCIe resource configuration table through the standard read interface and completes the initial configuration of the PCIe resources based on the configuration table.

[0024] In this embodiment, both the motherboard-side programmable logic device and the external component-side programmable logic device are complex programmable logic devices (CPLDs), which are standard components for server motherboards and external component boards, requiring no additional hardware. The external components include one or more of the following: server NVMe hard drive backplane, PCIe IO expansion module, GPU accelerator card expansion module, and FPGA accelerator card expansion module, all of which are standard external components for general servers. In this embodiment, the native sideband communication channel of the UBC cable refers to the native UART serial channel reserved for inter-board management communication in cables conforming to the OpenUBCv1.4 and above official specifications. The motherboard-side pins are defined as follows: pin 15 is UART receive (RX), and pin 16 is UART transmit (TX). The corresponding component-side pins are reverse matched, eliminating the need for additional communication cables and fully reusing existing hardware links. The write protection lock refers to the write protection mechanism implemented internally by the CPLD through a synchronous hardware state machine, which includes two levels: Level 1 Write Protection: After the initial configuration table generated during the power-on phase is locked, only the internal fault rollback logic and dynamic tuning logic are allowed to unlock. The external bus (BIOS / BMC / OS) always has only read-only permissions and can only be completely reset by power-down reset. Level 2 write protection: After the incremental configuration table and the rolled-back configuration table are updated, they are immediately relocked, and the external bus can never be modified. At the same time, additional hardware trigger conditions for unlocking are provided (only the internal state machine's fault rollback signal and the tuning completion signal can trigger unlocking, and there is no software trigger entry). This ensures both reliability and compatibility with the needs of rollback and dynamic tuning. The core configuration process of this method is implemented entirely based on CPLD hardware logic, without the need for software intervention from the CPU / BIOS / BMC.

[0025] This embodiment achieves fully hardware-based acquisition, processing, and generation of PCIe configuration data through end-to-end collaboration of dual-end CPLDs based on the native channel of UBC cables. Combined with the pre-configuration locking mechanism before BIOS initialization, it completely eliminates the strong dependence of traditional solutions on customized BIOS code. It can adapt to diverse hardware configuration combinations without modifying the BIOS image, significantly reducing the development and maintenance costs of server PCIe resource configuration, while improving the flexibility and scalability of the configuration scheme.

[0026] In one feasible implementation, the motherboard-side programmable logic device and the external component-side programmable logic device mentioned in step S1 complete interactive negotiation through the native sideband communication channel of the UBC cable, and receive standardized data reported by the component side containing component topology information and PCIe link configuration requirements, including the following steps: Step S101: After the server is powered on, the programmable logic device on the motherboard side completes initialization and completes handshake interaction with all external component-side programmable logic devices through the native sideband communication channel of the UBC cable to negotiate and generate a unique session key for this power-on. Step S102: The motherboard-side programmable logic device allocates an independent reporting time slot and communication baud rate to each external component-side programmable logic device according to the number of connected UBC cables and the fixed timing window of the server BIOS PCIe initialization, and generates a time-sharing scheduling instruction to send to the corresponding component-side programmable logic device. Step S103: The programmable logic device on the component side collects the component topology information fixed in local non-volatile memory and the PCIe link configuration requirements collected in real time by the hardware register according to the session key generated by negotiation and the time-sharing scheduling instructions issued, encapsulates them into a standardized data frame of fixed length, and enters the reporting state of time slot synchronization. Step S104: The programmable logic device on the motherboard side sends a reporting trigger signal to the corresponding programmable logic device on the component side in the order of the pre-allocated time slots, and synchronously receives the standardized data frame reported by the component side through the native sideband communication channel of the UBC cable, thus completing the standardized data reception of all components during this power-on.

[0027] The fixed-length standardized data frame described in step S103 carries component topology information for cable status monitoring and link configuration requirement data for PCIe resource allocation in independent fields within a single frame. The two types of data are stored independently within the same frame and do not interfere with each other.

[0028] In step S104, when the programmable logic device on the motherboard side receives data, it controls the reporting timing of multiple cables through a hardware backpressure mechanism. Before the current cable data is received and the preliminary frame structure is verified, the reporting trigger signal of other cables is blocked.

[0029] In this embodiment, the fixed timing window has a default total duration of no less than 20ms, which can be dynamically adjusted according to the number of access cables. The session key is generated through negotiation using an industrial-grade, universally applicable two-way challenge-response mechanism. The specific process is as follows: After the motherboard CPLD completes power-on initialization, it generates a 16-bit true random challenge code R. M Broadcast to all online CPLD components via the UBC cable sideband channel; Component CPLD received challenge code R M Then, the response code is calculated using a fixed 16-bit left circular shift XOR algorithm, with the following algorithm rules: The initial vector IV is fixed to a preset fixed value, such as 0xA55A (16 bits), and the shift step size is fixed to 4 bits; Step 1: Use the challenge code R M Shift left by 4 bits to obtain the shift value R. S ; Step 2: R S Perform a bitwise XOR operation with the initial vector IV to obtain the 16-bit ACK code; The component CPLD returns the ACK code to the motherboard CPLD. The motherboard CPLD calculates the verification ACK code locally using the same algorithm rules. If it matches the received ACK code, the component's identity is determined to be legitimate. Both parties jointly generate a 16-bit random session key KEY, with the generation rule: KEY=R M ^ACK^IV (^ is the bitwise XOR operator); The generated session key KEY is stored only in the volatile general-purpose registers of both parties' CPLDs. It is automatically cleared to zero when power is off and is not written to any non-volatile storage unit, so there is no risk of key leakage.

[0030] In this embodiment, the independent reporting time slots are in 1ms increments. Based on the number of access cables N, the total timing window before BIOS PCIe initialization is divided into N non-overlapping 1ms time slots. The time slot order corresponds one-to-one with the UBC physical port number. The default communication baud rate uses the UART serial communication standard baud rate, preferably 115200bps. The hardware backpressure mechanism is implemented through a single-frame reception synchronization state machine within the CPLD: when the state machine is in the "receiving" state, it forcibly shuts down the trigger signal output of all other time slots. Only when the state machine jumps to the "receiving complete + preliminary frame structure verification passed" state is the trigger signal of the next time slot enabled, completely avoiding data conflicts from multiple cables at the hardware level. In one implementation, the fixed-length standardized data frame is a fixed length of 16 bytes, fully conforming to the serial communication short frame transmission specification. The complete field definitions are shown in Table 1 below. Table 1: This embodiment establishes a trusted end-to-end communication channel through power-on handshake and unique session key negotiation. Combined with time-slot scheduling and hardware backpressure mechanisms, it completely resolves the data conflict issue caused by parallel reporting from multiple cables. Furthermore, through a standardized data frame design with dual-purpose functionality, it enables simultaneous transmission of configuration and monitoring data over the same link, eliminating the need for additional communication links, simplifying server hardware design, and improving the stability and reliability of data reporting in multi-component scenarios. In one feasible implementation, such as Figure 2 As shown, the programmable logic device on the motherboard side in step S2 performs verification processing on the standardized data, including the following steps: Step S201: The programmable logic device on the motherboard side performs frame structure legality verification on the received full set of standardized data frames, and filters out the format compliant data frames whose frame header, frame tail, and frame length completely match the preset rules; Step S202: The programmable logic device on the motherboard performs a data integrity check on the selected format-compliant data frames to confirm that there is no tampering or omission during the data transmission process, and obtains a complete and valid data frame; Step S203: The programmable logic device on the motherboard performs a data uniqueness check on the complete and valid data frame that has passed the verification, filters duplicate frames and replays frames to obtain a unique and valid data frame without duplicates; Step S204: The programmable logic device on the motherboard performs configuration boundary legality verification on the unique valid data frame after deduplication, confirms that the configuration parameters in the frame comply with the hardware security rules of the CPU PCIe controller, and obtains standardized valid data that has passed the full process verification.

[0031] The motherboard-side programmable logic device performing resource optimization processing on the standardized data in step S2 includes the following steps: Step S205: The programmable logic device on the motherboard side summarizes the total PCIe link bandwidth requirements corresponding to all the standardized data that have passed verification, and synchronously retrieves the total boundary of available resources of the CPU PCIe root port and the component service priority rules that are pre-configured locally. Step S206: The programmable logic device on the motherboard side allocates PCIe bandwidth resources to each component in descending order of priority according to the retrieved component priority rules, and generates a preliminary bandwidth allocation result. Step S207: The programmable logic device on the motherboard performs a total resource boundary check on the generated preliminary bandwidth allocation result. If the total allocated bandwidth exceeds the total boundary of available CPU PCIe resources, unnecessary bandwidth is cut off from low to high priority until the total allocated bandwidth meets the resource boundary requirements. Finally, an initial PCIe resource configuration table without resource conflicts and in accordance with hardware rules is generated.

[0032] Step S2, which involves generating a standardized PCIe resource configuration table adapted to the current server CPU platform, includes the following steps: Step S208: The programmable logic device on the motherboard side identifies the CPU platform model of the current server through hardware pins; Step S209: The programmable logic device on the motherboard side retrieves the pre-integrated PCIe controller specification and register mapping rules for the corresponding CPU platform; Step S210: The programmable logic device on the motherboard side converts the original parameters in the initial PCIe resource configuration table into standardized register configuration parameters that can be directly recognized by the corresponding CPU platform, and generates the final PCIe resource configuration table.

[0033] In this embodiment, a pipelined hardware execution logic is used for end-to-end trust verification of standardized data. Frames that fail the previous stage verification are discarded at the hardware level and do not proceed to subsequent processing stages. Only data that passes the entire process verification can be used as the sole legitimate input for subsequent resource allocation. The preset rules for frame structure validity verification correspond completely to the definition of standardized data frames. Specifically, the frame header is fixed at 0xAA, the frame tail is fixed at 0x55, and the total frame length is fixed at 16 bytes. Only data frames that simultaneously meet all three rules can proceed to subsequent processing, thereby filtering out malformed frames and synchronization failure frames generated during serial transmission and preventing invalid data from consuming processing resources. Data integrity verification uses the IEEE 802.3 Ethernet standard CRC32 algorithm, with the generator polynomial fixed at 0x04C11DB7. By comparing the locally recalculated checksum with the checksum carried in the frame, it is confirmed that the data has not been tampered with, bit-to-bit, or byte-to-byte errors during transmission through the UBC sideband channel. Only data frames with completely matching checksums can proceed to subsequent processing. Data uniqueness verification is achieved by comparing the unique combination of "same UBC physical port + session key negotiated during this power-on + intra-frame incrementing sequence number". Only the first reported valid data is retained for frames with the same combination. Subsequent repeated reports are directly identified as duplicate frames, replay frames and discarded by hardware, thereby solving the data conflict problem in the process of parallel reporting by multiple components.

[0034] In this embodiment, the configuration boundary validity verification sets three verification rules around the inherent hardware boundary of the CPU PCIe controller: the single-port bandwidth configuration does not exceed the maximum bit width of a single port x 16, the total bandwidth requirement of all ports does not exceed the total number of available channels of the root port, and the rate configuration conforms to the PCIe generation specification supported by the current CPU. Only data that simultaneously meets all three rules can be used as valid input for bandwidth allocation. The PCIe bandwidth resource optimization processing uses valid data that has passed the previous verification as the only input and strictly follows the allocation rules guided by service priority. Before bandwidth allocation, the total bandwidth requirement of the entire link is summarized, and the local pre-configured total boundary of available resources of the CPU PCIe root port and the component service priority rules are retrieved synchronously. The priority rules are sorted by default as "GPU accelerator card > FPGA accelerator card > NVMe storage backplane > PCIe IO expansion module", which can be modified online through BMC. Bandwidth allocation is strictly executed in descending order of priority, prioritizing the allocation of sufficient bandwidth to high-priority components, and then allocating the remaining available bandwidth to low-priority components, thereby generating a preliminary bandwidth allocation result. After the preliminary bandwidth allocation result is generated, a total resource boundary compliance verification is required. If the total allocated bandwidth exceeds the total boundary of available CPU PCIe resources (which is completely consistent with the rule for the total number of available channels on the root port for configuration boundary validity verification), then bandwidth pruning and reallocation will be performed according to the following rules to ensure that the final total allocated bandwidth strictly does not exceed the CPU hardware resource boundary: Basic guarantee lock: First, lock the minimum guaranteed bandwidth of all components, with the minimum guaranteed bandwidth of GPU / FPGA accelerator card being x8, the minimum guaranteed bandwidth of NVMe storage backplane being x4, and the minimum guaranteed bandwidth of PCIe IO expansion module being x1. The total minimum guaranteed bandwidth after locking must not exceed 80% of the total available CPU resources, with 20% reserved for redundant bandwidth. Definition of non-essential bandwidth: Non-essential bandwidth refers to the elastic bandwidth between the maximum bandwidth demanded by the component and the minimum guaranteed bandwidth. Only this portion of bandwidth can be pruned. Round-based pruning rules: Multiple rounds of pruning are executed in order of priority from low to high. The minimum pruning step size follows the minimum bandwidth allocation granularity defined by the PCIe specification, such as x4. The pruning range of a single round is 50% of the elastic bandwidth of a single component. After each round of pruning is completed, the total bandwidth is checked to see if it meets the boundary requirements. If it does, the pruning stops; otherwise, the next round begins. Priority allocation rule: For multiple components with the same priority, the remaining available bandwidth is allocated according to the proportion of bandwidth demand. The allocation formula is: bandwidth allocated to a single component = minimum guaranteed bandwidth + (remaining available bandwidth × bandwidth demanded by the component / total bandwidth demanded by components with the same priority). Extreme scenario handling mechanism: If the total bandwidth still exceeds the CPU available resource boundary after all components are reduced to the minimum guaranteed bandwidth, non-core components will be shut down in order of priority from low to high. The shutdown order is: IO expansion module → high-capacity NVMe storage backplane → low-latency NVMe storage backplane, until the total bandwidth meets the hardware boundary requirements. At the same time, the highest level alarm of BMC will be triggered and the shutdown log will be recorded. The final configuration table ensures that the bandwidth allocated to all components is no less than the minimum guaranteed bandwidth (except in extreme shutdown scenarios), and the total allocated bandwidth strictly does not exceed the total available resource boundary of the CPU PCIe root port, with no resource conflicts.

[0035] In this embodiment, cross-CPU platform configuration table adaptation is implemented using hardware identification and automatic conversion logic without software dependencies. The complete process and conversion rules are as follows: CPU platform hardware identification: CPU platform model identification is achieved through a 4-bit hardware strapping pin on the motherboard. The corresponding platform is defined by the combination of pull-up and pull-down resistor levels. For example, 0000=Intel, 0001=AMD, 0010=Hygon, and 0011=Phytium. This is a software-independent identification method that is common to server motherboards. After the CPLD is powered on, it directly reads the level value of the 4-bit pin to lock the current CPU platform model. Hardware lookup table pre-integration: The CPLD has a pre-integrated hardware platform adaptation lookup table (LUT). The lookup table is stored in synchronous ROM and is not lost when power is off. Each CPU platform has an independent lookup table entry. The entry adopts a fixed mapping storage structure. A single entry is bound to a general configuration parameter and the CPU platform register address + register configuration value to form a one-to-one binding mapping relationship.

[0036] General configuration parameter definition: The general configuration parameters in the initial configuration table are platform-independent standardized parameters, including: port number, port width (x1 / x4 / x8 / x16 / x32), PCIe speed generation (3.0 / 4.0 / 5.0), and link polarity configuration. Each parameter uses a fixed 4-bit encoding and has no platform differences. Automatic conversion execution process: The CPLD uses a pipelined hardware logic to perform parameter conversion, completing the single-port parameter conversion in a single clock cycle. The specific steps are as follows: Step 1: Based on the identified CPU platform model, retrieve the corresponding platform's compatibility lookup table; Step 2: Convert the general port width parameters in the initial configuration table into the write values ​​of the corresponding CPU platform's PCIe root port bandwidth configuration register, as shown in the example below: Intel Xeon Scalable Platform: x16 bandwidth corresponds to register value 0x3, x8 corresponds to 0x2, x4 corresponds to 0x1, and the register address is fixed as 0x200 + port number × 0x10; AMD EPYC platform: x16 bandwidth corresponds to register value 0xF, x8 corresponds to 0x7, x4 corresponds to 0x3, and the register address is fixed as 0x400 + port number × 0x20; The corresponding conversion rules for Hygon / Phytium platforms are pre-integrated in the lookup table; Step 3: Convert the general rate generation parameters into the write values ​​of the corresponding CPU platform PCIe link rate control register; Step 4: Arrange all the converted register addresses and configuration values ​​in order to generate a standardized PCIe configuration table that can be directly recognized by the corresponding CPU platform, and store it in a fixed address segment of the CPLD's internal RAM; The entire conversion process is completed by the CPLD hardware logic, without any secondary processing by the BIOS / CPU. The standard BIOS only needs to read the final configuration table and write it directly into the register to complete the configuration.

[0037] This embodiment employs a four-level end-to-end hardware verification mechanism to filter out invalid, tampered, and illegal configuration data at the source, providing a legitimate and valid data foundation for subsequent configuration table generation and ensuring the legality and security of the configuration table. Through hardware-based priority arbitration and resource boundary verification, it resolves configuration conflicts when the total bandwidth requirements of multiple components exceed available CPU resources, ensuring an extremely high configuration success rate in complex configuration scenarios. Furthermore, through pre-integrated cross-platform specification automatic conversion, a single hardware solution is compatible with all mainstream server CPU platforms, eliminating the need to repeatedly develop adaptation code for different CPU platforms and reducing cross-platform adaptation costs.

[0038] In one feasible implementation, the motherboard-side programmable logic device mentioned in step S3 sends a configuration ready signal to the BIOS before the server BIOS executes the PCIe controller initialization process, opening the standard read interface of the PCIe resource configuration table, including the following steps: Step S301: After the programmable logic device on the motherboard side completes the hardware-level write protection lock of the final PCIe resource configuration table, it monitors the power-on startup progress of the server BIOS in real time through the motherboard's dedicated GPIO pins to obtain the BIOS's POST stage node information. Step S302: Based on the obtained BIOS boot phase node information, the programmable logic device on the motherboard side sends a continuously valid high-level configuration ready signal to the BIOS through a dedicated hardware GPIO pin at a fixed timing node before the BIOS enters the PCIe controller initialization and bus enumeration process. Step S303: The programmable logic device on the motherboard side synchronously opens the fixed address standard read interface of the storage area corresponding to the PCIe resource configuration table, locks the interface access permission to read-only, and completes the hardware timing coordination preparation with the BIOS initialization process.

[0039] In this embodiment, the standard read interface is a standard serial bus interface conforming to SMBUS 2.0 or I2C specifications, which is a common standard interface for communication between the server motherboard CPLD and BIOS / BMC; the BIOS POST phase node monitoring is achieved through the CPLD connection to the BIOS's POST diagnostic code output port. The BIOS outputs a corresponding standard POST diagnostic code value at each stage of the POST process. The CPLD collects this value in real time. When it detects a UEFI standard POST diagnostic code value (e.g., 0x99) indicating the end of the PEI phase, it determines that it has entered a preset timing window. The configuration ready signal is active high for at least 500ms. It only outputs a high level after the configuration table has been written-protected and locked; otherwise, it continuously outputs a low level to prevent the BIOS from reading incomplete or invalid configurations. The fixed address standard read interface corresponds to a preset 64-byte continuous physical address segment in the CPLD's internal RAM. The SMBUS / I2C bus slave address is fixed to the general CPLD standard slave address (e.g., 0x50). The configuration table is stored in the 0x00-0x3F address segment. The BIOS can directly read the configuration table using the fixed slave address plus a fixed offset address, without dynamic addressing.

[0040] This embodiment ensures that the PCIe resource configuration table is generated, locked, and the interface is opened before the BIOS performs PCIe initialization by real-time monitoring during the BIOS POST phase and hard coordination of a fixed timing window. This completely solves the problem of timing mismatch and the need to modify the BIOS core boot process in traditional solutions. General standard UEFI BIOS can be directly adapted to this solution without any modification, achieving true no-code configuration adaptation.

[0041] In one feasible implementation, the server BIOS in step S4 obtains the PCIe resource configuration table through the standard read interface and completes the initial configuration of the PCIe resources based on the configuration table, including the following steps: Step S401: When the server BIOS enters the PCIe controller initialization process, after detecting a continuously valid configuration ready signal, it accesses the designated storage area of ​​the programmable logic device on the motherboard side through the corresponding open standard read interface and reads the PCIe resource configuration table after hardware write protection locking. Step S402: The server BIOS directly extracts the standardized register configuration parameters from the read PCIe resource configuration table, without needing to perform external hardware topology scanning, device enumeration and configuration mapping matching logic; Step S403: The server BIOS writes the extracted standardized register configuration parameters into the corresponding physical registers of the CPU PCIe controller in a preset order, completing the PCIe root port configuration, bus enumeration, and full-link resource initialization configuration.

[0042] In this embodiment, the BIOS read configuration table logic is implemented based on the UEFI standard SMBUS driver: In the PCIe Host Bridge initialization entry function during the DXE stage, only one line of standard SMBUS read instruction needs to be added to read the configuration table data at the fixed address of the CPLD. There is no need to modify the core enumeration and initialization logic of the BIOS. The general BIOS image only needs to be compiled once to adapt to all hardware configurations. The fixed order of register writing is: first write the bandwidth configuration register of the PCIe root port, then write the link rate configuration register, and finally trigger link retraining. After the root port configuration is completed, the standard PCIe bus enumeration process is executed, which fully complies with the initialization process of the PCIe Express specification.

[0043] This embodiment completes PCIe initialization by directly reading the standardized configuration table pre-generated by the hardware in the BIOS. This completely breaks through the inherent technical concept of "BIOS as the core execution body for PCIe configuration" in the traditional solution. It eliminates the need to build any hardware configuration mapping table, enumeration logic and adaptation code in the BIOS. It fundamentally eliminates the workload of BIOS customization development caused by diversified hardware configurations, greatly shortens the adaptation cycle of new hardware configurations, and reduces the maintenance cost of BIOS version iteration and troubleshooting.

[0044] In one feasible implementation, the method further includes a cable status intelligent alarm step that is executed in parallel with the PCIe configuration process during the server power-on phase, specifically including the following steps: Step S501: The server BMC obtains the verified component topology information from the independently partitioned storage area of ​​the programmable logic device on the motherboard side through the standard read interface shared with the BIOS. Step S502: The BMC will match and verify the obtained component topology information with the locally stored UBC physical port-component legal mapping rules one by one, and generate port matching verification results. Step S503: Based on the generated port matching verification results, BMC accurately identifies three types of abnormal states: missing or incorrect cable insertion, and component hardware failure. It triggers real-time alarms of the corresponding level and synchronously records the entire process abnormal log to the BMC management platform.

[0045] In this embodiment, the independently partitioned storage area is a 32-byte independent address segment (0x40-0x5F) in the CPLD's internal RAM, physically isolated from the PCIe configuration table. The BIOS accesses the 0x00-0x3F address segment, and the BMC accesses the 0x40-0x5F address segment. Different address segments under the same I2C / SMBUS interface allow for dual-path reading without interference and without bus conflicts. The specific judgment rules for the three types of faults are as follows: 1. Missing insertion fault: If the preset UBC port does not report the corresponding component topology information for a duration exceeding a preset time threshold, such as 1 second, it is judged as missing insertion. 2. Incorrect insertion fault: If the port number reported by the component does not match the preset legal port mapping relationship, it is judged as incorrect insertion. 3. Component fault: If the same component fails to verify data for 3 consecutive frames, it is judged as a component hardware fault. The alarm triggering is implemented through the IPMI 2.0 standard protocol. The BMC synchronizes the alarm information to the Web management platform and the remote management port, and triggers the corresponding port's light alarm through the motherboard alarm indicator light to accurately locate the fault location, which is a common standard implementation method for server operation and maintenance.

[0046] This embodiment achieves an integrated design for PCIe resource configuration and cable status monitoring by using a parallel reading mechanism that shares the same standard interface with the BIOS. This eliminates the need for additional communication links and hardware circuits. Furthermore, by matching and verifying topology information with preset mapping rules, it enables accurate location and real-time alarms for missing or incorrectly inserted cables and component failures. This eliminates the need for manual on-site troubleshooting, improves the efficiency of server hardware deployment and maintenance, and reduces maintenance costs.

[0047] In one feasible implementation, such as Figure 3 As shown, the method also includes a dynamic optimization step for the entire lifecycle of PCIe resources in OS runtime, specifically including the following steps: Step S601: During the normal operation of the server OS, the programmable logic device on the motherboard side collects the negotiation rate, bit error rate, and link status health data of each PCIe link in real time according to a preset cycle, and simultaneously receives the service bandwidth utilization rate and load level data of each component reported by the BMC, and summarizes them to obtain the full operation data of the links and load. Step S602: When the link health data and component load data meet the preset bandwidth adjustment trigger conditions, the programmable logic device on the motherboard side generates an incremental bandwidth adjustment configuration table by combining the link bit error rate, negotiation rate and component load level, and simultaneously completes resource conflict verification and CPU platform adaptation conversion to obtain a legal and valid incremental configuration table and executes write protection locking. Step S603: The programmable logic device on the motherboard side triggers the platform runtime processing flow of the server BIOS and OS kernel through the interrupt signal specified by the ACPI standard, based on the generated lock incremental configuration table. Step S604: The OS kernel, through the triggered platform runtime processing flow, follows the standard PCIe hot-plug specification to complete the bandwidth incremental adjustment, update the local configuration table and synchronize it to the programmable logic device on the motherboard side, and complete the dynamic optimization without restart or service interruption.

[0048] In this embodiment, the preset period can be adjusted according to the system load, and is exemplarily set to 10s, supporting online adjustment via BMC; for example, the preset bandwidth adjustment triggering conditions in this embodiment include: 1. Component bandwidth utilization rate exceeding 85% for 5 seconds; 2. Component bandwidth utilization rate below 20% for 30 seconds; 3. PCIe link bit error rate exceeding 10 for 1 second. -12 4. Hot-swapping of external components causes topology changes, and adjustments are triggered if any condition is met. The incremental bandwidth adjustment configuration table only modifies the bandwidth configuration parameters of the corresponding port that triggers the adjustment, while the configurations of other ports remain unchanged, thus avoiding service interruptions caused by full-link reconfiguration. The ACPI interrupt triggering is implemented through the SCI system control interrupt defined in ACPI 6.0 and above specifications. The complete platform runtime mechanism (PRM) processing flow and the non-interruptible adjustment process are as follows: Hardware interrupt and configuration table synchronization: After the motherboard CPLD completes the generation and write protection lock of the incremental configuration table, it sends a level-triggered interrupt signal to the ACPI subsystem through the motherboard SCI interrupt pin. At the same time, it writes the incremental configuration table to the physical memory address segment shared by the motherboard BIOS and OS (fixed to 0x7E000-0x7FFFF, low memory reserved area conforming to PC architecture standard). The configuration table adopts a fixed 16-byte structure, which includes four core fields: port number, target bandwidth, speed configuration, and checksum. The PRM handler implementation: The BIOS predefines a PRM handler at a fixed path in the ACPI namespace, namely \_SB.PCI0.PRMT. This handler conforms to the PRM module format defined in UEFI 2.8 and above specifications, has no OS dependency, and can be directly called by the Linux / Windows kernel. The core execution logic of the PRM handler is as follows: Upon receiving an SCI interrupt, the incremental configuration table of the shared memory address segment is read, and a CRC32 integrity check is performed. After successful verification, the configuration table is converted into a standard pci_bus_config data structure that can be recognized by the OS kernel PCIe bus driver; The data structure is passed to the OS kernel's ACPI driver through the ACPI operation area, thus completing the cross-layer transfer of configuration parameters. OS kernel non-disruptive adjustment process: After receiving the configuration parameters, the OS kernel follows the steps below to perform non-disruptive adjustment, adhering to the dynamic bandwidth adjustment function and hot-plug specifications defined in PCIe 4.0 and above: Step 1: By using PCIe multipath IO (MPIO) driver, the service traffic of the target port is seamlessly switched to the redundant link of the same component, with zero packet loss of service traffic; Step 2: Modify the bandwidth configuration register of the target root port through the PCIe bus driver to trigger link retraining and complete the bandwidth incremental adjustment; Step 3: After the link retraining is completed and the negotiation is stable, switch the business traffic back to the original port to complete the whole process adjustment; After the adjustment is completed, the OS kernel writes the execution result to the CPLD status register and updates the configuration table in shared memory synchronously. The entire process does not require a system restart or business interruption, and fully complies with the PCIe device management specifications and ACPI specifications of Linux / Windows server operating systems.

[0049] This embodiment achieves dynamic adaptive adjustment of PCIe resources throughout their entire lifecycle, from power-on initialization to OS runtime, by real-time acquisition of runtime link and load data, hardware generation of incremental configuration tables, and in conjunction with the ACPI standard runtime mechanism. It can complete bandwidth allocation on demand without restarting the system or interrupting business operations. Compared with the traditional one-time static configuration scheme, it improves the utilization rate of PCIe link resources, reduces the power consumption of PCIe links in the whole machine, and can avoid the risk of link interruption in advance based on the link health status, thereby improving the stability of server operation.

[0050] In one feasible implementation, the method further includes a full-process configuration exception rollback step, specifically including the following steps: Step S701: The programmable logic device on the motherboard side monitors the PCIe configuration execution status of the BIOS and OS kernel in real time through a dedicated feedback link and obtains the configuration execution result feedback; Step S702: When the programmable logic device on the motherboard side detects a failure state such as configuration execution failure or link negotiation abnormality based on the obtained configuration execution result feedback, it immediately releases the write protection of the current fault configuration table, retrieves the last effective PCIe resource configuration table in the local non-volatile memory, and re-executes the hardware-level write protection lock. Step S703: The programmable logic device on the motherboard side sends a hardware-level configuration ready signal to the BIOS / OS again according to the re-locked valid configuration table, opens the read-only standard read interface of the valid configuration table, and triggers a fault alarm and records the entire process fault log.

[0051] In this embodiment, the dedicated feedback link is a 16-bit status register (bus address 0x60) inside the CPLD. After the BIOS / OS completes the configuration, it writes the execution result to this register: 0x00 = configuration successful, 0x01 = configuration failed, 0x02 = link negotiation error. The CPLD reads the register value in real time to obtain the execution result. The criteria for determining the effectiveness of the configuration table are: after the BIOS / OS completes the configuration writing, the PCIe link negotiation is successful, there are no abnormal alarms, and it runs stably for more than 500ms. The BIOS then synchronously writes the effectiveness flag to the CPLD dedicated register. The triggering rule for the fault rollback is: only when... A rollback is triggered only when the status register value remains non-0x00 for more than 500ms to avoid erroneous rollbacks caused by a single momentary error. The write-protected state machine only allows internal logic to temporarily jump to the UNLOCK state when a fault state is detected, and immediately jumps back to the LOCK state after the valid configuration table replacement is completed. The contents of the storage area cannot be modified by external bus read and write operations throughout the process. The storage rules for the valid configuration table are as follows: after each successful configuration, the CPLD writes the configuration table to the circular storage area of ​​the built-in Flash, storing a maximum of the three most recently successful configuration tables. The most recently valid configuration table is retrieved during each rollback, and the data is not lost when power is lost.

[0052] This embodiment avoids system startup failures and service interruptions caused by configuration errors or link anomalies by real-time monitoring of configuration execution status and a hardware-level automatic fault rollback mechanism. When configuration execution fails, it can automatically roll back to the last stable and effective configuration, restoring normal system operation without manual intervention, thereby improving the fault tolerance of server PCIe configuration and the stability of system operation.

[0053] The above description is merely a preferred embodiment of the present invention. It should be understood that the present invention is not limited to the forms disclosed herein and should not be construed as excluding other embodiments. It can be used in various other combinations, modifications, and environments, and can be altered within the scope of the concept described herein through the above teachings or related technologies or knowledge. Modifications and variations made by those skilled in the art that do not depart from the spirit and scope of the present invention should be within the protection scope of the appended claims.

Claims

1. A server PCIe resource adaptive configuration method, characterized in that, Includes the following steps: S1: The programmable logic device on the motherboard side and the programmable logic device on the external component side complete the interactive negotiation through the native sideband communication channel of the UBC cable, and receive standardized data reported by the component side, which includes component topology information and PCIe link configuration requirements. S2: The programmable logic device on the motherboard side verifies and optimizes the standardized data to generate a standardized PCIe resource configuration table adapted to the current server CPU platform, and performs hardware-level write protection locking on the configuration table; the write protection lock can be unlocked by triggering the fault rollback logic and runtime tuning logic inside the programmable logic device on the motherboard side. After unlocking, only internal logic is allowed to modify the configuration table, and the external access interface always maintains read-only permission. S3: Before the server BIOS executes the PCIe controller initialization process, the programmable logic device on the motherboard side sends a configuration ready signal to the BIOS, opening the standard read interface of the PCIe resource configuration table; S4: The server BIOS obtains the PCIe resource configuration table through the standard read interface and completes the initial configuration of the PCIe resources based on the configuration table.

2. The server PCIe resource adaptive configuration method of claim 1, wherein, In step S1, the motherboard-side programmable logic device and the external component-side programmable logic device complete interactive negotiation through the native sideband communication channel of the UBC cable, and receive standardized data reported by the component side, including component topology information and PCIe link configuration requirements, including the following steps: S101: After the server is powered on, the programmable logic device on the motherboard side completes initialization and completes handshake interaction with all external component-side programmable logic devices through the native sideband communication channel of the UBC cable to negotiate and generate a unique session key for this power-on. S102: The motherboard-side programmable logic device allocates an independent reporting time slot and communication baud rate to each external component-side programmable logic device based on the number of connected UBC cables and the fixed timing window of the server BIOS PCIe initialization, and generates a time-sharing scheduling instruction to send to the corresponding component-side programmable logic device. S103: The programmable logic device on the component side collects the component topology information fixed in local non-volatile memory and the PCIe link configuration requirements collected in real time by the hardware registers according to the session key generated by negotiation and the time-sharing scheduling instructions issued. It encapsulates the information into a standardized data frame of fixed length and enters the reporting state of time slot synchronization. S104: The programmable logic device on the motherboard side sends a reporting trigger signal to the corresponding programmable logic device on the component side in the order of the pre-allocated time slots, and synchronously receives the standardized data frames reported by the component side through the native sideband communication channel of the UBC cable, thus completing the standardized data reception of all components during this power-on.

3. The server PCIe resource adaptive configuration method of claim 2, wherein, In step S104, when the programmable logic device on the motherboard side receives data, it controls the reporting timing of multiple cables through a hardware backpressure mechanism. Before the current cable data is received and the preliminary frame structure is verified, the reporting trigger signal of other cables is blocked.

4. The server PCIe resource adaptive configuration method of claim 1, wherein, The programmable logic device on the motherboard side performing verification processing on the standardized data in step S2 includes the following steps: S201: The programmable logic device on the motherboard side performs frame structure legality verification on the received full set of standardized data frames, and filters out format compliant data frames whose frame header, frame tail, and frame length completely match the preset rules. S202: The programmable logic device on the motherboard side performs data integrity verification on the selected format compliant data frames to confirm that there is no tampering or error during the data transmission process, and obtains a complete and valid data frame; S203: The programmable logic device on the motherboard performs a uniqueness check on the complete and valid data frame that has passed the verification, filters duplicate frames and replays frames to obtain a unique and valid data frame without duplicates. S204: The programmable logic device on the motherboard performs configuration boundary validity verification on the unique valid data frame after deduplication, confirms that the configuration parameters in the frame comply with the hardware security rules of the CPU PCIe controller, and obtains standardized valid data that has passed the full process verification.

5. The server PCIe resource adaptive configuration method according to claim 4, characterized in that, The motherboard-side programmable logic device performing resource optimization processing on the standardized data in step S2 includes the following steps: S205: The programmable logic device on the motherboard side summarizes the total PCIe link bandwidth requirements corresponding to all verified standardized data, and synchronously retrieves the total boundary of available resources of the CPU PCIe root port and the component service priority rules that are pre-configured locally. S206: The programmable logic device on the motherboard side allocates PCIe bandwidth resources to each component in descending order of priority according to the retrieved component priority rules, and generates a preliminary bandwidth allocation result. S207: The programmable logic device on the motherboard side performs a total resource boundary check on the generated preliminary bandwidth allocation result. If the total allocated bandwidth exceeds the total boundary of available CPU PCIe resources, unnecessary bandwidth is cut off from low to high priority until the total allocated bandwidth meets the resource boundary requirements. Finally, an initial PCIe resource configuration table without resource conflicts and in accordance with hardware rules is generated.

6. The server PCIe resource adaptive configuration method according to claim 5, characterized in that, Step S2, which involves generating a standardized PCIe resource configuration table adapted to the current server CPU platform, includes the following steps: S208: The programmable logic device on the motherboard side identifies the CPU platform model of the current server through hardware pins; S209: The motherboard-side programmable logic device retrieves the pre-integrated PCIe controller specifications and register mapping rules for the corresponding CPU platform; S210: The motherboard-side programmable logic device converts the original parameters in the initial PCIe resource configuration table into standardized register configuration parameters that can be directly recognized by the corresponding CPU platform, and generates the final PCIe resource configuration table.

7. The server PCIe resource adaptive configuration method according to claim 1, characterized in that, The motherboard-side programmable logic device mentioned in step S3 sends a configuration ready signal to the BIOS before the server BIOS executes the PCIe controller initialization process, opening the standard read interface of the PCIe resource configuration table. This includes the following steps: S301: After the programmable logic device on the motherboard side completes the hardware-level write protection lock of the final PCIe resource configuration table, it monitors the power-on startup progress of the server BIOS in real time through the motherboard's dedicated GPIO pins to obtain the BIOS's POST stage node information. S302: Based on the obtained BIOS boot phase node information, the motherboard-side programmable logic device sends a continuously valid high-level configuration ready signal to the BIOS through a dedicated hardware GPIO pin at a fixed timing node before the BIOS enters the PCIe controller initialization and bus enumeration process. S303: The motherboard-side programmable logic device synchronously opens the fixed address standard read interface of the corresponding storage area of ​​the PCIe resource configuration table, locks the interface access permission to read-only, and completes the hardware timing coordination preparation with the BIOS initialization process.

8. The server PCIe resource adaptive configuration method according to claim 1, characterized in that, Step S4, where the server BIOS obtains the PCIe resource configuration table through the standard read interface and completes the initial configuration of the PCIe resources based on the configuration table, includes the following steps: S401: When the server BIOS enters the PCIe controller initialization process, after detecting a continuously valid configuration ready signal, it accesses the designated storage area of ​​the programmable logic device on the motherboard side through the corresponding open standard read interface and reads the PCIe resource configuration table after hardware write protection locking. S402: The server BIOS directly extracts standardized register configuration parameters from the PCIe resource configuration table it reads, without having to perform external hardware topology scanning, device enumeration and configuration mapping matching logic; S403: The server BIOS extracts the standardized register configuration parameters and writes them into the corresponding physical registers of the CPU PCIe controller in a preset order, completing the PCIe root port configuration, bus enumeration, and full-link resource initialization configuration.

9. The server PCIe resource adaptive configuration method according to claim 1, characterized in that, The method also includes a cable status intelligent alarm step that is executed in parallel with the PCIe configuration process during the server power-on phase, specifically including the following steps: S501: The server BMC obtains verified component topology information from the independently partitioned storage area of ​​the programmable logic device on the motherboard side through a standard read interface shared with the BIOS. S502: The BMC will match and verify the obtained component topology information with the locally stored UBC physical port-component legal mapping rules one by one, and generate port matching verification results. S503: Based on the generated port matching verification results, BMC accurately identifies three types of abnormal states: missing or incorrect cable insertion, and component hardware failure. It triggers real-time alarms of the corresponding level and synchronously records the entire process abnormal log to the BMC management platform.

10. The server PCIe resource adaptive configuration method according to claim 1, characterized in that, The method also includes a dynamic optimization step for the entire lifecycle of OS-running PCIe resources, specifically including the following steps: S601: During the normal operation of the server OS, the programmable logic device on the motherboard side collects the negotiation rate, bit error rate, and link status health data of each PCIe link in real time according to a preset cycle, and simultaneously receives the service bandwidth utilization rate and load level data of each component reported by the BMC, and summarizes them to obtain the full operation data of the links and load. S602: When the link health data and component load data meet the preset bandwidth adjustment trigger conditions, the motherboard-side programmable logic device generates an incremental bandwidth adjustment configuration table by combining the link bit error rate, negotiation rate and component load level, and simultaneously completes resource conflict verification and CPU platform adaptation conversion to obtain a legal and valid incremental configuration table and execute write protection locking. S603: The motherboard-side programmable logic device triggers the platform runtime processing flow of the server BIOS and OS kernel through the interrupt signal specified by the ACPI standard, based on the generated lock incremental configuration table. S604: The OS kernel, through the platform runtime processing flow triggered by the system, follows the standard PCIe hot-plug specification to complete the bandwidth increment adjustment, update the local configuration table and synchronize it to the programmable logic device on the motherboard side, thus completing dynamic optimization without restarting or service interruption.