CN108052411A - The restorative procedure and device that a kind of single-track link table interrupts - Google Patents
The restorative procedure and device that a kind of single-track link table interrupts Download PDFInfo
- Publication number
- CN108052411A CN108052411A CN201711440304.XA CN201711440304A CN108052411A CN 108052411 A CN108052411 A CN 108052411A CN 201711440304 A CN201711440304 A CN 201711440304A CN 108052411 A CN108052411 A CN 108052411A
- Authority
- CN
- China
- Prior art keywords
- node
- chained list
- link table
- track link
- pointer
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/0796—Safety measures, i.e. ensuring safe condition in the event of error, e.g. for controlling element
Abstract
The application provides the restorative procedure and device that a kind of single-track link table interrupts, applied to storage device, the described method includes:When the Loss Of Pointer in either objective node in single-track link table or mistake, the logically affiliated target chained list of the destination node is judged;Each node before destination node described in the destination node and the target chained list, the tail node in the target chained list logically carry to identify the mark that node has been found in each node in another chained list in the single-track link table in addition to the target chained list;After the latter node of the destination node is found in the target chained list based on default inquiry mode, the pointer for the latter node for being directed toward the destination node is repaired in the destination node.Using the technical method of the application, the reliability of single-track link table can be improved.
Description
Technical field
This application involves technical field of data storage, restorative procedure and device that more particularly to a kind of single-track link table interrupts.
Background technology
Single-track link table is a kind of data structure on basis, is made of several nodes, each node is by data field and refers to
Pin domain two parts composition.Wherein, for data field for storing data, pointer field is used to store the pointer of next node.
Fig. 1 is referred to, Fig. 1 is a kind of schematic diagram of single-track link table.Physically, each node of single-track link table is in company
Continuous storage state, logically, each node of single-track link table determines the access order of each node based on pointer.When due to hardware or
When person's software issue causes the pointer in the pointer field of a certain node destroyed, storage device will be unable to after the node is accessed
Data in each node cause the interruption of single-track link table.
For example, in Fig. 1, when the pointer in node 2 is destroyed, storage device will be unable to that node 3 and node is accessed
Use_tail。
In the prior art, in order to solve the disruption of single-track link table, it is proposed that a kind of doubly linked list.Fig. 2 is referred to, is schemed
2 be a kind of schematic diagram of the doubly linked list proposed in the prior art.Each node includes a data field and two in doubly linked list
Pointer field, data field is for storing data, and a pointer field is used to store the pointer of next node, another pointer field is used for
Store the pointer of a node.Similarly, physically, each node of doubly linked list is in continuous state, logically,
Each node of doubly linked list determines the access order of each node based on pointer.Wherein, there is positive access and anti-in doubly linked list
To access.It is since the head node of chained list that forward direction, which accesses, is accessed based on each node middle finger to the pointer of next node,
Until the tail node of chained list.Inverted access is since the tail node of chained list, based on the upward node of each node middle finger
The order of pointer access, until the head node of chained list.
When storage device accesses each node of doubly linked list based on a direction, if doubly linked list interrupts, that
Storage device can access each node of doubly linked list based on another direction, thereby may be ensured that in a certain access direction hair
In the case that raw chained list interrupts, each node in doubly linked list still can be accessed by another access direction, be carried with this
The reliability of high doubly linked list.
In the prior art, the either increase of single-track link table or doubly linked list all supporting nodes and delete operation.By
Node in doubly linked list preserves the pointer for being directed toward previous node for one more than the node in single-track link table, therefore, two-way
Chained list consumes memory more than single-track link table, meanwhile, the time ratio that increase or deletion of node are consumed in doubly linked list is in list
The time that increase or deletion of node are consumed into chained list is more.
In higher equipment is required to process performance, doubly linked list is not suitable as the data storage knot of this kind equipment
Structure.
The content of the invention
In view of this, the application provides the restorative procedure and device that a kind of single-track link table interrupts, and applied to storage device, uses
In the reliability for improving single-track link table.
Specifically, the application is achieved by the following technical solution:
The restorative procedure that a kind of single-track link table interrupts, applied to storage device, logically, the single-track link table is divided into and making
With chained list and idle chained list, physically, each node Coutinuous store in the single-track link table, including:
When the Loss Of Pointer in either objective node in single-track link table or mistake, the destination node is judged logically
Affiliated target chained list;
Each node, the target chained list described in the destination node and the target chained list before destination node
In tail node, logically carry in each node in another chained list in the single-track link table in addition to the target chained list
For identifying the mark that node has been found;
After the latter node of the destination node is found in the target chained list based on default inquiry mode,
The pointer for the latter node for being directed toward the destination node is repaired in the destination node;Wherein, after the destination node
One node is the start node when last time found based on the inquiry mode travels through the target chained list.
The prosthetic device that a kind of single-track link table interrupts, applied to storage device, logically, the single-track link table is divided into and making
With chained list and idle chained list, physically, each node Coutinuous store in the single-track link table, including:
Judging unit, for when the Loss Of Pointer in either objective node in single-track link table or mistake when, judge the mesh
Mark the logically affiliated target chained list of node;
Unit is carried, for each section before the destination node described in the destination node and the target chained list
Point, the logically tail node in the target chained list, another chained list in the single-track link table in addition to the target chained list
In each node in carry for identifying the mark that node has been found;
Unit is repaired, the destination node is found in the target chained list based on default inquiry mode for working as
After the latter node, the pointer for the latter node for being directed toward the destination node is repaired in the destination node;Wherein, it is described
The latter node of destination node is the rising when last time found based on the inquiry mode travels through the target chained list
Beginning node.
The advantageous effect that the technical method that the application provides is brought:
In this application, when the Loss Of Pointer of either objective node in single-track link table or mistake, storage device can be with
Each node, the mesh in the logically affiliated target chained list of the destination node, the destination node before the destination node
It marks and is taken in each node in another chained list in logic in the tail node of chained list, single-track link table in addition to the target chained list
Band is used to identify the mark that node has been found.When the last time traversal that storage device is found based on default inquiry mode
After start node (node is the latter node of destination node) during the target chained list, repair and refer in destination node
To the pointer of the latter node of destination node, therefore it can realize and not use the technology of doubly linked list to improve the reliable of chained list
Property.
Description of the drawings
Fig. 1 is a kind of schematic diagram of single-track link table;
Fig. 2 is a kind of schematic diagram of the doubly linked list proposed in the prior art;
Fig. 3 is the restorative procedure flow chart that a kind of single-track link table shown in the embodiment of the present application one interrupts;
Fig. 4 is the physical storage structure of each node and the compares figure using chained list, idle chained list in single-track link table;
Fig. 5 is the principle schematic that node is added in single-track link table;
Fig. 6 is to carry mark in the node of single-track link table when single-track link table is interrupted shown in the embodiment of the present application one
The schematic diagram of note;
Fig. 7 is the flow of the latter node that destination node is searched in target chained list shown in the embodiment of the present application one
Figure;
Fig. 8 is one kind of storage device where the prosthetic device that a kind of single-track link table shown in the embodiment of the present application two interrupts
Hardware structure diagram;
Fig. 9 is the prosthetic device that a kind of single-track link table shown in the embodiment of the present application two interrupts.
Specific embodiment
Here exemplary embodiment will be illustrated in detail, example is illustrated in the accompanying drawings.Following description is related to
During attached drawing, unless otherwise indicated, the same numbers in different attached drawings represent the same or similar element.Following exemplary embodiment
Described in embodiment do not represent all embodiments consistent with the application.On the contrary, they be only with it is such as appended
The example of the consistent apparatus and method of some aspects be described in detail in claims, the application.
It is only merely for the purpose of description specific embodiment in term used in this application, and is not intended to be limiting the application.
It is also intended in the application and " one kind " of singulative used in the attached claims, " described " and "the" including majority
Form, unless context clearly shows that other meanings.It is also understood that term "and/or" used herein refers to and wraps
Containing one or more associated list items purposes, any or all may be combined.
It will be appreciated that though various information, but this may be described using term first, second, third, etc. in the application
A little information should not necessarily be limited by these terms.These terms are only used for same type of information being distinguished from each other out.For example, it is not departing from
In the case of the application scope, the first information can also be referred to as the second information, and similarly, the second information can also be referred to as
One information.Depending on linguistic context, word as used in this " if " can be construed to " ... when " or " when ...
When " or " in response to determining ".
Single-track link table is a kind of data structure on basis, is made of several nodes, each node is by data field and refers to
Pin domain two parts composition.Wherein, for data field for storing data, pointer field is used to store the pointer of next node.
Physically, each node of single-track link table is in Coutinuous store state.Logically, each node of single-track link table
The access order of each node is determined based on pointer, single-track link table can be divided into using chained list and sky according to the service condition of node
Not busy chained list.
When causing the pointer in the pointer field of a certain node destroyed due to hardware or software issue, storage device will
The data in each node after the node can not be accessed, cause the interruption of single-track link table.
In order to improve the reliability of chained list, the technology of doubly linked list is proposed in the prior art.However, either unidirectional chain
The increase of table or doubly linked list all supporting nodes and delete operation.Since the node in doubly linked list is than the section in single-track link table
More one of point preserves the pointer for being directed toward previous node, and therefore, doubly linked list consumes memory more than single-track link table, meanwhile, double
Increase time that either deletion of node is consumed into chained list than increasing in single-track link table or when deletion of node is consumed
Between it is more.In higher equipment is required to process performance, doubly linked list is not suitable as the data storage knot of this kind equipment
Structure.
Embodiment one
In order to improve the reliability of single-track link table, the embodiment of the present application one shows the reparation side that a kind of single-track link table interrupts
Method, applied to storage device.Fig. 3 is referred to, Fig. 3 is the reparation side that a kind of single-track link table shown in the embodiment of the present application one interrupts
Method flow chart, specifically performs following steps:
Step 301:When the Loss Of Pointer in either objective node in single-track link table or mistake, the destination node is judged
Logically affiliated target chained list;
In the present embodiment, having applied in advance in storage device can be with the storage resource of Coutinuous store, and uses unidirectional
The mode of chained list is stored.
Wherein, by the way of storage resource is applied in advance, can to save Shen when increasing node in single-track link table
Please memory time and in deletion of node save recycling memory time, it is thus possible to improve increasing in single-track link table
Speed when node and deletion of node.
In practical application, generally according to whether data are stored in the data field in each node in single-track link table, in logic
On single-track link table is divided into using chained list and idle chained list.Above-mentioned increase node refers to that a node is removed from idle chained list to be increased
It adds to using chained list, above-mentioned deletion of node refers to the node is added to idle chained list after a node from using to delete in chained list
In.
Wherein, either deletion of node still adds node, and the physical storage locations of the node will not change, simply
The data field and pointer field of the node are operated.
For example, referring to Fig. 4, Fig. 4 is the physical storage structure of each node and use chained list, idle chained list in single-track link table
Compares figure.
As shown in figure 4, Use_head, Use_tail, Free_head, Free_tail are respectively the cephalomere using chained list
The head node and tail node of point, tail node and idle chained list, u1, u2, u3 are using the node in chained list, and f1, f2, f3 are sky
Between node in chained list.In the physical storage structure of single-track link table, the arrow direction between each node is represented under each node direction
The pointer of one node.
The processor of storage device, which saves, to be directed toward using the head node of chained list and the pointer of tail node and is directed toward idle
The head node of chained list and the pointer of tail node.Wherein, the equal data field of head node does not store data, and the pointer field of tail node is not deposited
Store up pointer.
As shown in figure 4, when needing to increase node to using chained list, generally according to the cephalomere of the idle chained list of direction of preservation
The pointer of point is directly targeted to the head node of idle chained list, then according to the needle locating preserved in the head node to next section
Point (i.e. f1 in Fig. 4), using the node as data memory node and added to after using the tail node of chained list.Chain will be used
The pointer of f1 is directed toward in addition in the pointer field of the protocercal tail node of table, and f1 becomes the new tail node using chained list, in idle chained list
The pointer of head node be also required to modify, become to be directed toward the pointer of f2, eventually become shown in Fig. 5 as a result, Fig. 5 is in list
The principle schematic of node is added into chained list.
In the present embodiment, storage device can be detected in single-track link table except the tail node for using chained list and idle chained list
Tail node beyond each node, determine whether the pointer in the pointer field of each node is lost or mistake.
Wherein, due to not storing pointer in tail node, the detection range of above-mentioned storage device does not include tail node.
Further, since the increase and deletion of single-track link table supporting node, therefore the physical storage locations where tail node can change.
When storage device detects the Loss Of Pointer or mistake of either objective node, storage device may determine that the mesh
The logically affiliated target chained list of node is marked, that is, judges the destination node for using the section of the node of chained list or idle chained list
Point.
Step 302:It is each node described in the destination node and the target chained list before destination node, described
Tail node in target chained list, logically each section in another chained list in the single-track link table in addition to the target chained list
It carries to identify the mark that node has been found in point;
In the present embodiment, after storage device determines destination node logically affiliated target chained list, storage device
It can directly be positioned to the head node according to the pointer of the head node of the direction target chained list of preservation, be begun stepping through from the head node
Node in the target chained list.
Storage device carries to identify in traversal when traveling through the node of the Target Link in the node traversed
The mark that node has been found until traversing the destination node, and carries the mark in the destination node.
In addition, storage device can also be directly positioned according to the pointer of the tail node of the direction target chained list of preservation to the tail
Node, and carry in the tail node mark and in single-track link table except another of the object chain off-balancesheet in logic
The mark is carried in each node in chained list.
Wherein, taken in each node in the above-mentioned another chained list in logic that the object chain off-balancesheet is removed in single-track link table
Process with the mark is:
It is directly positioned to the head node, from this according to the pointer of the head node of another chained list in logic of direction of preservation
Head node begins stepping through the chained list.Storage device carries the mark until traveling through complete strips in traversal in the node traversed
Chained list.
For example, refer to Fig. 6, Fig. 6 be shown in the embodiment of the present application one when single-track link table is interrupted in unidirectional chain
The schematic diagram of mark is carried in the node of table.
As shown in Figure 6, it is assumed that use the Loss Of Pointer in the node u1 in chained list, then node u1 and node u1 it
In preceding node (node use_head), node use_tail, idle chained list each node (node free_head, node f1,
Node f2, node f3, node free_tail) it carries to identify the mark (such as found) that node has been found.
Step 303:When finding the latter of the destination node in the target chained list based on default inquiry mode
After a node, the pointer for the latter node for being directed toward the destination node is repaired in the destination node;Wherein, the target
The latter node of node is the starting section when last time found based on the inquiry mode travels through the target chained list
Point.
In the present embodiment, each section when storage device in destination node and target chained list before the destination node
It is each in point, the tail node in the target chained list, another chained list in logic in single-track link table in addition to the target chained list
After carrying target label in node, storage device can be found last time based on default inquiry mode and travel through the target
Start node during chained list.
Fig. 7 is referred to, Fig. 7 is the latter section that destination node is searched in target chained list shown in the embodiment of the present application one
The flow chart of point.
Wherein, above-mentioned inquiry mode is:
A), array traversal mode is started based on from head node and travel through node in the single-track link table, judge current traversal
To node whether carry to identify the mark that node has been found, if so, step b) is performed, if not, performing step
c);
B), judge whether to have traveled through the node in single-track link table based on array traversal mode, if not, step a) is performed,
If so, perform step f);
C) mark, is carried in the node that traverses of array traversal mode is currently based on, and records and is currently based on number
The start node that the node that group traversal mode traverses is traveled through for logic-based traversal mode, performs step d);
D), logic traversal mode is started based on from present node and begin stepping through node in the single-track link table, judge to work as
Whether the node that preceding logic-based traversal mode traverses carries the mark, if so, step a) is performed, if not, performing
Step e);
E) mark, is carried in the node that traverses of logic traversal mode is currently based on, and performs step d);
F) the latter node of the node finally recorded for destination node described in the target chained list, is determined;Wherein, institute
State the start node when node finally recorded travels through the single-track link table for last time logic-based traversal mode.
Wherein, above-mentioned array traversal mode is traveled through for the order based on each node in physical store.Above-mentioned logic
Traversal mode is to be traveled through based on the pointer in each node.
For example, as shown in fig. 6, physics traversal first first, i.e., begin stepping through from the head node use_head of single-track link table, when
When traversing node u3, it can detect that node u3 does not carry found marks.
Logic traversal is proceeded by this time, i.e., found marks are carried in node u3, and record node u3.Then make
With in chained list traversal is proceeded by from node u3.Due to node u3 the latter node use_tail carry found mark, when time
Physics traversal is back to after going through to node use_tail, i.e., continues to travel through since node u3.
When traversing node u2, since node u2 does not carry found marks, logic traversal is proceeded by this time, that is, is existed
Found marks are carried in node u2, and record node u2.Then traversal is proceeded by from node u2 in chained list is used, due to
Node u3 and node use_tail carry found mark, be back to after node use_tail is traversed physics traversal, i.e., from
Node u2 starts to continue to travel through, and node after node f3 is traversed in single-track link table has all traveled through.Since node u2 is most
The node recorded afterwards, thus may determine that node u2 is the latter node of destination node.
It in the present embodiment, can be in the destination node when storage device finds the latter node of destination node
The middle pointer for repairing the latter node for being directed toward the destination node.For example, as shown in fig. 6, " node u1 is set up in node u1
The pointer of → node u2 ".
In conclusion in this application, when the Loss Of Pointer of either objective node in single-track link table or mistake, storage
Equipment can be in the logically affiliated target chained list of the destination node, the destination node before the destination node each section
It is each in another chained list in logic in point, the tail node of the target chained list, single-track link table in addition to the target chained list
It carries to identify the mark that node has been found in node.When storage device found based on default inquiry mode it is last
After start node (node is the latter node of destination node) when once traveling through the target chained list, in destination node
It is middle to repair the pointer for the latter node for being directed toward destination node, therefore can realize and the technology of doubly linked list is not used to improve chain
The reliability of table.
Embodiment two
Corresponding with the embodiment one for the restorative procedure that a kind of foregoing single-track link table interrupts, present invention also provides a kind of lists
The embodiment two of the prosthetic device interrupted to chained list.
The embodiment for the prosthetic device that a kind of single-track link table of the application interrupts can be applied on a storage device.Device is implemented
Example can be realized by software, can also be realized by way of hardware or software and hardware combining.Exemplified by implemented in software, as
Device on one logical meaning is by corresponding calculating in nonvolatile memory by the processor of storage device where it
Machine program instruction reads what operation in memory was formed.For hardware view, as shown in figure 8, showing for the embodiment of the present application two
A kind of hardware structure diagram of storage device where the prosthetic device that a kind of single-track link table gone out interrupts, except processing shown in Fig. 8
Outside device, memory, network interface and nonvolatile memory, the storage device in embodiment where device is generally according to this
The actual functional capability for the reparation that single-track link table interrupts can also include other hardware, this is repeated no more.
Fig. 9 is referred to, Fig. 9 is the prosthetic device that a kind of single-track link table shown in the embodiment of the present application two interrupts, and is applied to
Storage device, logically, the single-track link table are divided into using chained list and idle chained list, physically, in the single-track link table
Each node Coutinuous store, described device include:Judging unit 910 carries unit 920, repairs unit 930.
The judging unit 910, for when the Loss Of Pointer in either objective node in single-track link table or mistake when, judge
The logically affiliated target chained list of the destination node;
Unit 920 is carried, for each before the destination node described in the destination node and the target chained list
Node, the logically tail node in the target chained list, another chain in the single-track link table in addition to the target chained list
It carries to identify the mark that node has been found in each node in table;
Unit 930 is repaired, the target section is found in the target chained list based on default inquiry mode for working as
After the latter node of point, the pointer of the latter node for being directed toward the destination node is repaired in the destination node wherein,
When the latter node of the destination node is that the last time found based on the inquiry mode travels through the target chained list
Start node.
Wherein, each node includes the data field for storing data and for storing in logic in the single-track link table
The pointer field of the pointer of next node is directed toward, the judging unit 910 is specifically used for:
Judge whether the data field of the destination node has stored data;
If so, the logically affiliated target chained list of the destination node is determined to use chained list;
If not, determine that the logically affiliated target chained list of the destination node is idle chained list.
In the present embodiment, described device further includes:
Query unit is used for:
A), array traversal mode is started based on from head node and travel through node in the single-track link table, judge current traversal
To node whether carry to identify the mark that node has been found, if so, step b) is performed, if not, performing step
c);
B), judge whether to have traveled through the node in single-track link table based on array traversal mode, if not, step a) is performed,
If so, perform step f);
C) mark, is carried in the node that traverses of array traversal mode is currently based on, and records and is currently based on number
The start node that the node that group traversal mode traverses is traveled through for logic-based traversal mode, performs step d);
D), logic traversal mode is started based on from present node and begin stepping through node in the single-track link table, judge to work as
Whether the node that preceding logic-based traversal mode traverses carries the mark, if so, step a) is performed, if not, performing
Step e);
E) mark, is carried in the node that traverses of logic traversal mode is currently based on, and performs step d);
F) the latter node of the node finally recorded for destination node described in the target chained list, is determined;Wherein, institute
State the start node when node finally recorded travels through the single-track link table for last time logic-based traversal mode.
Detection unit, for detecting in the single-track link table except the tail node and the tail node of idle chained list that use chained list
Outside each node, it is determined whether lose pointer or pointer error.
The function of unit and the realization process of effect specifically refer to and step are corresponded in the above method in above device
Realization process, details are not described herein.
For device embodiment, since it corresponds essentially to embodiment of the method, so related part is real referring to method
Apply the part explanation of example.The apparatus embodiments described above are merely exemplary, wherein described be used as separating component
The unit of explanation may or may not be physically separate, and the component shown as unit can be or can also
It is not physical location, you can be located at a place or can also be distributed in multiple network element.It can be according to reality
It needs that some or all of module therein is selected to realize the purpose of application scheme.Those of ordinary skill in the art are not paying
In the case of going out creative work, you can to understand and implement.
The foregoing is merely the preferred embodiment of the application, not limiting the application, all essences in the application
God and any modification, equivalent substitution, improvement and etc. within principle, done, should be included within the scope of the application protection.
Claims (8)
1. the restorative procedure that a kind of single-track link table interrupts, applied to storage device, logically, the single-track link table is divided into use
Chained list and idle chained list, physically, each node Coutinuous store in the single-track link table, which is characterized in that including:
When the Loss Of Pointer in either objective node in single-track link table or mistake, judge that the destination node is logically affiliated
Target chained list;
In each node, the target chained list described in the destination node and the target chained list before destination node
Tail node is logically carried in each node in another chained list in the single-track link table in addition to the target chained list and is used for
The mark that mark node has been found;
After the latter node of the destination node is found in the target chained list based on default inquiry mode, in institute
State the pointer that the latter node for being directed toward the destination node is repaired in destination node;Wherein, the latter of the destination node
Node is the start node when last time found based on the inquiry mode travels through the target chained list.
2. according to the method described in claim 1, it is characterized in that, each node includes storing data in the single-track link table
Data field and for store in logic be directed toward next node pointer pointer field;
The target chained list for judging that the destination node is logically affiliated, including:
Judge whether the data field of the destination node has stored data;
If so, the logically affiliated target chained list of the destination node is determined to use chained list;
If not, determine that the logically affiliated target chained list of the destination node is idle chained list.
3. according to the method described in claim 1, it is characterized in that, the inquiry mode is:
A), array traversal mode is started based on from head node and travel through node in the single-track link table, judge what is currently traversed
Whether node carries to identify the mark that node has been found, if so, step b) is performed, if not, performing step c);
B), judge whether to have traveled through the node in single-track link table based on array traversal mode, if not, step a) is performed, if
It is to perform step f);
C) mark, is carried in the node that traverses of array traversal mode is currently based on, and records and is currently based on array time
The start node that the node that the mode of going through traverses is traveled through for logic-based traversal mode, performs step d);
D), logic traversal mode is started based on from present node and begin stepping through node in the single-track link table, judge current base
The mark whether is carried in the node that logic traversal mode traverses, if so, step a) is performed, if not, performing step
e);
E) mark, is carried in the node that traverses of logic traversal mode is currently based on, and performs step d);
F) the latter node of the node finally recorded for destination node described in the target chained list, is determined;Wherein, it is described most
The node recorded afterwards travels through start node when mode travels through the single-track link table for last time logic-based.
4. according to the method described in claim 1, it is characterized in that, the method further includes:
Each node in addition to the tail node and the tail node of idle chained list that use chained list in the single-track link table is detected, is determined
Whether pointer or pointer error are lost.
5. the prosthetic device that a kind of single-track link table interrupts, applied to storage device, logically, the single-track link table is divided into use
Chained list and idle chained list, physically, each node Coutinuous store in the single-track link table, which is characterized in that including:
Judging unit, for when the Loss Of Pointer in either objective node in single-track link table or mistake when, judge the target section
The logically affiliated target chained list of point;
Carry unit, for before the destination node described in the destination node and the target chained list each node, institute
It states each in another chained list in tail node in target chained list, the logically single-track link table in addition to the target chained list
It carries to identify the mark that node has been found in node;
Unit is repaired, the latter of the destination node is found in the target chained list based on default inquiry mode for working as
After a node, the pointer for the latter node for being directed toward the destination node is repaired in the destination node;Wherein, the target
The latter node of node is the starting section when last time found based on the inquiry mode travels through the target chained list
Point.
6. device according to claim 5, which is characterized in that each node includes storing data in the single-track link table
Data field and for store in logic be directed toward next node pointer pointer field, including:
The judging unit is specifically used for:
Judge whether the data field of the destination node has stored data;
If so, the logically affiliated target chained list of the destination node is determined to use chained list;
If not, determine that the logically affiliated target chained list of the destination node is idle chained list.
7. the apparatus according to claim 1, which is characterized in that described device further includes:
Query unit is used for:
A), array traversal mode is started based on from head node and travel through node in the single-track link table, judge what is currently traversed
Whether node carries to identify the mark that node has been found, if so, step b) is performed, if not, performing step c);
B), judge whether to have traveled through the node in single-track link table based on array traversal mode, if not, step a) is performed, if
It is to perform step f);
C) mark, is carried in the node that traverses of array traversal mode is currently based on, and records and is currently based on array time
The start node that the node that the mode of going through traverses is traveled through for logic-based traversal mode, performs step d);
D), logic traversal mode is started based on from present node and begin stepping through node in the single-track link table, judge current base
The mark whether is carried in the node that logic traversal mode traverses, if so, step a) is performed, if not, performing step
e);
E) mark, is carried in the node that traverses of logic traversal mode is currently based on, and performs step d);
F) the latter node of the node finally recorded for destination node described in the target chained list, is determined;Wherein, it is described most
The node recorded afterwards travels through start node when mode travels through the single-track link table for last time logic-based.
8. device according to claim 5, which is characterized in that described device further includes:
Detection unit, for detecting in the single-track link table in addition to the tail node and the tail node of idle chained list that use chained list
Each node, it is determined whether lose pointer or pointer error.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711440304.XA CN108052411B (en) | 2017-12-27 | 2017-12-27 | Method and device for repairing one-way linked list interruption |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711440304.XA CN108052411B (en) | 2017-12-27 | 2017-12-27 | Method and device for repairing one-way linked list interruption |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108052411A true CN108052411A (en) | 2018-05-18 |
CN108052411B CN108052411B (en) | 2020-12-29 |
Family
ID=62128237
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201711440304.XA Active CN108052411B (en) | 2017-12-27 | 2017-12-27 | Method and device for repairing one-way linked list interruption |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108052411B (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110838333A (en) * | 2018-08-17 | 2020-02-25 | 成都华为技术有限公司 | Hash table repairing method and device |
Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110016284A1 (en) * | 2009-07-16 | 2011-01-20 | Shreeharsha Balan | Memory Management in Network Processors |
US20120011166A1 (en) * | 2009-06-18 | 2012-01-12 | Canon Kabushiki Kaisha | Skip list generation |
US8745741B1 (en) * | 2012-08-31 | 2014-06-03 | Google Inc. | Detecting and handling vtable pointer corruption |
CN104182291A (en) * | 2013-05-28 | 2014-12-03 | 上海博达数据通信有限公司 | Method for recovering destroyed idle memory linked list |
CN104239564A (en) * | 2014-09-28 | 2014-12-24 | 深圳市锐明视讯技术有限公司 | Method and device for organizing and repairing indexes of files |
CN104572432A (en) * | 2013-10-24 | 2015-04-29 | 杭州迪普科技有限公司 | Lock-free linked list management device |
CN104598194A (en) * | 2014-12-09 | 2015-05-06 | 中国航空工业集团公司第六三一研究所 | Initializing method and circuit of head and tail pointer chain table storage |
CN106295260A (en) * | 2016-08-05 | 2017-01-04 | 武汉斗鱼网络科技有限公司 | The hidden method of a kind of application program nucleus module and system |
CN106656865A (en) * | 2016-10-28 | 2017-05-10 | 杭州迪普科技股份有限公司 | Method and system for managing linked list resource |
-
2017
- 2017-12-27 CN CN201711440304.XA patent/CN108052411B/en active Active
Patent Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20120011166A1 (en) * | 2009-06-18 | 2012-01-12 | Canon Kabushiki Kaisha | Skip list generation |
US20110016284A1 (en) * | 2009-07-16 | 2011-01-20 | Shreeharsha Balan | Memory Management in Network Processors |
US8745741B1 (en) * | 2012-08-31 | 2014-06-03 | Google Inc. | Detecting and handling vtable pointer corruption |
CN104182291A (en) * | 2013-05-28 | 2014-12-03 | 上海博达数据通信有限公司 | Method for recovering destroyed idle memory linked list |
CN104572432A (en) * | 2013-10-24 | 2015-04-29 | 杭州迪普科技有限公司 | Lock-free linked list management device |
CN104239564A (en) * | 2014-09-28 | 2014-12-24 | 深圳市锐明视讯技术有限公司 | Method and device for organizing and repairing indexes of files |
CN104598194A (en) * | 2014-12-09 | 2015-05-06 | 中国航空工业集团公司第六三一研究所 | Initializing method and circuit of head and tail pointer chain table storage |
CN106295260A (en) * | 2016-08-05 | 2017-01-04 | 武汉斗鱼网络科技有限公司 | The hidden method of a kind of application program nucleus module and system |
CN106656865A (en) * | 2016-10-28 | 2017-05-10 | 杭州迪普科技股份有限公司 | Method and system for managing linked list resource |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110838333A (en) * | 2018-08-17 | 2020-02-25 | 成都华为技术有限公司 | Hash table repairing method and device |
Also Published As
Publication number | Publication date |
---|---|
CN108052411B (en) | 2020-12-29 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7533230B2 (en) | Transparent migration of files among various types of storage volumes based on file access properties | |
CN105242871B (en) | A kind of method for writing data and device | |
KR940005786B1 (en) | Personal computer operation method | |
CN104156380B (en) | A kind of distributed memory hash indexing method and system | |
CN107193871B (en) | Database recovering method and device | |
WO2019047480A1 (en) | Program update method, computer-readable storage medium, terminal device and apparatus | |
CN106227794A (en) | The storage method and apparatus of dynamic attribute data in temporal diagram data | |
CN110741354A (en) | Presenting differences between code entity invocations | |
JPH04225431A (en) | Method for compiling computer instruction for increasing instruction-cache efficiency | |
JP6156517B2 (en) | Write information storage device, method, and program | |
CN106910528A (en) | A kind of optimization method and device of solid state hard disc data routing inspection | |
CN104461384B (en) | A kind of method for writing data and storage device | |
US20200174910A1 (en) | Indexing and searching a time-travel trace for arbitrary length/arbitrary alignment values | |
JP2008269503A5 (en) | ||
JP4825719B2 (en) | Fast file attribute search | |
US7319653B2 (en) | Methods for recording data to optical media | |
CN114924923A (en) | Method, system, equipment and medium for verifying correctness of hard disk write-in point | |
CN108052411A (en) | The restorative procedure and device that a kind of single-track link table interrupts | |
JP4177833B2 (en) | Method and apparatus for multi-process access to linked list | |
US6496877B1 (en) | Method and apparatus for scheduling data accesses for random access storage devices with shortest access chain scheduling algorithm | |
CN108984421A (en) | A kind of information cuing method and device | |
CN103246718A (en) | Method, device and equipment for accessing files | |
JP2006500653A (en) | Method and apparatus for detecting errors when writing to persistent memory | |
CN106991116A (en) | The optimization method and device of database executive plan | |
CN109918074B (en) | Compiling link optimization method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |