CN106293728B - power management method of multi-task TF (TransFlash) cryptographic module - Google Patents

power management method of multi-task TF (TransFlash) cryptographic module Download PDF

Info

Publication number
CN106293728B
CN106293728B CN201610631239.8A CN201610631239A CN106293728B CN 106293728 B CN106293728 B CN 106293728B CN 201610631239 A CN201610631239 A CN 201610631239A CN 106293728 B CN106293728 B CN 106293728B
Authority
CN
China
Prior art keywords
module
state
power management
password module
password
Prior art date
Application number
CN201610631239.8A
Other languages
Chinese (zh)
Other versions
CN106293728A (en
Inventor
王隶庞
赵建平
韦永刚
Original Assignee
成都三零瑞通移动通信有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 成都三零瑞通移动通信有限公司 filed Critical 成都三零瑞通移动通信有限公司
Priority to CN201610631239.8A priority Critical patent/CN106293728B/en
Publication of CN106293728A publication Critical patent/CN106293728A/en
Application granted granted Critical
Publication of CN106293728B publication Critical patent/CN106293728B/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping
    • G06F9/4418Suspend and resume; Hibernate and awake

Abstract

The invention discloses a power management method of a multi-task TF (TransFlash) cryptographic module, which comprises the following procedures: the Android terminal identifies the TF password module through the TF password module driving program; the TF power management module is initialized, and the TF password module is in a wake-up state after initialization is completed; if no service is sent to the TF password module by the terminal within the overtime time of the sleep timer, the TF password module is made to enter a dormant state; otherwise, the driver queries the state of the current TF cryptographic module, and if the current TF cryptographic module is in a dormant state, the driver performs state maintenance operation after executing wakeup operation; and if the state is the awakening state, directly performing state maintenance operation. The invention is realized by combining the requirements of an operating system based on the transformation of the matched driving program of the TF cryptographic module, has no special maintenance requirement, and is very suitable for the TF cryptographic module with higher requirements on power consumption and cryptographic resource maintenance.

Description

Power management method of multi-task TF (TransFlash) cryptographic module

Technical Field

The invention belongs to the technical field of embedding, and particularly relates to a power management method of a multitask TF (TransFlash) cryptographic module based on an Android intelligent operating system.

Background

The power management methods of the existing TF business secret code card are mainly divided into the following methods:

(1) Operating system bottom layer send instruction

In the mode, the Android power management function is registered in the driver of the bottom layer sdio/sd/mmc controller of the operating system, unified management of the operating system is received, the bottom layer controller is called to send a sleep instruction to the TF password module when the Android intelligent terminal needs to enter a sleep state, and a wake-up instruction is sent to the TF password module when the Android intelligent terminal needs to be used.

This method is limited by the sleep and wake mechanism of the operating system, and when the user uses other functions of the terminal, the operating system cannot enter into sleep, and the TF cryptographic module cannot enter into sleep even though it has no service requirement.

(2) operating system underlying offload logic

This power management approach is similar to (1), except that the underlying controller offloads the TF cipher logic when it needs to enter the sleep state, and re-identifies the TF cipher when it needs to be used.

In addition, the uninstallation and re-identification of the TF cipher module logic will result in that the cipher resource state cannot be preserved for a long time inside the TF cipher module, which will limit the applicable scope of the TF cipher module.

(3) Method for providing power management interface by application layer

In the mode, the TF password module provides a dormancy awakening interface related to power management called by an application layer, and a user designs a power management flow by himself.

The method has great limitation on the application layer multitask calling TF cryptographic modules, and the state condition of the TF cryptographic modules is required to be maintained between applications, so that the method is difficult to realize and the efficiency is greatly reduced.

Disclosure of Invention

In order to overcome the defects in the prior art, the invention provides a power management method of a multi-task TF (TransFlash) cryptographic module, which is different from the conventional power management method, is realized by combining the requirements of an operating system based on the modification of a matched driver of the TF cryptographic module, has no special maintenance requirement, and is very suitable for the TF cryptographic module with higher requirements on power consumption and cryptographic resource maintenance.

the technical scheme adopted by the invention for solving the technical problems is as follows: a power management method of a multi-task TF cryptographic module comprises the following procedures:

(1) After the Android terminal is started, the operating system supplies power to the TF password module; the Android terminal identifies the TF password module through the TF password module driving program;

(2) the TF power management module is initialized, and the TF password module is in a wake-up state after initialization is completed;

(3) Judging whether the terminal has a service to send to the TF password module within the overtime of the sleep timer: if not, making the TF password module enter a dormant state; if yes, entering the next process;

(4) the driver inquires the state of the current TF password module, and if the current TF password module is in a dormant state, the driver performs state maintenance operation after executing wakeup operation; and if the state is the awakening state, directly performing state maintenance operation.

Compared with the prior art, the invention has the following positive effects:

(1) The improvement based on TF cryptographic module driver is realized, maintenance cost is avoided, no additional equipment or kernel component is provided, and the applicability is good.

(2) the invention follows but is not limited by the dormancy awakening mechanism of the operation system, when the TF password module automatically enters dormancy at the time as long as no service requirement exists, and the terminal operation system can not influence the dormancy of the TF password module because other operations of a user can not enter dormancy. This way the power consumption due to the TF cryptographic module is greatly reduced. In addition, the invention follows the dormancy awakening mechanism of the operating system, ensures that the TF cryptographic module must be ensured to enter dormancy before the terminal operating system intends to enter deep sleep, and avoids the TF cryptographic module abnormity caused by inconsistent power management of the terminal and the TF cryptographic module.

(3) According to the invention, through a power management method of a special protocol, a working mode of a terminal controller is configured, so that power is always supplied to the TF password module after the Android operating system and the TF password module are in dormancy, and the controller does not unload the logic of the password module so as to store the state of password resources in the TF password module.

(4) The invention belongs to the realization of a bottom layer, the state is self-maintained, the sleep awakening is self-adaptive, an application layer does not need to maintain the state condition of the TF cipher module, and the sleep awakening interface of the application layer does not exist, so that the efficiency of the TF cipher module with the requirement of multi-task parallel calling is greatly improved.

Drawings

The invention will now be described, by way of example, with reference to the accompanying drawings, in which:

FIG. 1 is a schematic diagram of a multitask TF cryptographic module power management system;

fig. 2 is a schematic diagram of the TF power management module.

Detailed Description

the multitask TF cipher module power management system is shown in figure 1 and mainly comprises an Android operating system power management module, a TF cipher module driver and a TF cipher module, when cipher business is carried out, the driver of the cipher module is called by function through application software or a kernel component of an intelligent terminal, and the driver calls the cipher module uniformly through a standard sdio/sd/mmc protocol. The TF power management module belongs to a part of a driver and is the main body of the invention. The TF power management module is shown in fig. 2.

The TF power management module consists of a timer, a thread, a TF cryptographic module state machine and an operating system power management logic.

The implementation scheme of the invention is as follows:

the TF power management module in the driver is matched with the Android operating system power management module and the TF password module to complete the self-adaptive power management function of the TF password module supporting multiple tasks, and the specific process is as follows:

(1) After the Android terminal is started, the operating system supplies power to the TF password module;

(2) The Android terminal identifies the TF password module through the TF password module driving program;

(3) and the TF power management module completes initialization, including work of registering an operating system power management system function, setting an operating system deep sleep wakelock timer, setting a sleep timer, creating a thread, initializing a power management state machine and the like. The timeout time of the sleep timer is N seconds (N is recommended to be more than 5 and less than 20), the timeout time of the wakelock timer of the operating system is N +1 second, and the operation ensures that the operating system can enter deep sleep after the TF password module is in sleep. After the completion, the TF password module is in an awakening state;

(4) When the terminal has no service to send to the TF password module for more than N seconds, the TF power management module considers that the TF password module needs to enter a dormant state;

(5) and the power management module interacts with the TF password module according to a special dormancy protocol, so that the TF password module sleeps, a power management state machine is modified, and the physical voltage and the logic state of the underlying controller are maintained. Thus, the self-adaptive dormancy of the TF cryptographic module is completed.

(6) When some packet of terminal service data reaches the driver, the driver queries the state of the current TF cryptographic module through a state machine of the power management module, if the current TF cryptographic module is in a dormant state, the driver jumps to (7) to execute the awakening operation, and if the current TF cryptographic module is in the awakening state, the driver enters (8) to perform state maintenance operation.

(7) and the power management module interacts with the TF password module according to the special awakening protocol, awakens the TF password module, and then returns to normal service interaction, so that the self-adaptive awakening of the TF password module is completed.

(8) The state maintenance content includes operations of resetting sleep timer time in the TF power module, resetting operating system wakelock timer time, updating power management state machine, and the like. The reset timer uses the mod _ timer function provided by the operating system kernel. After the state is completed, the terminal returns to the state after the process (3) is completed (namely, the TF password module is in the wake-up state).

Claims (7)

1. a power management method of a multi-task TF cryptographic module is characterized in that: the method comprises the following steps:
(1) after the Android terminal is started, the operating system supplies power to the TF password module; the Android terminal identifies the TF password module through the TF password module driving program;
(2) The TF power management module is initialized, the TF password module is in an awakening state after the initialization is finished, and when the awakening operation is executed, the TF power management module interacts with the TF password module according to a special awakening protocol, awakens the TF password module and then returns to normal service interaction;
(3) Judging whether the terminal has a service to send to the TF password module within the overtime of the sleep timer: if not, the TF password module is enabled to enter a dormant state, when the TF password module needs to enter the dormant state, the TF power management module interacts with the TF password module according to a special dormant protocol, so that the TF password module is dormant, a power management state machine is modified, and the physical voltage and the logic state of the underlying controller are maintained; if yes, entering the next process;
(4) The driver inquires the state of the current TF password module, and if the current TF password module is in a dormant state, the driver performs state maintenance operation after executing wakeup operation; and if the state is the awakening state, directly performing state maintenance operation.
2. The method of claim 1, wherein the method further comprises: the initialization of the TF power management module includes: registering an operating system power management system function, setting the timeout time of an operating system deep sleep wakelock timer, setting the timeout time of a sleep timer, creating a thread, and initializing a power management state machine.
3. The method of claim 2, wherein the method further comprises: the timeout time of the operating system deep sleep wakelock timer is 1 second greater than the timeout time of the sleep timer.
4. the method of claim 3, wherein the method further comprises: the timeout time of the sleep timer is 5 to 20 seconds.
5. the method of claim 1, wherein the method further comprises: the state maintenance operation comprises the steps of resetting the overtime time of a sleep timer in the TF power module, resetting the overtime time of a deep sleep wakelock timer, and updating the operation of a power management state machine, wherein the TF password module is in a wake-up state after the state maintenance is finished.
6. The method of claim 5, wherein the method further comprises: the reset timer uses the mod _ timer function provided by the operating system kernel.
7. the method of claim 1, wherein the method further comprises: and the driving program inquires the state of the current TF password module through a state machine of the TF power management module.
CN201610631239.8A 2016-08-04 2016-08-04 power management method of multi-task TF (TransFlash) cryptographic module CN106293728B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610631239.8A CN106293728B (en) 2016-08-04 2016-08-04 power management method of multi-task TF (TransFlash) cryptographic module

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610631239.8A CN106293728B (en) 2016-08-04 2016-08-04 power management method of multi-task TF (TransFlash) cryptographic module

Publications (2)

Publication Number Publication Date
CN106293728A CN106293728A (en) 2017-01-04
CN106293728B true CN106293728B (en) 2019-12-13

Family

ID=57664688

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610631239.8A CN106293728B (en) 2016-08-04 2016-08-04 power management method of multi-task TF (TransFlash) cryptographic module

Country Status (1)

Country Link
CN (1) CN106293728B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109992360A (en) * 2017-12-29 2019-07-09 广东欧珀移动通信有限公司 Process handling method and device, electronic equipment, computer readable storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102117114A (en) * 2009-12-30 2011-07-06 重庆重邮信科通信技术有限公司 Electricity-saving method for embedded equipment
CN103823544A (en) * 2014-03-03 2014-05-28 哈尔滨工业大学深圳研究生院 Dynamic power supply management method
CN105183123A (en) * 2015-09-21 2015-12-23 北京元心科技有限公司 Method and device for power supply management multisystem based on container
CN105373207A (en) * 2014-08-20 2016-03-02 深圳飞音时代网络通讯技术有限公司 Standby method of wireless communication terminal
CN105630132A (en) * 2015-12-23 2016-06-01 深圳市万普拉斯科技有限公司 Power consumption control method and system as well as terminal

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102117114A (en) * 2009-12-30 2011-07-06 重庆重邮信科通信技术有限公司 Electricity-saving method for embedded equipment
CN103823544A (en) * 2014-03-03 2014-05-28 哈尔滨工业大学深圳研究生院 Dynamic power supply management method
CN105373207A (en) * 2014-08-20 2016-03-02 深圳飞音时代网络通讯技术有限公司 Standby method of wireless communication terminal
CN105183123A (en) * 2015-09-21 2015-12-23 北京元心科技有限公司 Method and device for power supply management multisystem based on container
CN105630132A (en) * 2015-12-23 2016-06-01 深圳市万普拉斯科技有限公司 Power consumption control method and system as well as terminal

Also Published As

Publication number Publication date
CN106293728A (en) 2017-01-04

Similar Documents

Publication Publication Date Title
US10845868B2 (en) Methods and apparatus for running and booting an inter-processor communication link between independently operable processors
US20170289916A1 (en) Power management via coordination and selective operation of timer-related tasks
CN106233249B (en) Apparatus and method for managing graphics buffers of sleep mode processor
US10649819B2 (en) Managing applications for power conservation
EP2754002B1 (en) Keep alive management
CN103902390B (en) Inter-process communication method based on Android application layer and basis application communication system
US20160378170A1 (en) Platform and processor power management
US10275586B2 (en) Method for power management using fingerprint identification in mobile terminal and mobile terminal
US7779451B2 (en) Securing wakeup network events
KR20140027875A (en) An ultra low power apparatus and method to wake up a main processor
US6467042B1 (en) Method and/or apparatus for lowering power consumption in a peripheral device
KR101689450B1 (en) Method and apparatus for enhancing a hibernate and resume process using user space synchronization
KR101503627B1 (en) Minimizing resource latency between processor application states in a portable computing device by scheduling resource set transitions
US7869835B1 (en) Method and system for pre-loading and executing computer instructions within the cache memory
US9904345B2 (en) Data processing method, modem, and terminal
US9229516B2 (en) Methods, devices, and computer program products for maintaining network presence while conserving power consumption
EP2756385B1 (en) Managing processes within suspend states and execution states
CN104149717B (en) A kind of long-range noiseless renewal system and method for car load control
US7529956B2 (en) Granular reduction in power consumption
EP2194745B1 (en) Power management for subscriber identity module
US10592254B2 (en) Technologies for fast low-power startup of a computing device
US7992018B2 (en) System device including NIC and power-saving controlling method of the same
CN104252389B (en) application program operation method, system
US9152205B2 (en) Mechanism for facilitating faster suspend/resume operations in computing systems
US8862709B2 (en) Remote management of boot application

Legal Events

Date Code Title Description
PB01 Publication
C06 Publication
SE01 Entry into force of request for substantive examination
C10 Entry into substantive examination
GR01 Patent grant
GR01 Patent grant