Methods and apparatus for dynamically allocating resources during real-time system operation; real-time system

By introducing shared memory and management partitions into the real-time system and dynamically adjusting partition resource configurations, the problem of cumbersome and time-consuming resource allocation in existing technologies is solved, and flexible resource management at runtime is achieved.

CN118779097BActive Publication Date: 2026-11-10INTEWELL (GUANGZHOU) SOFEWARE TECH CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202410793581.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-19
Publication Date
2026-11-10
Estimated Expiration
2044-06-19

AI Technical Summary

Technical Problem

In existing real-time operating systems, partition resource allocation requires recompiling and burning the entire system, which is cumbersome and time-consuming, and cannot achieve dynamic adjustment.

Method used

By introducing shared memory and management partitions into the real-time system, the resource configuration of partitions can be dynamically adjusted. Shared memory is used to store and manage the resource configuration information of each partition, allowing partition resources to be adjusted at runtime without restarting the entire system.

Benefits of technology

It enables dynamic adjustment of partition resource configuration without restarting the device, simplifying the process, saving time, and improving the flexibility and efficiency of resource allocation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118779097B_ABST
    Figure CN118779097B_ABST
Patent Text Reader

Abstract

This application relates to a method, apparatus, and real-time system for dynamically allocating resources during real-time system operation. The method includes: obtaining a resource change request for at least one of the second partitions, the resource change request including a resource configuration to be changed; reading the current resource configuration of each second partition stored in shared memory; determining whether the resource change is reasonable based on the resource configuration to be changed and the current resource configuration of each second partition; when the resource change is reasonable, updating the current resource configuration of the corresponding at least one second partition in shared memory according to the resource configuration to be changed, and causing the at least one second partition to perform the resource configuration change according to the updated current resource configuration. This application allows the operating system to dynamically adjust the resource configuration of partitions during runtime without restarting the entire system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of operating system resource allocation technology, and in particular to a method and apparatus for dynamically allocating resources during the operation of a real-time system, a real-time system, a computing device, and a storage medium. Background Technology

[0002] Existing time-sharing and partitioned real-time operating systems, such as VxWorks and Intewell OS, consist of multiple partitions (VMs), each with its own resources (CPU cores, memory, bus, peripherals, etc.). Before the operating system boots, resource allocation needs to be performed on each partition. The allocation process is as follows: Figure 1 As shown, it includes:

[0003] 1. Partitioning: First, the system needs to be divided into multiple independent partitions.

[0004] 2. Resource Allocation: Next, allocate the corresponding resources to each partition according to its needs.

[0005] 3. Generate configuration files: Generate static configuration files for each partition, which describe in detail the resource allocation of the partition.

[0006] 4. Compile configuration files: Compile static configuration files so that they can be recognized and executed by the device.

[0007] 5. Download configuration file: Download the compiled configuration file to the device.

[0008] 6. System Initialization: When the device starts up, the system initializes the resources of each partition, including reading, parsing and initializing the resource information in the static configuration file.

[0009] Currently, resource allocation is performed before compilation using static configuration files. This means that once the system starts running, the resources of each partition are isolated and exclusive, and cannot be dynamically adjusted. A diagram illustrating resource-isolated partitions can be found here. Figure 2 .

[0010] If any partition's resource allocation needs to be changed, the entire system's files (including executables and configuration files) must be recompiled. Then, a new flashing file needs to be created, downloaded, and flashed onto the device. Finally, the device needs to be restarted to reinitialize the resources of each partition in the system. This process is tedious and time-consuming because it requires restarting the entire device and recompiling and flashing the entire system. Summary of the Invention

[0011] In view of the above-mentioned problems of the prior art, this application provides a method and apparatus for dynamically allocating resources in the operation of a real-time system, a real-time system, a computing device and a storage medium, to solve the problem that when the resource allocation of any partition is changed, the entire device needs to be restarted and the entire system needs to be recompiled and burned.

[0012] To achieve the above objectives, the first aspect of this application provides a method for dynamically allocating resources during the operation of a real-time system, comprising:

[0013] Obtain resource change requests for at least one of the second partitions, wherein the resource change requests include the resource configuration to be changed;

[0014] Read the current resource configuration of each second partition stored in shared memory;

[0015] Based on the resource configuration to be changed and the current resource configuration of each second partition, determine whether the resource change is reasonable;

[0016] When the resource change is reasonable, the current resource configuration of the corresponding at least one second partition in the shared memory is updated according to the resource configuration to be changed, and the at least one second partition performs the resource configuration change according to the updated current resource configuration.

[0017] Therefore, this application does not require recompiling and burning the entire system. It only needs to obtain the resource change request of the partition to be changed, and jointly determine whether the resource change is reasonable with the current resource configuration of each second partition stored in the shared memory. If it is reasonable, the current resource configuration in the shared memory and the partition to be changed is updated. There is no need to restart the entire device. Only the partition to be changed needs to be restarted, and the partition to be changed can perform the resource configuration change according to the updated current resource configuration. The process is simple and saves time.

[0018] As one possible implementation of the first aspect, it also includes:

[0019] If the resource change is unreasonable, refuse the change.

[0020] As one possible implementation of the first aspect, determining whether the resource change is reasonable based on the resource configuration to be changed and the current resource configuration of each second partition includes:

[0021] The deletion and / or addition of resources in the resource change are determined based on the resource configuration to be changed and the current resource configuration of each second partition;

[0022] When it is determined that only the deletion of resources is included, it is judged whether the deletion of resources is reasonable. If it is not reasonable, the change is rejected; if it is reasonable, the change is allowed.

[0023] When it is determined that only adding resources is included, it is judged whether the addition of resources is reasonable. If it is not reasonable, the change is rejected; if it is reasonable, the change is allowed.

[0024] When it is determined that the deletion and addition of resources are involved, the appropriateness of the deleted resource is assessed. If the deletion is inappropriate, the change is rejected. If the deletion is appropriate, the appropriateness of the added resource is assessed. If the addition is inappropriate, the change is rejected. If the addition is appropriate, the change is permitted.

[0025] As one possible implementation of the first aspect, the resource configuration to be changed includes one or more of the following resources: CPU cores occupied by the partition, memory occupied by the partition, peripherals occupied by the partition, and interrupt numbers occupied by the partition;

[0026] The determination of whether a resource change is reasonable includes at least one of the following:

[0027] Determine whether the CPU cores occupied by the partition have been deleted. If the CPU cores occupied by the partition have been deleted, it is unreasonable; if the CPU cores occupied by the partition have not been deleted, it is reasonable.

[0028] Determine whether the memory occupied by the partition has been deleted. If the memory occupied by the partition has been deleted, it is unreasonable; if the memory occupied by the partition has not been deleted, it is reasonable.

[0029] Determine whether the memory occupied by the added partition conflicts. If the memory address occupied by the added partition does not overlap with the memory address occupied by other second partitions, and the sum of the memory occupied by the added partition and the memory occupied by other second partitions is less than the memory size of the real-time system, then there is no conflict. If the memory address occupied by the added partition overlaps with the memory address occupied by other second partitions, and / or the sum of the memory occupied by the added partition and the memory occupied by other second partitions is greater than the memory size of the real-time system, then there is a conflict.

[0030] Determine whether the peripherals occupied by the added partition are reasonable. If the peripherals occupied by the added partition exist in the real-time system, then it is reasonable. If the peripherals occupied by the added partition do not exist in the real-time system, then it is unreasonable.

[0031] Determine whether the I / O multiplexing of the peripheral occupied by the added partition conflicts. If the peripheral occupied by the added partition is a peripheral occupied by another second partition, then there is a conflict. If the peripheral occupied by the added partition is not a peripheral occupied by another second partition, then there is no conflict.

[0032] Determine whether the base address of the peripheral occupied by the added partition is within the available address range of the real-time system. If it is, it is reasonable; if not, it is unreasonable.

[0033] Determine whether the interrupt number occupied by the added partition conflicts with the interrupt number in another second partition. If the interrupt number occupied by the added partition is the same as the interrupt number in another second partition, then there is a conflict. If the interrupt number occupied by the added partition is not the same as the interrupt number in another second partition, then there is no conflict.

[0034] As one possible implementation of the first aspect, the step of causing the at least one second partition to perform resource configuration changes based on the updated current resource configuration includes:

[0035] When resource deletion is included, the at least one second partition shall perform resource deletion based on the deleted resource;

[0036] Write the current runtime context data to shared memory and stop running;

[0037] Initialize by reading the updated current resource configuration from the shared memory;

[0038] After reading the current running context data from the shared memory, operation resumes and the resource configuration changes are completed.

[0039] As one possible implementation of the first aspect, the step of causing the at least one second partition to perform resource configuration changes based on the updated current resource configuration includes:

[0040] When additional resources are added, the at least one second partition writes the current runtime context data to shared memory and stops running.

[0041] Initialize by reading the updated current resource configuration from the shared memory;

[0042] After reading the current running context data from the shared memory, operation resumes and the resource configuration changes are completed.

[0043] As one possible implementation of the first aspect, the current resource configuration of each second partition stored in the shared memory is written by each second partition.

[0044] As one possible implementation of the first aspect, the method for dynamically allocating resources during real-time system operation runs on a first partition, which is used to manage the shared memory and the various second partitions.

[0045] To achieve the above objectives, a second aspect of this application provides a device for dynamically allocating resources during real-time system operation, comprising:

[0046] The resource change request acquisition module is used to acquire resource change requests for at least one of the second partitions, wherein the resource change request includes the resource configuration to be changed.

[0047] The current resource configuration reading module is used to read the current resource configuration of each second partition stored in shared memory;

[0048] The change rationality judgment module is used to determine whether the resource change is reasonable based on the resource configuration to be changed and the current resource configuration of each second partition;

[0049] The change module is used to update the current resource configuration of the corresponding at least one second partition in the shared memory according to the resource configuration to be changed when the resource change is reasonable, and to make the at least one second partition perform the resource configuration change according to the updated current resource configuration.

[0050] To achieve the above objectives, a third aspect of this application provides a real-time system, comprising: a first partition, at least one second partition, and shared memory;

[0051] Each of the second partitions is configured with the resources it uses, and the corresponding resource configuration is written to the shared storage.

[0052] The first partition is running any of the methods described in the first aspect above.

[0053] A fourth aspect of this application provides a computing device, comprising:

[0054] processor, and

[0055] A memory having stored program instructions that, when executed by the processor, cause the processor to perform any of the methods described in the first aspect above.

[0056] The fifth aspect of this application provides a computer-readable storage medium having program instructions stored thereon, which, when executed by a computer, cause the computer to perform any of the methods described in the first aspect above. Attached Figure Description

[0057] Figure 1 This is a flowchart of the existing real-time system resource allocation method;

[0058] Figure 2 This is a schematic diagram of resource isolation in the existing partitions;

[0059] Figure 3 This is a structural schematic diagram of a real-time system provided in an embodiment of this application;

[0060] Figure 4 This is a flowchart of an embodiment of a method for dynamically allocating resources in a real-time system, provided in this application.

[0061] Figure 5A flowchart illustrating a specific implementation of a method for dynamically allocating resources during real-time system operation, provided in this application embodiment;

[0062] Figure 6 This is a structural schematic diagram of a device for dynamically allocating resources in a real-time system, provided in an embodiment of this application.

[0063] Figure 7 This is a schematic structural diagram of a computing device provided in an embodiment of this application.

[0064] It should be understood that the dimensions and shapes of the blocks in the above structural diagrams are for reference only and should not constitute an exclusive interpretation of the embodiments of the present invention. The relative positions and inclusion relationships between the blocks presented in the structural diagrams are only schematic representations of the structural relationships between the blocks, and are not intended to limit the physical connection methods of the embodiments of the present invention. Detailed Implementation

[0065] The technical solutions provided in this application will be further described below with reference to the accompanying drawings and embodiments. It should be understood that the system architecture and business scenarios provided in the embodiments of this application are mainly for illustrating possible implementations of the technical solutions of this application and should not be construed as the sole limitation on the technical solutions of this application. Those skilled in the art will recognize that the technical solutions provided in this application are equally applicable to similar technical problems as system architectures evolve and new business scenarios emerge.

[0066] It should be understood that the dynamic resource allocation scheme for real-time system operation provided in the embodiments of this application includes a method, apparatus, and real-time system for dynamic resource allocation during real-time system operation. Since these technical solutions solve problems based on the same or similar principles, some repetitive details may not be repeated in the following descriptions of specific embodiments. However, it should be considered that these specific embodiments have mutual references and can be combined with each other.

[0067] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. In case of any inconsistency, the meaning set forth in this specification or derived from the content described herein shall prevail. Furthermore, the terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application. To accurately describe the technical content of this application and to accurately understand the invention, the following explanations or definitions of the terms used in this specification are provided before describing specific embodiments.

[0068] [Examples of the Real-Time System in this Application]

[0069] The existing system requires a complete device reboot and system recompilation and flashing if any partition's resource allocation needs to be changed. To address this issue, this application proposes a real-time system that uses a combination of shared memory, configuration, and partition management to dynamically adjust partition resource allocation during real-time system operation. Figure 3 As shown, the real-time system includes: a first partition, at least one second partition, and shared memory;

[0070] Each of the second partitions is configured with the resources it uses, and the corresponding resource configuration is written to the shared storage.

[0071] The first partition runs a method for dynamically allocating resources during real-time system operation.

[0072] In practice, the first partition is a fixed management partition: Management VM, or MVM for short. Apart from this management partition (MVM), all other partitions in the second partition are ordinary partitions (VMs). Users can add, delete, and configure these ordinary partitions as they wish. The management partition (MVM) is essential and must run when the system starts. This partition is not a business partition and does not implement business logic. The management partition has the following permissions: start, stop, suspend, and resume all other second partitions. During system operation, the MVM can initiate resource change requests for each second partition VM. The MVM maintains the current resource configuration tables for each second partition VM in the SHM (System Management Module), and maintains and judges changes accordingly.

[0073] On the hardware device, a shared memory (SHM) is allocated as a global shared memory, which can be accessed and modified simultaneously by all partitions (the first partition and the second partition). MVM continuously monitors the contents of the SHM after startup.

[0074] When the system is running and the second partition VMs are initialized, each second partition VM proactively writes its current resource configuration (including 1. the CPU core number the VM is running on; 2. the VM's memory start address, end address, and size; 3. the peripherals allocated to the VM, as well as the base address and size of the peripherals; 4. the interrupt number allocated to the VM) into the shared memory SHM. Once the system's second partition VM initialization is complete, the SHM completes the collection and filling of resource information for each second partition VM and writes an end marker. At this point, the MVM determines that the second partition VM information collection is complete by monitoring the end marker, reads and parses the resource configuration information of each second partition from the SHM, and forms a total resource configuration table, which is then stored in the SHM for unified management.

[0075] The following describes in detail how the first partition achieves dynamic resource allocation during real-time system operation.

[0076] [An Example of a Method for Dynamically Allocating Resources in a Real-Time System]

[0077] This application provides a method for dynamically allocating resources during the operation of a real-time system, such as... Figure 4 As shown, the method includes:

[0078] S410: Obtain a resource change request for at least one of the second partitions, wherein the resource change request includes the resource configuration to be changed;

[0079] S420: Reads the current resource configuration of each second partition stored in shared memory;

[0080] S430: Based on the resource configuration to be changed and the current resource configuration of each second partition, determine whether the resource change is reasonable;

[0081] S440: When the resource change is reasonable, update the current resource configuration of the corresponding at least one second partition in the shared memory according to the resource configuration to be changed, and cause the at least one second partition to perform the resource configuration change according to the updated current resource configuration.

[0082] In some embodiments, it also includes:

[0083] If the resource change is unreasonable, refuse the change.

[0084] In some embodiments, the above-described method for dynamically allocating resources during real-time system operation runs on a first partition, which is used to manage the shared memory and the respective second partitions.

[0085] In some embodiments, the current resource configuration of each second partition stored in the shared memory is written by each second partition.

[0086] In practice, during the initialization of the second partition VM, each second partition VM actively writes its current resource configuration (including 1. the CPU core number running the VM; 2. the VM's memory start address, end address, and size; 3. the peripherals allocated to the VM, as well as the base address and size of the peripherals; 4. the interrupt number allocated to the VM) into the shared memory SHM. The current resource configuration is stored within itself and written into the shared memory SHM in the form of a configuration table.

[0087] In specific implementation, in step S401, if the user wants to change the resources in the second partition, a resource change request needs to be generated. This resource change request includes the resource configuration to be changed, such as... Figure 5As shown, the left side displays the resource configuration before the change, and the right side displays the resource configuration after the change. The first partition then retrieves this resource change request for further processing.

[0088] In some embodiments, determining whether a resource change is reasonable based on the resource configuration to be changed and the current resource configuration of each second partition includes:

[0089] The deletion and / or addition of resources in the resource change are determined based on the resource configuration to be changed and the current resource configuration of each second partition;

[0090] When it is determined that only the deletion of resources is included, it is judged whether the deletion of resources is reasonable. If it is not reasonable, the change is rejected; if it is reasonable, the change is allowed.

[0091] When it is determined that only adding resources is included, it is judged whether the addition of resources is reasonable. If it is not reasonable, the change is rejected; if it is reasonable, the change is allowed.

[0092] When it is determined that the deletion and addition of resources are involved, it is judged whether the deletion of resources is reasonable. If the deletion of resources is unreasonable, the change is rejected. If the deletion of resources is reasonable, it is judged whether the addition of resources is reasonable. If the addition of resources is unreasonable, the change is rejected. If the addition of resources is reasonable, the change is allowed.

[0093] In practice, when only resource deletion is included, it's only necessary to determine if the deletion is justified. If so, the change is allowed; otherwise, it's rejected. Similarly, when only resource addition is included, it's only necessary to determine if the addition is justified. If so, the change is allowed; otherwise, it's rejected. However, when both resource deletion and addition are included, the process is as follows: first, the deletion is judged as justified. Only if the deletion is justified will the addition be judged as justified. If the deletion is not justified, the change is rejected, and the addition is not judged further. Changes are only allowed when both resource deletion and addition are deemed justified.

[0094] In some embodiments, the resource configuration to be changed includes one or more of the following resources: CPU cores occupied by the partition, memory occupied by the partition, peripherals occupied by the partition, and interrupt numbers occupied by the partition;

[0095] The determination of whether a resource change is reasonable includes at least one of the following:

[0096] Determine whether the CPU cores occupied by the partition have been deleted. If the CPU cores occupied by the partition have been deleted, it is unreasonable; if the CPU cores occupied by the partition have not been deleted, it is reasonable.

[0097] Determine whether the memory occupied by the partition has been deleted. If the memory occupied by the partition has been deleted, it is unreasonable; if the memory occupied by the partition has not been deleted, it is reasonable.

[0098] Determine whether the memory occupied by the added partition conflicts. If the memory address occupied by the added partition does not overlap with the memory address occupied by other second partitions, and the sum of the memory occupied by the added partition and the memory occupied by other second partitions is less than the memory size of the real-time system, then there is no conflict. If the memory address occupied by the added partition overlaps with the memory address occupied by other second partitions, and / or the sum of the memory occupied by the added partition and the memory occupied by other second partitions is greater than the memory size of the real-time system, then there is a conflict.

[0099] Determine whether the peripherals occupied by the added partition are reasonable. If the peripherals occupied by the added partition exist in the real-time system, then it is reasonable. If the peripherals occupied by the added partition do not exist in the real-time system, then it is unreasonable.

[0100] Determine whether the I / O multiplexing of the peripheral occupied by the added partition conflicts. If the peripheral occupied by the added partition is a peripheral occupied by another second partition, then there is a conflict. If the peripheral occupied by the added partition is not a peripheral occupied by another second partition, then there is no conflict.

[0101] Determine whether the base address of the peripheral occupied by the added partition is within the available address range of the real-time system. If it is, it is reasonable; if not, it is unreasonable.

[0102] Determine whether the interrupt number occupied by the added partition conflicts with the interrupt number in another second partition. If the interrupt number occupied by the added partition is the same as the interrupt number in another second partition, then there is a conflict. If the interrupt number occupied by the added partition is not the same as the interrupt number in another second partition, then there is no conflict.

[0103] In practice, resource changes for each second partition can be resource deletion or resource addition (including adding new resources or changing the size of existing resources). When executing step S430, the deletion and / or addition of resources in the resource change can be determined based on the resource configuration to be changed and the current resource configuration of each second partition. Then, it is determined whether the deletion and / or addition of resources is reasonable. The specific determination is as follows:

[0104] (1) CPU cores occupied by the partition: These cannot be deleted. Therefore, when making resource changes, it is necessary to first determine whether the CPU cores occupied by the partition have been deleted. If they have been deleted, it means that the deletion is unreasonable and the resource change is rejected. Changes and replacements are allowed, but they must be CPU cores allowed by the real-time system.

[0105] (2) Memory occupied by the partition: It is not allowed to be deleted, so first determine whether the memory occupied by the partition has been deleted. If it has been deleted, it means that the deletion is unreasonable and the resource change is rejected.

[0106] It allows modification and replacement, and allows changes to the size, start address, and end address of the memory. Therefore, after determining if something has been deleted, it checks if it has been modified. If modified, it checks for memory conflicts, including:

[0107] (21) Some peripherals require memory. MVM determines whether the size of the modified memory is within the allowed range. That is, it adds the size of the modified memory to the size of the memory of the other second partition and compares it with the size of the memory of the whole system. If it is less than the size of the memory of the whole system, it means that the size of the modified memory is within the allowed range and there is no conflict. If it is greater than the size of the memory of the whole system, it means that the size of the modified memory is not within the allowed range and there is a conflict.

[0108] (22) Determine whether the memory occupied overlaps with the memory address occupied by other existing second partitions. That is, determine whether the start address and end address of the modified memory overlap with the start address and end address of the memory occupied by other existing second partitions. If they do not overlap, it means there is no conflict. If they overlap, it means there is a conflict.

[0109] If there are no conflicts, then MVM can update the configuration table in SHM.

[0110] CPU cores and memory are evaluated first, followed by the removal / addition of peripherals.

[0111] (3) The peripherals occupied by the partition, including the base address and size of the peripherals. Peripherals can be deleted and added. Deleting a peripheral does not require a validity check; the deletion can be executed directly. However, adding a peripheral requires a validity check.

[0112] (31) Determine if the newly allocated peripheral resources are reasonable? The newly allocated peripheral resources must be peripherals that exist in this real-time system, otherwise they should be rejected.

[0113] (32) Determine if peripheral I / O multiplexing conflicts exist? Strictly adhere to the time-sharing concept; a VM is not allowed to have the same peripheral. If a second partition (VM) is allocated the same peripheral, it is considered a peripheral I / O multiplexing conflict. If such a conflict is detected, the real-time system should reject resource change requests to ensure the stability and reliability of the real-time system.

[0114] (33) Determine if the peripheral base address is reasonable? The peripheral base address refers to the starting address of a peripheral in the memory-mapped space or I / O address space of a computer system. The peripheral base address must be within the available address range of the real-time system.

[0115] (4) Interrupt Numbers Occupied by Partitions: For time-sharing partitioning systems, interrupt numbers are assigned. Each VM may have its own interrupt numbers for many peripherals. As peripherals are deleted or added, interrupt numbers need to be deleted or added accordingly. The number of peripherals and the number of interrupt numbers in each second partition should be the same. Interrupt numbers in two second partitions should not be duplicated (i.e., they should not conflict). Interrupt number conflicts will cause the drivers of two peripherals to crash. Therefore, to determine whether the interrupt number of the new peripheral conflicts, we need to determine whether the interrupt number occupied by the modified partition is the same as the interrupt number in other second partitions. If they are the same, it means that there is an interrupt number conflict, and the MVM will directly refuse to make the change.

[0116] The purpose of the entire judgment process described above is to ensure that resource changes will not negatively impact the stability and performance of the system. Through reasonableness judgment, the system can avoid potential problems caused by improper resource configuration, such as resource conflicts, system overload, or service interruptions.

[0117] In some embodiments, causing the at least one second partition to perform resource configuration changes based on the updated current resource configuration includes:

[0118] When resource deletion is included, the at least one second partition shall perform resource deletion based on the deleted resource;

[0119] Write the current runtime context data to shared memory and stop running;

[0120] Initialize by reading the updated current resource configuration from the shared memory;

[0121] After reading the current running context data from the shared memory, operation resumes and the resource configuration changes are completed.

[0122] In specific implementation, the following operations are performed in step 440 for the deletion or modification of resources: MVM updates the configuration table of the modified VM in SHM, notifies the modified VM, MVM stops the operation of the modified VM, VM terminates the device-related threads in VM, VM unloads the driver of the deleted resource, releases memory, then VM is paused and suspended, VM copies the current running context data to the shared memory SHM (including process context and interrupt context), stops VM operation, VM restarts, VM obtains the new resource configuration (in the form of a configuration table) from SHM and initializes the new configuration, after initialization, VM is paused and suspended, copies the running context from SHM to VM, restores the VM running state, and completes the deletion of resources.

[0123] In some embodiments, causing the at least one second partition to perform resource configuration changes based on the updated current resource configuration includes:

[0124] When additional resources are added, the at least one second partition writes the current runtime context data to shared memory and stops running.

[0125] Initialize by reading the updated current resource configuration from the shared memory;

[0126] After reading the current running context data from the shared memory, operation resumes and the resource configuration changes are completed.

[0127] In specific implementation, the following operations are performed in step 440 for the addition and change of resources: MVM updates the configuration table of the changed VM in SHM, MVM notifies the changed VM, the VM is paused and suspended, the current running context data is copied to the shared memory SHM (including process context and interrupt context), MVM stops the running of the changed VM, the VM restarts, the VM obtains the new resource configuration (in the form of a configuration table) from SHM and initializes the new configuration. After initialization, the VM is paused and suspended, the running context is copied from SHM to the VM, the VM running state is restored, and the addition of resources is completed.

[0128] The above update of the configuration table of the corresponding VM in SHM is performed after it has been determined that the resource changes are reasonable, that is, before the resource deletion / addition change operation is performed, or it can be performed during the resource deletion / addition change operation, that is, after the VM copies the current running context data to the shared memory SHM and stops the VM from running.

[0129] Therefore, this application obtains the resource change request of the partition to be changed, and jointly determines whether the resource change is reasonable by combining it with the current resource configuration of each second partition stored in shared memory. If reasonable, it updates the current resource configuration in shared memory and the partition to be changed, allowing the partition to be changed to perform the resource configuration change according to the updated current resource configuration. This application allows the operating system to quickly and dynamically adjust the resource configuration of the partition at runtime without restarting the entire system, which can improve the resource allocation of time-sharing partitions. By using shared memory to save and restore the running state of the partition, it ensures that the running state of the partition can be effectively managed and restored during the resource change process. At the same time, the use of shared memory also improves the switching efficiency and ensures the real-time performance of the real-time system to a certain extent. The process is simple and saves time.

[0130] [Detailed Implementation of the Method for Dynamically Allocating Resources in Real-Time System Operation]

[0131] This application provides a specific implementation process for a method of dynamically allocating resources during real-time system operation. The application scenarios of this method are as follows:

[0132] The total resources of the real-time system are shown below:

[0133] CPU cores: CPU core 1, CPU core 2, CPU core 3;

[0134] Peripherals: GPIO0, GPIO1;

[0135] UART0, UART1, UART2, UART3;

[0136] SPI0, SPI1;

[0137] I2C0, I2C1;

[0138] USB0;

[0139] GMAC0;

[0140] Memory: Total RAM (1000MB)

[0141] Virtual interrupts: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12.

[0142] The real-time system consists of three partitions: VM1, VM2, and VM3. The initial resource configuration for VM1, VM2, and VM3 is as follows:

[0143] The resources of VM1 include: CPU core 1, RAM (100MB), GPIO0, SPI0, UART0, USB0, GMAC0, virtual interrupts 1, 2, 3, 4, and 5.

[0144] VM2's resources include: 2 CPU cores, 200MB RAM, 1 GPIO, 1 SPI, 1 UART, 0 I2C, and virtual interrupts 6, 7, 8, and 9.

[0145] VM3's resources include: CPU core 3, RAM (100MB), UART2, UART3, I2C1, and virtual interrupts 10, 11, and 12.

[0146] When a user wants to modify the resource configuration of any partition, the specific process of the method in this application embodiment is as follows: Figure 5 As shown, it includes:

[0147] 1. After the system initializes and runs, the three partitions (VM1, VM2, VM3) write their current resource configurations to the shared memory in the form of a configuration table. After the current resource configurations are written, an end marker is written to the shared memory.

[0148] 2. After detecting the end marker, the management partition reads the current resource configuration of each of the three partitions (VM1, VM2, VM3) from the shared memory, parses it to form a resource configuration master table, and sends it to the shared memory for storage.

[0149] The user then wants to make resource configuration changes to VM1 and VM2, specifically as follows:

[0150] The modified VM1 resources include: CPU core 1, RAM (200MB), GPIO0, UART0, UART1, GMAC0, and virtual interrupts 1, 2, 3, and 4.

[0151] The modified VM2 resources include: CPU core 2, RAM (200MB), GPIO1, SPI0, SPI1, I2C0, USB0, and virtual interrupts 5, 6, 7, 8, and 9.

[0152] 3. The management partition receives resource change requests from users for VM1 (the request includes: occupying CPU core 1, occupying peripherals GPIO0, UART0, UART1, GMAC0, occupying 200MB of RAM, and occupying virtual interrupts 1, 2, 3, and 4) and VM2 (the request includes: occupying CPU core 2, occupying peripherals GPIO1, SPI0, SPI1, I2C0, and USB0, occupying 200MB of RAM, and occupying virtual interrupts 5, 6, 7, 8, and 9). It compares the resource change requests for VM1 and VM2 with the overall resource configuration table in shared memory to obtain the expected change information for VM1 and VM2, as shown below:

[0153] Expected changes to VM1: RAM (100MB) is changed to RAM (200MB), peripherals SPI0 and USB0 are removed, peripheral UART1 is added, and the corresponding virtual interrupts are reassigned to 1, 2, 3, and 4.

[0154] Expected changes to VM2: Remove peripheral UART1, add peripherals SPI0 and USB0, and reassign the corresponding virtual interrupts to 5, 6, 7, 8, and 9.

[0155] 4. The management partition determines whether the resource change requests of VM1 and VM2 are reasonable based on the resource change requests and expected change information of VM1 and VM2. The specific determination steps are as follows:

[0156] 41. Determine whether the resource change requests of VM1 and VM2 contain CPU cores and whether those CPU cores exist in the system. If CPU cores are present, it means they have not been deleted. If those CPU cores exist in the system, it means the change is reasonable and there is no change.

[0157] 42. Determine whether the RAM of VM1 and VM2 has changed. If the RAM of VM1 has increased, determine whether the size of the RAM of VM1 is reasonable. Add the sizes of the RAM of VM1, VM2, and VM3 together. If the total is 500M, which is less than the total system size of 1G, it means that the change in the size of the RAM of VM1 is reasonable. At the same time, determine whether the starting address of the RAM of VM1 is reasonable. If it is reasonable, allow the change of the RAM of VM1 and mark it as allowed.

[0158] 43. Determine that the peripherals SPI0 and USB0 deleted from VM1 are valid, and the peripheral UART1 deleted from VM2 is valid, and mark them as allowed to be deleted.

[0159] 44. Determine whether the newly added peripheral UART1 on VM1 and the newly added peripherals SPI0 and USB0 on ​​VM2 are reasonable. The newly added peripherals UART1, SPI0, and USB0 exist in the system, and they have not been assigned after being deleted. They can be assigned to any VM. Furthermore, the addition of peripheral UART1 on VM1 does not conflict with the I / O multiplexing of its own GPIO0, UART0, and GMAC0. The addition of peripherals SPI0 and USB0 on ​​VM2 does not conflict with the I / O multiplexing of its own GPIO1, SPI1, and I2C0. Therefore, the addition of peripherals is reasonable and marked as allowed.

[0160] 45. Determine whether the virtual interrupt numbers of VM1 and VM2 are reasonable. VM1 has 4 peripherals corresponding to 4 virtual interrupt numbers, and VM2 has 5 peripherals corresponding to 5 virtual interrupt numbers. The 4 virtual interrupt numbers in VM1 are different from the 5 virtual interrupt numbers in VM2 and the 3 virtual interrupt numbers in VM3. Therefore, there is no conflict in the virtual interrupt numbers, and they are marked as allowed to be changed.

[0161] At this point, all changes to VM1 and VM2 have been evaluated and deemed valid. The new resource configurations in the resource change requests for VM1 and VM2 are then written into shared memory, replacing the original resource configurations of VM1 and VM2 in shared memory.

[0162] 5. Implement changes to the management partition, and send change notifications to VM1 and VM2 via shared memory to make the changes. The specific change steps are as follows:

[0163] 51. Delete VM1's peripherals SPI0 and USB0, stop running the related threads of peripherals SPI0 and USB0, uninstall the drivers of peripherals SPI0 and USB0, and remove the virtual interrupts corresponding to peripherals SPI0 and USB0. Delete VM2's peripheral UART1, stop running the related threads of peripheral UART1, uninstall the driver of peripheral UART1, and remove the virtual interrupts corresponding to peripheral UART1.

[0164] 52. Suspend VM1 and VM2, copy the current running context data of VM1 and VM2 to shared memory, and stop VM1 and VM2 from running;

[0165] 53. Restart VM1 and VM2. VM1 and VM2 read the new resource configuration from shared memory and initialize them. VM1 includes initializing the changed RAM, loading and initializing the driver of the newly added peripheral UART1, and initializing the virtual interrupt. VM2 includes loading and initializing the drivers of the newly added peripherals SPI0 and USB0, and initializing the virtual interrupt. After initialization, VM1 and VM2 are paused and suspended, and then resumed running by reading the corresponding runtime context data from shared memory. The resource change is complete.

[0166] [Example of the device for dynamically allocating resources during real-time system operation in this application]

[0167] like Figure 6 As shown, this application provides a device for dynamically allocating resources during real-time system operation. This device can be used to implement the method for dynamically allocating resources during real-time system operation described in the above embodiments, such as... Figure 6 As shown, the real-time system's dynamic resource allocation device has a resource change request acquisition module 610, a current resource configuration reading module 620, a change rationality judgment module 630, and a change module 640.

[0168] The resource change request acquisition module is used to acquire resource change requests for at least one of the second partitions, wherein the resource change request includes the resource configuration to be changed.

[0169] The current resource configuration reading module is used to read the current resource configuration of each second partition stored in shared memory;

[0170] The change rationality judgment module is used to determine whether the resource change is reasonable based on the resource configuration to be changed and the current resource configuration of each second partition;

[0171] The change module is used to update the current resource configuration of the corresponding at least one second partition in the shared memory according to the resource configuration to be changed when the resource change is reasonable, and to make the at least one second partition perform the resource configuration change according to the updated current resource configuration.

[0172] For details, please refer to the detailed description in the method embodiments, which will not be repeated here.

[0173] [Examples of the computing device in this application]

[0174] Figure 7This is a schematic structural diagram of a computing device 900 provided in an embodiment of this application. This computing device can serve as a dynamic resource allocation device in real-time system operation, executing various optional embodiments of the above-described dynamic resource allocation method in real-time system operation. The computing device can be a terminal, or a chip or chip system within the terminal. Figure 7 As shown, the computing device 900 includes: a processor 910, a memory 920, and a communication interface 930.

[0175] It should be understood that Figure 7 The communication interface 930 in the computing device 900 shown can be used to communicate with other devices, and may specifically include one or more transceiver circuits or interface circuits.

[0176] The processor 910 can be connected to the memory 920. The memory 920 can be used to store the program code and data. Therefore, the memory 920 can be a storage unit inside the processor 910, an external storage unit independent of the processor 910, or a component that includes both the storage unit inside the processor 910 and the external storage unit independent of the processor 910.

[0177] Optionally, the computing device 900 may also include a bus. The memory 920 and communication interface 930 can be connected to the processor 910 via the bus. The bus can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 7 The symbol is represented by a line without an arrow, but this does not mean that there is only one bus or one type of bus.

[0178] It should be understood that in the embodiments of this application, the processor 910 may be a central processing unit (CPU). The processor may also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor. Alternatively, the processor 910 may employ one or more integrated circuits to execute relevant programs to implement the technical solutions provided in the embodiments of this application.

[0179] The memory 920 may include read-only memory and random access memory, and provides instructions and data to the processor 910. A portion of the processor 910 may also include non-volatile random access memory. For example, the processor 910 may also store device type information.

[0180] When the computing device 900 is running, the processor 910 executes computer execution instructions stored in the memory 920 to perform any of the operational steps of the above method and any of the optional embodiments thereof.

[0181] It should be understood that the computing device 900 according to the embodiments of this application can correspond to the corresponding subject in executing the methods according to the various embodiments of this application, and the above and other operations and / or functions of each module in the computing device 900 are respectively for implementing the corresponding processes of the methods of this embodiment. For the sake of brevity, they will not be described in detail here.

[0182] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0183] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0184] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0185] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0186] In addition, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.

[0187] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0188] This application also provides a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, is used to perform the above-described method, which includes at least one of the schemes described in the above embodiments.

[0189] The computer storage medium in this application embodiment can be any combination of one or more computer-readable media. A computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. For example, a computer-readable storage medium can be, but is not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of computer-readable storage media (a non-exhaustive list) include: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this document, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device.

[0190] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, capable of sending, propagating, or transmitting programs for use by or in connection with an instruction execution system, apparatus, or device.

[0191] The program code contained on a computer-readable medium may be transmitted using any suitable medium, including, but not limited to, wireless, wire, optical fiber, RF, etc., or any suitable combination thereof.

[0192] Computer program code for performing the operations of this application can be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, and C++, and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0193] Furthermore, the terms "first, second, third, etc." or similar terms such as module A, module B, and module C used in the specification and claims are only used to distinguish similar objects and do not represent a specific ordering of objects. It is understood that, where permissible, a specific order or sequence may be interchanged so that the embodiments of this application described herein can be implemented in an order other than that illustrated or described herein.

[0194] In the above description, the labels of the steps involved, such as S6, S120, etc., do not mean that the steps will necessarily be executed. The order of the steps can be interchanged or executed simultaneously if permitted.

[0195] The term "comprising" as used in the specification and claims should not be construed as limiting itself to what follows; it does not exclude other elements or steps. Therefore, it should be interpreted as specifying the presence of the mentioned feature, integral, step, or component, but does not exclude the presence or addition of one or more other features, integrals, steps, or components, or groups thereof. Thus, the statement "device comprising means A and B" should not be limited to a device consisting solely of components A and B.

[0196] The terms "an embodiment" or "an embodiment" as used in this specification mean that a particular feature, structure, or characteristic described in conjunction with that embodiment is included in at least one embodiment of this application. Therefore, the terms "in one embodiment" or "in an embodiment" appearing throughout this specification do not necessarily refer to the same embodiment, but may refer to the same embodiment. Furthermore, in one or more embodiments, the particular features, structures, or characteristics can be combined in any suitable manner, as will be apparent to those skilled in the art from this disclosure.

[0197] Note that the above are merely preferred embodiments and the technical principles employed in this application. Those skilled in the art will understand that this application is not limited to the specific embodiments described herein, and various obvious changes, readjustments, and substitutions can be made without departing from the scope of protection of this application. Therefore, although this application has been described in detail through the above embodiments, this application is not limited to the above embodiments, and may include many other equivalent embodiments without departing from the concept of this application, all of which fall within the scope of protection of this application.

Claims

1. A method for dynamically allocating resources during real-time system operation, characterized in that, The real-time system includes: a first partition, at least one second partition, and shared memory; each second partition is configured with its own resources, and the corresponding resource configuration is written to the shared memory for storage; the dynamic resource allocation method is run on the first partition; The method includes: Obtain resource change requests for at least one of the second partitions, wherein the resource change requests include the resource configuration to be changed; Read the current resource configuration of each second partition stored in shared memory; Based on the resource configuration to be changed and the current resource configuration of each second partition, determine whether the resource change is reasonable; When the resource change is reasonable, the current resource configuration of the corresponding at least one second partition in the shared memory is updated according to the resource configuration to be changed, and the at least one second partition performs the resource configuration change according to the updated current resource configuration; The step of determining whether the resource change is reasonable based on the resource configuration to be changed and the current resource configuration of each second partition includes: The deletion and / or addition of resources in the resource change are determined based on the resource configuration to be changed and the current resource configuration of each second partition; When it is determined that only deleted resources are included, it is judged whether the deletion of resources is reasonable; When it is determined that only adding resources is included, it is judged whether the addition of resources is reasonable; When it is determined that the deletion of resources includes both deletion and addition of resources, it is then determined whether the deletion of resources is reasonable; if the deletion of resources is reasonable, then it is determined whether the addition of resources is reasonable.

2. The method according to claim 1, characterized in that, Also includes: If the resource change is unreasonable, refuse the change.

3. The method according to claim 1 or 2, characterized in that, The resource configuration to be changed includes one or more of the following resources: CPU cores occupied by the partition, memory occupied by the partition, peripherals occupied by the partition, and interrupt numbers occupied by the partition; The determination of whether a resource change is reasonable includes at least one of the following: Determine whether the CPU cores occupied by the partition have been deleted. If the CPU cores occupied by the partition have been deleted, it is unreasonable; if the CPU cores occupied by the partition have not been deleted, it is reasonable. Determine whether the memory occupied by the partition has been deleted. If the memory occupied by the partition has been deleted, it is unreasonable; if the memory occupied by the partition has not been deleted, it is reasonable. Determine whether the memory occupied by the added partition conflicts. If the memory address occupied by the added partition does not overlap with the memory address occupied by other second partitions, and the sum of the memory occupied by the added partition and the memory occupied by other second partitions is less than the memory size of the real-time system, then there is no conflict. If the memory address occupied by the added partition overlaps with the memory address occupied by other second partitions, and / or the sum of the memory occupied by the added partition and the memory occupied by other second partitions is greater than the memory size of the real-time system, then there is a conflict. Determine whether the peripherals occupied by the added partition are reasonable. If the peripherals occupied by the added partition exist in the real-time system, then it is reasonable. If the peripherals occupied by the added partition do not exist in the real-time system, then it is unreasonable. Determine whether the I / O multiplexing of the peripheral occupied by the added partition conflicts. If the peripheral occupied by the added partition is a peripheral occupied by another second partition, then there is a conflict. If the peripheral occupied by the added partition is not a peripheral occupied by another second partition, then there is no conflict. Determine whether the base address of the peripheral occupied by the added partition is within the available address range of the real-time system. If it is, it is reasonable; if not, it is unreasonable. Determine whether the interrupt number occupied by the added partition conflicts with the interrupt number in another second partition. If the interrupt number occupied by the added partition is the same as the interrupt number in another second partition, then there is a conflict. If the interrupt number occupied by the added partition is not the same as the interrupt number in another second partition, then there is no conflict.

4. The method according to claim 1, characterized in that, The step of causing the at least one second partition to perform resource configuration changes based on the updated current resource configuration includes: When resource deletion is included, the at least one second partition shall perform resource deletion based on the deleted resource; Write the current runtime context data to shared memory and stop running; Initialize by reading the updated current resource configuration from the shared memory; After reading the current running context data from the shared memory, operation resumes and the resource configuration changes are completed.

5. The method according to claim 1, characterized in that, The step of causing the at least one second partition to perform resource configuration changes based on the updated current resource configuration includes: When additional resources are added, the at least one second partition writes the current runtime context data to shared memory and stops running. Initialize by reading the updated current resource configuration from the shared memory; After reading the current running context data from the shared memory, operation resumes and the resource configuration changes are completed.

6. The method according to claim 1, characterized in that, The current resource configuration of each second partition stored in the shared memory is written by each second partition.

7. The method according to claim 1, characterized in that, The first partition is used to manage the shared memory and the respective second partitions.

8. A device for dynamically allocating resources during real-time system operation, characterized in that, The real-time system includes: a first partition, at least one second partition, and shared memory; each second partition is configured with its own resources, and the corresponding resource configuration is written to the shared memory for storage; a dynamic resource allocation method is running on the first partition; The dynamic resource allocation device includes: The resource change request acquisition module is used to acquire resource change requests for at least one of the second partitions, wherein the resource change request includes the resource configuration to be changed. The current resource configuration reading module is used to read the current resource configuration of each second partition stored in shared memory; The change rationality judgment module is used to determine whether a resource change is reasonable based on the resource configuration to be changed and the current resource configuration of each second partition. Specifically, the change rationality judgment module is used to: determine whether a resource change involves deleting or adding resources based on the resource configuration to be changed and the current resource configuration of each second partition; when it is determined that only deleting resources are included, determine whether the deletion of resources is reasonable; when it is determined that only adding resources are included, determine whether the addition of resources is reasonable; when it is determined that both deletion and addition of resources are included, determine whether the deletion of resources is reasonable; if the deletion of resources is reasonable, then determine whether the addition of resources is reasonable. The change module is used to update the current resource configuration of the corresponding at least one second partition in the shared memory according to the resource configuration to be changed when the resource change is reasonable, and to make the at least one second partition perform the resource configuration change according to the updated current resource configuration.

9. A real-time system, characterized in that, include: First partition, at least one second partition, shared memory; Each of the second partitions is configured with the resources it uses, and the corresponding resource configuration is written to the shared memory for storage; The first partition is equipped with the method described in any one of claims 1-7.

10. A computing device, characterized in that, include: processor, and A memory having stored program instructions that, when executed by the processor, cause the processor to perform the method according to any one of claims 1-7.

11. A computer-readable storage medium, characterized in that, It stores program instructions that, when executed by a computer, cause the computer to perform the method described in any one of claims 1-7.

Citation Information

Patent Citations

  • Improvement in harvesters

    US15843A

  • Method of bending

    US15944A

  • Valve fob

    US16351A

  • Storage management calculator, and storage management method

    CN104919429A