This application provides a configuration method and related apparatus. During the configuration of AOP and TrustZone, it is necessary to first query the configuration status of TrustZone. Upon confirming that TrustZone configuration is complete, it can also be confirmed that xPU is enabled. Then, when xPU is enabled, the configuration parameters of AOP are
read through xPU to complete the AOP configuration. This application adjusts the timing during the configuration process, placing the step of reading the AOP configuration parameters through xPU after querying the TrustZone configuration status. This avoids
system crashes caused by calling xPU when it is not enabled, improving the success rate of internal
system environment configuration and enhancing user experience.