CN102163164A - Processing method and processor for critical data in shared memory - Google Patents

Processing method and processor for critical data in shared memory Download PDF

Info

Publication number
CN102163164A
CN102163164A CN2011101167022A CN201110116702A CN102163164A CN 102163164 A CN102163164 A CN 102163164A CN 2011101167022 A CN2011101167022 A CN 2011101167022A CN 201110116702 A CN201110116702 A CN 201110116702A CN 102163164 A CN102163164 A CN 102163164A
Authority
CN
China
Prior art keywords
critical data
shared drive
data
reparation
original value
Prior art date
Legal status (The legal status 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 status listed.)
Granted
Application number
CN2011101167022A
Other languages
Chinese (zh)
Other versions
CN102163164B (en
Inventor
董雪松
胡士辉
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Digital Technologies Chengdu Co Ltd
Huawei Digital Technologies Co Ltd
Original Assignee
Huawei Digital Technologies Chengdu Co Ltd
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 Huawei Digital Technologies Chengdu Co Ltd filed Critical Huawei Digital Technologies Chengdu Co Ltd
Priority to CN201110116702.2A priority Critical patent/CN102163164B/en
Publication of CN102163164A publication Critical patent/CN102163164A/en
Application granted granted Critical
Publication of CN102163164B publication Critical patent/CN102163164B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

The embodiment of the invention discloses a processing method for critical data in a shared memory. The method comprises the following steps of: storing a repair callback function pointer registered by a process before the process accesses to the shared memory; recording a primitive value of the critical data before that the process prepares to modify the critical data in the shared memory; and repairing the critical data in the shared memory after that the critical data in the shared memory is damaged by aborting of the process while accessing to the shared memory. The processing method for the critical data provided by the invention avoids that all the data in the shared memory are discarded after the critical data in the shared memory is damaged, and improves the reliability of the shared memory. The embodiment of the invention further provides a corresponding processor.

Description

The disposal route of the critical data in the shared drive and processor
Technical field
The present invention relates to communication technical field, be specifically related to the disposal route and the processor of the critical data in the shared drive.
Background technology
Along with the continuous expansion of built-in system software scale, in order to improve the reliability of system, industry mostly adopts operating system based on multi-process (as linux, freebsd) to replace the operating system (as vxworks) of one process multithreading.After adopting multiprocess system, face a system performance bottleneck---the problem of interprocess communication at once; Interprocess communication is exactly to propagate or exchange message between different processes.Industry generally adopts the mode of shared drive to come the problem of communicating by letter between treatment progress at present.Shared drive is exactly by a shared physical memory of a plurality of processes.If a plurality of processes all are mapped to this shared drive the address space of oneself, these processes just can directly be visited this shared drive, communicate by shared drive.For example, the meaning of two different process A, B shared drive is that same physical memory is mapped to process A, the B process address space separately.Process A can see the renewal of process B to data in the shared drive immediately, and process B writes in shared drive, and process A reads from shared drive, realizes two message exchanges between process in this way.
Process visit shared drive carries out in user's attitude, if process withdrawed from unusually and will enter kernel state by trap mechanism when visiting shared drive.
Data in the shared drive are divided into two kinds, and a kind of is critical data, and a kind of is load data.In shared drive, mostly data are to exist with forms such as chained lists, and wherein the pointer of chained list is exactly a critical data, that is to say that critical data is a kind of data that are used to connect data.When process is revised data in the shared drive,, just can guarantee not damage of overall data as long as critical data is not destroyed.Therefore, the data in the shared drive are damaged also and just refer to that the critical data in the shared drive is damaged.
Recovery after at present industry is damaged the critical data in the shared drive also do not have a solution.After the critical data in the shared drive is damaged, just directly lose the data in the whole shared drive.
Summary of the invention
The embodiment of the invention provides the disposal route and the processor of the critical data in a kind of shared drive, and the process that this technical scheme can the critical data in shared drive be withdrawed from is unusually revised the back and repaired critical data in the shared drive.
The disposal route of the critical data in the shared drive comprises:
Behind the pointer of the reparation call back function that user's attitude storage process is registered, process enters shared drive, and the pointer of described reparation call back function is used for calling the reparation call back function when repairing the critical data that has been modified of shared drive;
Before the critical data in described process preparation modification shared drive, the original value of the described critical data of track record, described critical data is to be used for the data that data connect in the shared drive;
After process withdraws from shared drive and enters kernel state by trap mechanism, if the zone bit of process indicates described process to use described shared drive, described process is sent back to user's attitude, described trap mechanism is exactly that process exception withdraws from the one section program that enters kernel state by user's attitude behind the shared drive, and described zone bit is used to indicate described process whether to use described shared drive;
Original value as the critical data of described track record, the critical data that confirms in the described shared drive is revised by described process, after the described critical data that has been modified need be repaired, use the pointer of described reparation call back function to call described reparation call back function, use described reparation call back function that the writing back in the critical data that has been modified in the shared drive of original value correspondence of described critical data gone.
A kind of processor comprises:
Storage unit is used for the pointer of the reparation call back function of storage process registration, and the pointer of described reparation call back function is used for calling the reparation call back function when repairing the critical data that has been modified of shared drive;
The track record unit was used for before described process is prepared to revise the critical data of shared drive, the original value of the described critical data of track record, and described critical data is to be used for the data that data connect in the shared drive;
Send the unit back to, be used for after process withdraws from shared drive and enters kernel state by trap mechanism, if the zone bit of process indicates described process to use described shared drive, described process is sent back to user's attitude, described trap mechanism is exactly that process exception withdraws from the one section program that enters kernel state by user's attitude behind the shared drive, and described zone bit is used to indicate described process whether to use described shared drive;
Call the reparation unit, be used for original value as the critical data of described track record, the critical data that confirms in the described shared drive is revised by described process, after the described critical data that has been modified need be repaired, use the pointer of described reparation call back function to call described reparation call back function, use described reparation call back function that the writing back in the critical data that has been modified in the shared drive of original value correspondence of described critical data gone.
The embodiment of the invention adopts the reparation call back function pointer of storage process registration before process visit shared drive, the original value of recorded key data before the critical data in process preparation modification shared drive, after when process visit shared drive, withdrawing from the critical data that causes in the shared drive unusually and being damaged, repair the critical data in the shared drive.The disposal route of critical data provided by the invention causes the data in the whole shared drive all to be abandoned after having avoided the critical data in the shared drive to be damaged, and has improved the reliability of shared drive.
Description of drawings
Fig. 1 is the first embodiment synoptic diagram of critical data disposal route in the embodiment of the invention;
Fig. 2 is the second embodiment synoptic diagram of critical data disposal route in the embodiment of the invention;
Fig. 3 A is the chain hoist pennants before the inventive method application scenarios embodiment is modified;
Fig. 3 B is the data tracking tabulation synoptic diagram of the inventive method application scenarios embodiment;
Fig. 3 C is the chain hoist pennants after the inventive method application scenarios embodiment is modified;
Fig. 3 D is the chain hoist pennants after the inventive method application scenarios embodiment is repaired;
Fig. 4 is the first embodiment synoptic diagram of processor in the embodiment of the invention.
Embodiment
The embodiment of the invention provides the disposal route of critical data in a kind of shared drive, can repair the critical data in the shared drive because of after process exception withdraws from the critical data that causes in the shared drive and be damaged.The embodiment of the invention also provides corresponding processor.Below be elaborated respectively.
See also Fig. 1, first embodiment of the disposal route of critical data in the embodiment of the invention comprises:
101, the pointer of the reparation call back function of storage process registration;
Process defines when initialization repairs call back function, and the pointer that will repair call back function registers to processor, and the pointer of call back function is repaired in the processor storage, and the pointer of repairing call back function is used for calling the reparation call back function when the reparation critical data.
102, before the critical data in process preparation modification shared drive, the original value of the critical data in the track record shared drive;
Critical data is to be used for the data that data connect in the shared drive, and for example, the pointer of chained list is exactly a critical data;
If process enters shared drive, prepare to revise the critical data in the shared drive, the original value of recorded key data before process is revised critical data if process does not prepare to revise the critical data in the shared drive, does not then write down the original value of critical data in the shared drive.
103, after described process withdraws from shared drive and enters kernel state by trap mechanism, judge according to the zone bit that described process is carried whether described shared drive is used by described process;
Trap mechanism is exactly that process exception withdraws from the one section program that enters kernel state by user's attitude behind the shared drive, and the process that withdraws from by trap mechanism must be the process that withdraws from unusually, and zone bit is used to indicate described process whether to use shared drive; If described zone bit indication is that described process was used described shared drive, execution in step 104, if the indication of described zone bit is that described process was not used described shared drive, execution in step 108.
104, described process is sent back to user's attitude;
105, according to the having or not of the original value of the critical data of described track record, judge whether the critical data in the described shared drive needs to repair;
If the original value of the critical data of track record is arranged, the critical data of then judging in the described shared drive is revised by process, need repair, execution in step 106, if the original value of the critical data of no track record, then judge described critical data and do not revised, do not need to repair execution in step 107 by process.
106, use the pointer of described reparation call back function to call described reparation call back function, use described reparation call back function that writing back in the shared drive in the critical data of being revised by process of the original value correspondence of described critical data gone;
With the original value of the critical data of step 102 track record, corresponding writing back in the shared drive in the critical data of being revised by process gone, and finishes the reparation of critical data;
After the critical data reparation is finished, the process that withdraws from is unusually sent back to kernel state, stop the process that this withdraws from unusually at kernel state.
107, described process is sent back to kernel state;
The critical data of judging in step 105 in the shared drive does not need to repair, and revises if mean the process that the critical data in the shared drive is not withdrawed from unusually, and this process that withdraws from is unusually sent back to kernel state, stops this process.
108, stop described process;
If the zone bit indication is that the process that withdraws from is not unusually used described shared drive in step 103, directly stop the described process that withdraws from unusually at kernel state.
The disposal route of critical data in the shared drive that present embodiment provides, the reparation call back function pointer of storage process registration before process visit shared drive, the original value of recorded key data before the critical data in process modification shared drive, after when process visit shared drive, withdrawing from the critical data that causes in the shared drive unusually and being damaged, repair the critical data in the shared drive.Compared with prior art, cause the data in the whole shared drive all to be abandoned after the disposal route of the critical data of the embodiment of the invention has avoided the critical data in the shared drive to be damaged, improved the reliability of shared drive.
Alternatively, in the above-described embodiments, step 103 can be omitted, and step 104 is revised as after process withdraws from shared drive and enters kernel state by trap mechanism, if the zone bit of process indicates described process to use described shared drive, described process is sent back to kernel state; Step 108 be revised as when the indication of described zone bit be described process when not using described shared drive, stop described process.
Alternatively, in the foregoing description, step 105 can also be omitted, step 106 is revised as when the original value of critical data is arranged, learn that the critical data in the shared drive revised by described process, use the pointer of described reparation call back function to call described reparation call back function, use described reparation call back function that writing back in the shared drive in the critical data of being revised by process of the original value correspondence of described critical data gone; Step 107 is revised as the original value when the critical data of no described track record, confirms described critical data and is not modified, and the critical data in the described shared drive does not send back to kernel state with described process after not needing to repair.
On the first embodiment basis, second embodiment of the disposal route of the critical data in the shared drive provided by the invention comprises:
201, set up a data tracking tabulation that comprises memory address field and initial value field, with recording in the data tracking tabulation of the original value correspondence of the critical data before being modified;
The original value of critical data comprises the memory address of critical data and the initial value of critical data, before the original value of recorded key data, set up a data tracking tabulation that comprises memory address field and initial value field, during the recorded key data, the memory address of critical data is recorded the memory address field that data tracking is tabulated, the initial value of critical data is recorded the initial value field of data tracking tabulation.Data tracking tabulation is a stack formula structure, before revising each critical data, the original value of each critical data is recorded in the data tracking tabulation successively, and the original value of the critical data that will be revised by process will be saved earlier earlier
202, the critical data of judging in the shared drive is revised by process;
203, use to repair call back function, the original value of the critical data of record in the data tracking tabulation is write back in the critical data of being revised by process go;
In finding the data tracking tabulation, the memory address of critical data and the initial value of critical data are arranged, just can confirm that the critical data in the shared drive needs to repair.
Memory address according to the critical data of record in the tabulation of step 201 data tracking, the initial value of the critical data of the memory address correspondence of critical data write back in the critical data of being revised by process go, finish the reparation of critical data, when repairing critical data, after the critical data that is modified, will preferentially be repaired during reparation.
The disposal route of critical data in the shared drive that present embodiment provides, on the first embodiment basis, follow the tracks of tabulation by setting up data before revising critical data in process, memory address field and the initial value field in the data tracking tabulation of recording with the memory address of the critical data before being modified and initial value correspondence, when repairing critical data, memory address according to the critical data of memory address field, the initial value of critical data write back in the critical data of being revised by process go, realize the reparation of critical data in the shared drive.Compared with prior art, cause the data in the whole shared drive all to be abandoned after the disposal route of the critical data of the embodiment of the invention has avoided the critical data in the shared drive to be damaged, improved the reliability of shared drive.
Alternatively, in the foregoing description, step 202 can be omitted, after step 203 is revised as critical data in confirming shared drive and has been modified, use to repair call back function, the original value of the critical data of record in the data tracking tabulation is write back in the critical data of being revised by process go.
For ease of understanding, be described in detail with the disposal route of a concrete application scenarios below the critical data described in the foregoing description, concrete:
Consult Fig. 3 A and 3B, with the chained list is example, choose three nodes in the chained list, first node 301, Section Point 302 and the 3rd node 303, first node 301 links to each other by pointer separately is double-stranded with Section Point 302, and the pointer of node is exactly the critical data of chained list, and the 3rd node 303 is independent of outside first node 301 and the Section Point 302.
Process will be repaired the call back function pointer and be registered to behind the processor, prepare the visit shared drive, process enters shared drive, the original value of recorded key data before the pointer in process modification node, process will be inserted into first node 301 to the 3rd node 303 and Section Point 302 is middle, revise in process before the critical data n of first node 301, set up the data tracking tabulation, the initial value Node302 of the memory address node301->n of the critical data n of record first node 301 and the critical data n of first node 301, at the critical data n of first node 301 with after the critical data p of the 3rd node 303 sets up double-stranded the connection, memory address node302->the p of the critical data p of record Section Point 302 and the initial value Node301 of Section Point 302 withdraw from shared drive unusually and enter kernel state by trap mechanism when process is revised Section Point.
Consult Fig. 3 C, after process exception withdrawed from, the duplex structure of first node 301 and the 3rd node 303 had also been revised complete, Section Point 302 and the 3rd node 303 have only strand, an other chain does not also have enough time to revise, and process just withdraws from, and enters kernel state by user's attitude.
The process that the zone bit indication that process is carried is withdrawed from was unusually used shared drive, and the process that withdraws from is unusually sent back to user's attitude.Follow the tracks of the first node 301 of record in the tabulation and the original value of Section Point 302 according to critical data, the critical data of judging first node and Section Point needs to repair, use the pointer of repairing call back function to call the reparation call back function, use and repair call back function, memory address node302->p according to the critical data p of the Section Point 302 of record in the data tracking tabulation, the initial value Node301 of Section Point 302 is write back among the critical data p of Section Point 302, repair Section Point 302.According to the memory address node301->n of the critical data n in the first node 301 the initial value Node302 of the critical data n of first node 301 is write back among the critical data n in the first node 301 then, repair first node 301.
Consult Fig. 3 D, the chain hoist pennants after being repaired, first node 301 and Section Point 302 be modified before identical, still be in double-stranded linking status, the 3rd node 303 still independent with first node 301 and Section Point 302 outside.
After chained list was repaired, the process that withdraws from unusually was sent back to kernel state, stops this process.
Above-mentioned is the introduction that example is carried out critical data disposal route of the present invention with the chained list, the reparation call back function pointer of employing storage process registration before process visit shared drive, and the original value of recorded key data, after when process visit shared drive, withdrawing from the critical data that causes in the shared drive unusually and being damaged, repair the disposal route of the critical data in the shared drive.Compared with prior art, cause the data in the whole shared drive all to be abandoned after the disposal route of the critical data of the embodiment of the invention has avoided the critical data in the shared drive to be damaged, improved the reliability of shared drive.
Introduce the processor in the embodiment of the invention below, see also Fig. 4, the processor in the embodiment of the invention comprises:
Storage unit 401 is used for the pointer of the reparation call back function of storage process registration, and the pointer of described reparation call back function is used for calling the reparation call back function when repairing the critical data that has been modified of shared drive;
Track record unit 402 was used for before described process is prepared to revise the critical data of shared drive, the original value of the described critical data of track record, and described critical data is to be used for the data that data connect in the shared drive;
Judging unit 403, be used in described track record unit 402 before described process is prepared to revise the critical data of shared drive, behind the original value of the described critical data of track record, after described process withdraws from shared drive and enters kernel state by trap mechanism, judge according to the zone bit that described process is carried whether described process used described shared drive.
Send unit 404 back to, be used for after process withdraws from shared drive and enters kernel state by trap mechanism, if the zone bit of process indicates described process to use described shared drive, described process is sent back to user's attitude, described trap mechanism is exactly that process exception withdraws from the one section program that enters kernel state by user's attitude behind the shared drive, and described zone bit is used to indicate described process whether to use described shared drive;
Call and repair unit 405, be used for original value as the critical data of described track record, the critical data that confirms in the described shared drive is revised by described process, after the described critical data that has been modified need be repaired, use the pointer of described reparation call back function to call described reparation call back function, use described reparation call back function that the writing back in the critical data that has been modified in the shared drive of original value correspondence of described critical data gone;
The described unit 404 of sending back to is used for the original value when the critical data of no described track record, confirms described critical data and is not modified, and the critical data in the described shared drive does not send back to kernel state with described process after not needing to repair;
Stop unit 406, what be used for indicating when described zone bit is described process when not using described shared drive, stops described process.
Described judging unit 403, be further used for described send unit 404 back to described process sent back to user's attitude after, according to having or not of the original value of the critical data of described track record, judge whether the critical data in the described shared drive is modified.
Described termination unit 406, be further used for described send unit 404 back to described process sent back to kernel state after, stop described process.
Described track record unit 402 also is used to set up a data tracking tabulation that comprises memory address field and initial value field, with the memory address field and the initial value field that are stored in the data tracking tabulation of the initial value correspondence of the memory address of critical data in the shared drive and critical data.
The original value of described critical data comprises the memory address of critical data and the initial value of critical data;
Described track record unit 402, be further used for setting up a data tracking tabulation that comprises memory address field and initial value field, the original value of described critical data comprises the memory address of critical data and the initial value of critical data, before described process is prepared to revise critical data, with the memory address field and the initial value field that record described data tracking tabulation of the initial value correspondence of the memory address of described critical data and critical data;
Described calling repaired unit 405, be used for the critical data that shared drive is modified of writing back to of the original value correspondence of described critical data is meant memory address according to described critical data, the initial value of described critical data is write back under the memory address of corresponding institute's critical data.
Behind the pointer of the reparation call back function that storage unit 401 storage process are registered, the original value of critical data in the track record unit 402 record shared drives, after process exception withdraws from shared drive, the zone bit that judging unit 403 carries according to process judges whether this process used shared drive, if this process was used shared drive, send unit 404 back to this process is sent back to user's attitude, judging unit 403 is according to the rare thing of the original value of critical data, judge whether the critical data in the shared drive needs to repair, repair if need, call and repair unit 405 and call reparation call back function pointer in the storage unit 401, use reparation call back function pointer to call the reparation call back function, the original value of the critical data of record in the track record unit 402 is write back in the critical data that is modified go.The embodiment of the invention can withdraw from the critical data that causes in the shared drive unusually and is damaged when process is visited shared drive after, repair the critical data in the shared drive, avoided the data in the whole shared drive to be dropped, improved the reliability of shared drive.
Alternatively, in the embodiment of above-mentioned processor, judging unit 403 can omit, and sends unit 404 back to and is used for withdrawing from shared drive in process and enters kernel state by trap mechanism, the zone bit of process sends back to user's attitude with described process after indicating described process to use described shared drive.
In the foregoing description, after judging unit 403 omits, call when repairing unit 405 and being used for the original value of recorded key data being arranged in 402 track record unit, learn that the critical data in the shared drive revised by described process, use the pointer of described reparation call back function to call described reparation call back function, use described reparation call back function that writing back in the shared drive in the critical data of being revised by process of the original value correspondence of described critical data gone.
One of ordinary skill in the art will appreciate that all or part of step in the whole bag of tricks of the foregoing description is to instruct relevant hardware to finish by program, this program can be stored in the computer-readable recording medium, and storage medium can comprise: ROM, RAM, disk or CD etc.
More than the disposal route and the processor of the critical data in the shared drive that the embodiment of the invention provided is described in detail, used specific case herein principle of the present invention and embodiment are set forth, the explanation of above embodiment just is used for helping to understand method of the present invention and core concept thereof; Simultaneously, for one of ordinary skill in the art, according to thought of the present invention, the part that all can change in specific embodiments and applications, in sum, this description should not be construed as limitation of the present invention.

Claims (12)

1. the disposal route of the critical data in the shared drive is characterized in that, comprising:
Behind the pointer of the reparation call back function that user's attitude storage process is registered, process enters shared drive, and the pointer of described reparation call back function is used for calling the reparation call back function when repairing the critical data that has been modified of shared drive;
Before the critical data in described process preparation modification shared drive, the original value of the described critical data of track record, described critical data is to be used for the data that data connect in the shared drive;
After process withdraws from shared drive and enters kernel state by trap mechanism, if the zone bit of process indicates described process to use described shared drive, described process is sent back to user's attitude, described trap mechanism is exactly that process exception withdraws from the one section program that enters kernel state by user's attitude behind the shared drive, and described zone bit is used to indicate described process whether to use described shared drive;
Original value as the critical data of described track record, the critical data that confirms in the described shared drive is revised by described process, after the described critical data that has been modified need be repaired, use the pointer of described reparation call back function to call described reparation call back function, use described reparation call back function that the writing back in the critical data that has been modified in the shared drive of original value correspondence of described critical data gone.
2. the disposal route of the critical data in the shared drive according to claim 1 is characterized in that, before the critical data in described process preparation modification shared drive, comprises after the step of the original value of the described critical data of track record:
After described process withdraws from shared drive and enters kernel state by trap mechanism, judge according to the zone bit that described process is carried whether described process used described shared drive.
3. the disposal route of critical data is characterized in that in the shared drive according to claim 1, also comprises: when the indication of described zone bit be described process when not using described shared drive, stop described process.
4. the disposal route of the critical data in the shared drive according to claim 2 is characterized in that, comprises after described process being sent back to the step of user's attitude described:
According to having or not of the original value of the critical data of described track record, judge whether the critical data in the described shared drive is modified.
5. the disposal route of critical data in the shared drive according to claim 4, it is characterized in that, also comprise: when the original value of the critical data of no described track record, confirming described critical data is not modified, critical data in the described shared drive does not send back to kernel state with described process after not needing to repair.
6. the disposal route of the critical data in the shared drive according to claim 5 is characterized in that the critical data in confirming described shared drive is not modified, and comprises after described process is sent back to kernel state:
After described process is sent back to kernel state, stop described process;
After the critical data that has been modified in described shared drive is repaired, comprising:
Described process is sent back to kernel state;
After described process is sent back to kernel state, stop described process.
7. according to the disposal route of critical data in any described shared drive of claim 1~6, it is characterized in that described before described process is prepared to revise critical data, the original value of the critical data in the track record shared drive comprises:
Set up a data tracking tabulation that comprises memory address field and initial value field, the original value of described critical data comprises the memory address of critical data and the initial value of critical data; Before described process is prepared to revise critical data, with the memory address field and the initial value field that record described data tracking tabulation of the initial value correspondence of the memory address of described critical data and critical data;
The critical data that is modified in the shared drive that writes back to of described original value correspondence with described critical data is meant memory address according to described critical data, and the initial value of described critical data is write back under the memory address of corresponding institute's critical data.
8. a processor is characterized in that, comprising:
Storage unit is used for the pointer of the reparation call back function of storage process registration, and the pointer of described reparation call back function is used for calling the reparation call back function when repairing the critical data that has been modified of shared drive;
The track record unit was used for before described process is prepared to revise the critical data of shared drive, the original value of the described critical data of track record, and described critical data is to be used for the data that data connect in the shared drive;
Send the unit back to, be used for after process withdraws from shared drive and enters kernel state by trap mechanism, if the zone bit of process indicates described process to use described shared drive, described process is sent back to user's attitude, described trap mechanism is exactly that process exception withdraws from the one section program that enters kernel state by user's attitude behind the shared drive, and described zone bit is used to indicate described process whether to use described shared drive;
Call the reparation unit, be used for original value as the critical data of described track record, the critical data that confirms in the described shared drive is revised by described process, after the described critical data that has been modified need be repaired, use the pointer of described reparation call back function to call described reparation call back function, use described reparation call back function that the writing back in the critical data that has been modified in the shared drive of original value correspondence of described critical data gone.
9. processor according to claim 8 is characterized in that, also comprises:
Judging unit, be used in described track record unit before described process is prepared to revise the critical data of shared drive, behind the original value of the described critical data of track record, after described process withdraws from shared drive and enters kernel state by trap mechanism, judge according to the zone bit that described process is carried whether described process used described shared drive; With
Stop the unit, be used for when judging that according to described zone bit described process was not used described shared drive, stopping described process.
10. processor according to claim 9 is characterized in that, comprising:
Described judging unit, be further used for described send the unit back to described process sent back to user's attitude after, according to having or not of the original value of the critical data of described track record, judge whether the critical data in the described shared drive is modified; With
The described unit of sending back to is further used for the original value when the critical data of no described track record, confirms described critical data and is not modified, and the critical data in the described shared drive does not send back to kernel state with described process after not needing to repair.
11. processor according to claim 10 is characterized in that, comprising:
Described termination unit, be further used for described send the unit back to described process sent back to kernel state after, stop described process.
12. any according to Claim 8~11 described processor is characterized in that, comprising:
Described track record unit, be further used for setting up a data tracking tabulation that comprises memory address field and initial value field, the original value of described critical data comprises the memory address of critical data and the initial value of critical data, before described process is prepared to revise critical data, with the memory address field and the initial value field that record described data tracking tabulation of the initial value correspondence of the memory address of described critical data and critical data;
The described reparation unit that calls, be used for the critical data that shared drive is modified of writing back to of the original value correspondence of described critical data is meant memory address according to described critical data, the initial value of described critical data is write back under the memory address of corresponding institute's critical data.
CN201110116702.2A 2011-05-06 2011-05-06 Processing method and processor for critical data in shared memory Expired - Fee Related CN102163164B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201110116702.2A CN102163164B (en) 2011-05-06 2011-05-06 Processing method and processor for critical data in shared memory

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201110116702.2A CN102163164B (en) 2011-05-06 2011-05-06 Processing method and processor for critical data in shared memory

Publications (2)

Publication Number Publication Date
CN102163164A true CN102163164A (en) 2011-08-24
CN102163164B CN102163164B (en) 2014-06-25

Family

ID=44464401

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201110116702.2A Expired - Fee Related CN102163164B (en) 2011-05-06 2011-05-06 Processing method and processor for critical data in shared memory

Country Status (1)

Country Link
CN (1) CN102163164B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106201749A (en) * 2016-08-29 2016-12-07 东软集团股份有限公司 The access control method of a kind of shared drive, Apparatus and system
CN107733837A (en) * 2016-08-11 2018-02-23 杭州迪普科技股份有限公司 Method for detecting abnormality and device based on application layer Network Abnormal message
CN110659083A (en) * 2019-09-19 2020-01-07 苏州浪潮智能科技有限公司 Method and system for recovering memory data after program fault restart
WO2022052730A1 (en) * 2020-09-08 2022-03-17 华为技术有限公司 Method and apparatus for repairing abnormal application exit, and electronic device

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101017448A (en) * 2007-03-12 2007-08-15 中国建设银行股份有限公司 Dynamic refresh method and system for data
CN101425052A (en) * 2008-12-04 2009-05-06 中国科学院计算技术研究所 Method for implementing transactional memory

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101017448A (en) * 2007-03-12 2007-08-15 中国建设银行股份有限公司 Dynamic refresh method and system for data
CN101425052A (en) * 2008-12-04 2009-05-06 中国科学院计算技术研究所 Method for implementing transactional memory

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107733837A (en) * 2016-08-11 2018-02-23 杭州迪普科技股份有限公司 Method for detecting abnormality and device based on application layer Network Abnormal message
CN106201749A (en) * 2016-08-29 2016-12-07 东软集团股份有限公司 The access control method of a kind of shared drive, Apparatus and system
CN106201749B (en) * 2016-08-29 2019-04-26 东软集团股份有限公司 A kind of access control method of shared drive, apparatus and system
CN110659083A (en) * 2019-09-19 2020-01-07 苏州浪潮智能科技有限公司 Method and system for recovering memory data after program fault restart
WO2022052730A1 (en) * 2020-09-08 2022-03-17 华为技术有限公司 Method and apparatus for repairing abnormal application exit, and electronic device

Also Published As

Publication number Publication date
CN102163164B (en) 2014-06-25

Similar Documents

Publication Publication Date Title
US10983874B2 (en) Processing a recover state input/output request
CN108205506B (en) Virtual machine live migration method, virtual machine memory data processing method, server and virtual machine system
US20120254114A1 (en) Method and system for replicating data
CN103562878A (en) Storage checkpointing in a mirrored virtual machine system
CN102163164B (en) Processing method and processor for critical data in shared memory
EP2879054A2 (en) Communication control device, information processing apparatus, parallel computer system, and control method for parallel computer system
CN102419729A (en) Parallel test execution
US11321117B2 (en) Persistent multi-word compare-and-swap
WO2015039582A1 (en) Virtual resource allocation method and apparatus
CN104268097B (en) A kind of metadata processing method and system
KR20150103886A (en) Data processing apparatus for pipeline execution acceleration and method thereof
CN108369519A (en) The instruction block that replayed portion executes in the processor-based system for executing model using block-atom
CN105892954A (en) Data storage method and device based on multiple copies
CN104142802A (en) Memory control apparatus and method
CN102799490A (en) System and method for realizing one-to-many interprocess communication
CN109542860B (en) Service data management method based on HDFS and terminal equipment
US20100325373A1 (en) Duplexing Apparatus and Duplexing Control Method
CN109508151A (en) A method of promoting solid state hard disk performance
CN106844094B (en) File repair method and device
CN113342698A (en) Test environment scheduling method, computing device and storage medium
CN110908644B (en) Configuration method and device of state node, computer equipment and storage medium
US10528253B2 (en) Increased bandwidth of ordered stores in a non-uniform memory subsystem
JP2006227923A (en) Disk management apparatus and program
CN109791541B (en) Log serial number generation method and device and readable storage medium
US7568121B2 (en) Recovery from failure in data storage systems

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C53 Correction of patent of invention or patent application
CB02 Change of applicant information

Address after: 100085 Beijing, Haidian District on the road, No. 3

Applicant after: Beijing Huawei Digital Technology Co.,Ltd.

Address before: 100085 Beijing, Haidian District on the road, No. 3

Applicant before: Huawei Digit Technology Co., Ltd.

COR Change of bibliographic data

Free format text: CORRECT: APPLICANT; FROM: HUAWEI DIGIT TECHNOLOGY CO., LTD. TO: BEIJING HUAWEI DIGITAL TECHNOLOGY CO., LTD.

C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20140625

Termination date: 20190506

CF01 Termination of patent right due to non-payment of annual fee