CN107562640B - Information processing method, solid state disk and electronic equipment - Google Patents

Information processing method, solid state disk and electronic equipment Download PDF

Info

Publication number
CN107562640B
CN107562640B CN201610514444.6A CN201610514444A CN107562640B CN 107562640 B CN107562640 B CN 107562640B CN 201610514444 A CN201610514444 A CN 201610514444A CN 107562640 B CN107562640 B CN 107562640B
Authority
CN
China
Prior art keywords
block
combination
effective
determining
blocks
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.)
Active
Application number
CN201610514444.6A
Other languages
Chinese (zh)
Other versions
CN107562640A (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.)
Lenovo Beijing Ltd
Original Assignee
Lenovo Beijing 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 Lenovo Beijing Ltd filed Critical Lenovo Beijing Ltd
Priority to CN201610514444.6A priority Critical patent/CN107562640B/en
Publication of CN107562640A publication Critical patent/CN107562640A/en
Application granted granted Critical
Publication of CN107562640B publication Critical patent/CN107562640B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Techniques For Improving Reliability Of Storages (AREA)
  • Read Only Memory (AREA)

Abstract

The invention discloses an information processing method, a solid state disk and electronic equipment, wherein the method comprises the following steps: determining M storage blocks included in a first storage area in the solid state disk, wherein M is an integer greater than 1; dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1; when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer; determining a current read-write mode corresponding to the S block combinations; and performing read-write operation on the S block combinations based on the current read-write mode. The method is used for solving the technical problem that the data access performance of the SSD is poor in the prior art, and the technical effect of improving the data access performance of the SSD is achieved.

Description

Information processing method, solid state disk and electronic equipment
Technical Field
The present invention relates to the field of electronic technologies, and in particular, to an information processing method, a solid state disk, and an electronic device.
Background
The SSD (Solid State Disk) is a permanent memory, and has the advantages of fast read and write, light weight, low energy consumption, and small size, which are not possessed by the conventional mechanical hard Disk, so the SSD is widely used in the market.
In NAND Flash, in order to implement parallel read and write of multiple planes and improve the access performance of SSD, there are often multiple planes under the same die, and different planes can be accessed as one large block at the same time. If a bad block appears, other good blocks on the same plane will be selected for replacement. When more bad blocks appear on the same plane, the actual available capacity will decrease. Where die denotes a memory area and plane denotes a column area. Specifically, take the case of four planes under a die, and only 16 blocks under a die (actually much more than this value) as an example (see fig. 1), where if the 6, 10 numbered blocks of plane2 are broken and the 12 numbered blocks of plane0 are broken, as many as possible, the 4 planes are accessed in parallel. In actual use, the actually available valid parallel read-write blocks may be large blocks composed of four blocks with the numbers 0, 1, 2, and 3, or large blocks composed of four blocks with the numbers 4, 5, 14, and 7, that is, only 8 valid blocks of sixteen blocks are used in the whole die, where the available capacity of the other 5 valid blocks cannot be used for reading and writing except for 3 bad blocks.
Therefore, the prior art has the technical problem of poor data access performance of the SSD.
Disclosure of Invention
The embodiment of the invention provides an information processing method, a solid state disk and electronic equipment, which are used for solving the technical problem of poor data access performance of an SSD in the prior art and achieving the technical effect of improving the data access performance of the SSD.
In one aspect, an embodiment of the present application provides an information processing method, including:
determining M storage blocks included in a first storage area in the solid state disk, wherein M is an integer greater than 1;
dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1;
when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer;
determining a current read-write mode corresponding to the S block combinations;
and performing read-write operation on the S block combinations based on the current read-write mode.
Optionally, the method further comprises:
determining that a first block combination meeting a first preset condition exists in the N block combinations;
when the bad block appears in the first block combination, determining the column position of the bad block in the first storage area;
determining effective blocks which are positioned at the column positions and meet a second preset condition;
controlling the valid block to replace the bad block;
the S block combinations after the recombination are obtained.
Optionally, the determining the valid block in the column position and meeting the second preset condition specifically includes:
determining a first effective block set located at the column position, wherein the first effective block set comprises at least two effective blocks;
removing the middle block in the middle position of block combination from the first effective block set to obtain a second effective block set;
determining the valid block from the second set of valid blocks.
Optionally, after the determining the first valid block set located at the column position, the method further includes:
removing the first effective block set from which the read-write times are greater than the preset read-write times to obtain a third effective block set;
determining the valid block from the third set of valid blocks.
Optionally, after the determining the first valid block set located at the column position, the method further includes:
determining a block combination where each effective block in the first effective block set is located;
and determining the effective blocks from the first effective block set according to the sequence selected by block combination.
Optionally, after the determining the first valid block set located at the column position, the method further includes:
and determining the effective blocks with the reading and writing times similar to those of the bad blocks from the first effective block set.
Optionally, after the removing, from the first valid block set, the middle block located in the middle of the block combination to obtain a second valid block set, the method further includes:
removing the second effective block set from which the read-write times are larger than the preset read-write times to obtain a fourth effective block set;
determining a block combination where each effective block in the fourth effective block set is located;
determining a fifth effective block set from the fourth effective block set according to the sequence selected by block combination;
and determining the effective blocks with the reading and writing times similar to those of the bad blocks from the fifth effective block set.
Optionally, the method further comprises:
when the effective block meeting the second preset condition does not exist, performing degradation processing on the first block combination, adjusting the first block combination to a second block combination different from the first block combination, and obtaining the adjusted S block combinations including the second block combination; alternatively, the first and second electrodes may be,
and when the bad block appears in other block combinations except the first block combination in the N block combinations, performing degradation processing on the other block combinations to obtain the adjusted S block combinations.
On the other hand, an embodiment of the present application further provides a solid state disk, including:
a housing;
a control unit disposed within the housing;
the flash memory unit is connected with the control unit and arranged in the shell;
wherein the control unit is configured to:
determining M storage blocks included in a first storage area in the solid state disk, wherein M is an integer greater than 1;
dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1;
when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer;
determining a current read-write mode corresponding to the S block combinations;
and performing read-write operation on the S block combinations based on the current read-write mode. On the other hand, an embodiment of the present application further provides an electronic device, including: the solid state disk comprises a first determining unit, a second determining unit and a control unit, wherein the first determining unit is used for determining M storage blocks included in a first storage area in the solid state disk, and M is an integer larger than 1;
the first dividing unit is used for dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1;
a first obtaining unit, configured to, when a bad block occurs in any block combination, recombine the N block combinations according to a second preset rule to obtain S block combinations after the recombination, where S is a positive integer;
a second determining unit, configured to determine a current read-write mode corresponding to the S block combinations;
and the first processing unit is used for performing read-write operation on the S block combinations based on the current read-write mode.
One or more technical solutions in the embodiments of the present application have at least one or more of the following technical effects:
in the technical scheme of the embodiment of the application, M storage blocks included in a first storage area in the solid state disk are determined, wherein M is an integer greater than 1; dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1; when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer; determining a current read-write mode corresponding to the S block combinations; and performing read-write operation on the S block combinations based on the current read-write mode. That is to say, when a bad block occurs in any block combination of the N block combinations in the solid state disk, the N block combinations are recombined according to a second preset rule to obtain S block combinations after being recombined, and the solid state disk performs read-write operation on the S block combinations based on the read-write mode corresponding to the S block combinations after being recombined. Therefore, the technical problem that the data access performance of the SSD is poor in the prior art is solved, and the data access performance of the SSD is improved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings used in the description of the embodiments will be briefly introduced, and it is obvious that the drawings in the following description are only some embodiments of the present invention.
Fig. 1 is a schematic structural diagram of a memory area with four planes, 16 memory blocks and memory blocks numbered 6, 10 and 12 all being bad blocks;
fig. 2 is a flowchart of a method of processing information according to an embodiment of the present application;
fig. 3 is a flowchart of a method of step S102 in an information processing method according to an embodiment of the present application;
fig. 4 shows access patterns included in an a memory area having four row areas and four column areas in an information processing method according to an embodiment of the present application;
fig. 5a is a schematic structural diagram of an information processing method according to an embodiment of the present application after block combination is performed on 16 storage blocks in a B storage area having four rows and four columns;
fig. 5B is a schematic structural diagram of a corresponding method after recombining effective blocks in a B storage area when a storage block with four rows and four columns in a B storage area and the number 1 is changed into a bad block in an information processing method according to an embodiment of the present application;
fig. 6 is a flowchart of an information processing method according to an embodiment of the present application;
fig. 7 is a flowchart of a method of a first implementation manner of step S303 in an information processing method according to an embodiment of the present application;
fig. 8 is a flowchart of a method of a second implementation manner of step S303 in an information processing method according to an embodiment of the present application;
fig. 9 is a flowchart of a method of a third implementation manner of step S303 in an information processing method according to an embodiment of the present application;
fig. 10 is a flowchart of a method of a fifth implementation manner of step S303 in an information processing method according to an embodiment of the present application;
fig. 11 is a diagram of a recombined B storage area in an information processing method according to an embodiment of the present application;
fig. 12 is a schematic structural diagram of four access mode degradation processes corresponding to four block combinations in an information processing method according to an embodiment of the present application;
fig. 13 is a block diagram illustrating a structure of a solid state disk according to a second embodiment of the present application;
fig. 14 is a block diagram of an electronic device according to a third embodiment of the present application.
Detailed Description
The embodiment of the application provides an information processing method, a solid state disk and an electronic device, which are used for solving the technical problem that the data access performance of an SSD is poor in the prior art and achieving the technical effect of improving the data access performance of the SSD.
In order to solve the technical problems, the general idea of the embodiment of the present application is as follows:
determining M storage blocks included in a first storage area in the solid state disk, wherein M is an integer greater than 1;
dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1;
when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer;
determining a current read-write mode corresponding to the S block combinations;
and performing read-write operation on the S block combinations based on the current read-write mode.
In the technical scheme of the embodiment of the application, M storage blocks included in a first storage area in the solid state disk are determined, wherein M is an integer greater than 1; dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1; when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer; determining a current read-write mode corresponding to the S block combinations; and performing read-write operation on the S block combinations based on the current read-write mode. That is to say, when a bad block occurs in any block combination of the N block combinations in the solid state disk, the N block combinations are recombined according to a second preset rule to obtain S block combinations after being recombined, and the solid state disk performs read-write operation on the S block combinations based on the read-write mode corresponding to the S block combinations after being recombined. Therefore, the technical problem that the data access performance of the SSD is poor in the prior art is solved, and the data access performance of the SSD is improved.
In order to better understand the technical solutions, the technical solutions of the present invention are described in detail below with reference to the drawings and specific embodiments, and it should be understood that the specific features in the embodiments and examples of the present invention are detailed descriptions of the technical solutions of the present invention, and are not limitations of the technical solutions of the present invention, and the technical features in the embodiments and examples of the present invention may be combined with each other without conflict.
In the embodiment provided based on the technical scheme of the application, the solid state disk is a hard disk manufactured by using a solid state electronic storage chip array, and mainly comprises a main control chip and a flash memory chip. The flash memory chips are further classified into SLC (Single-Level Cell, i.e., 1bit/Cell) flash memory chips, MLC (Multi-Level Cell, i.e., double-Level Cell, 2bit/Cell) flash memory chips, TLC (Trinary-Level Cell, i.e., triple-Level Cell, 3bit/Cell) flash memory chips, and the like. Flash memory has a limitation on the number of times it must be erased before writing, however, flash memory has a limitation on the number of times it is programmed and erased, so that each program/erase cycle is called a 1P/E (program/erase cycles) cycle. Generally, SLC can reach 10 million times of PE, MLC is 1 million times of PE generally, and TLC is 3000-5000 times of PE generally.
Example one
Referring to fig. 2, an embodiment of the present application provides an information processing method applied to a solid state disk, including:
s101: determining M storage blocks included in a first storage area in the solid state disk, wherein M is an integer greater than 1;
s102: dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1;
s103: when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer;
s104: determining a current read-write mode corresponding to the S block combinations;
s105: and performing read-write operation on the S block combinations based on the current read-write mode.
In the specific implementation process, the specific implementation process of step S101 to step S105 is as follows:
first, step S101 is performed: and determining M storage blocks included in a first storage area in the solid state disk, wherein M is an integer greater than 1. Specifically, the solid state disk may have a plurality of storage areas, and each storage area may include a plurality of storage blocks. For example, the storage area A comprises 16 storage blocks with serial numbers of 0-15. Then, according to a first preset rule, dividing the M storage blocks into N block combinations, where N is an integer greater than 1, and the storage blocks in each block combination can be accessed together by the SSD as one large block. For example, two memory blocks combined together as one large block are accessed simultaneously by the SSD; for another example, three memory blocks are combined together as a large block to be accessed by the SSD at the same time; as another example, four memory blocks are combined together as a large block to be accessed simultaneously by the SSD. In addition, when the storage block is a valid block or an available block, the storage block can be effectively accessed by the SSD, and when the storage block is a bad block, the data cannot be further stored, and thus cannot be effectively accessed by the SSD.
Then, step S102 is executed: and dividing the M storage blocks into N block combinations according to a first preset rule. In a specific implementation process, the M storage blocks may be divided into N block combinations according to different rules. Specifically, one implementation is shown in fig. 3, and step S102: dividing the M storage blocks into N block combinations according to a first preset rule, where N is an integer greater than 1, and specifically including:
s201: determining P column areas included under the first storage area, wherein P is an integer greater than 1, and each column area in the P column areas includes at least two storage blocks;
s202: determining P combination modes among the effective blocks based on the P column areas;
s203: and dividing the M effective blocks into the N block combinations based on the P combination modes.
In the specific implementation process, the specific implementation process of step S201 to step S203 is as follows:
first, P column areas included under the first storage area are determined. For example, it is determined that 4 column areas, numbered plane0, plane1, plane2, and plane3, are included under the a storage area. Then, based on these four column regions, it is determined that there are 4 combinations between the effective blocks. For example, the 4 combinations are a single column combination, two column combinations, three column combinations, and four column combinations in the same row area. For another example, when the a memory region includes 3 column regions including a plane0, a plane1, and a plane2, the effective blocks have 3 combination modes, which are a single column combination mode, two column combination modes, and three column combination modes in the same row region. In a specific implementation process, when the current block combination mode is a two-column combination mode, the read-write mode of the solid state disk to the current block combination mode is to simultaneously access two effective blocks in the two-column combination mode in parallel and continuously. In addition, when the current block combination mode is the four-column combination mode, the read-write mode of the solid state disk for the current block combination mode is to simultaneously access the four effective blocks in the four-column combination mode in parallel and continuously. For another example, when there are three column regions below the storage region, there are three combinations among the effective blocks, for example, the three combinations are a single column combination, two column combinations, and three column combinations in the same row region. And when the combination mode of the current block is a three-column combination mode, the read-write mode of the solid state disk for the combination mode of the current block is to simultaneously access three effective blocks in the three-column combination mode in parallel and continuously. Of course, those skilled in the art may design different column combination modes in the same row area according to the specific distribution of the following areas in the storage area, which is not described herein again.
In a specific implementation process, in order to fully utilize each effective block in the storage area, after the above several column combination modes are defined, each column combination mode corresponds to an access mode of the solid state disk to the column combination mode. Taking an a memory area a having four row areas and four column areas as an example, the access mode corresponding to the single column combination manner is a mode M1 for accessing a single column area, and specifically includes an M10 mode for accessing a column area with a plane0, an M11 mode for accessing a column area with a plane1, an M12 mode for accessing a column area with a plane2, and an M13 mode for accessing a column area with a plane 3. The access mode corresponding to the two column combination mode is a mode M2 of continuously accessing two column regions linked together, and specifically includes a mode M20 of continuously and simultaneously accessing a column region numbered plane0 and plane1, a mode M21 of continuously and simultaneously accessing a column region numbered plane1 and plane2, and a mode M22 of continuously and simultaneously accessing a column region numbered plane2 and plane 3. The access mode corresponding to the three-column combination mode is a mode M3 in which three column regions linked together are consecutively accessed, and specifically includes a M30 mode in which the column regions numbered plane0, plane1, and plane2 are consecutively and simultaneously accessed, and a M31 mode in which the column regions numbered plane1, plane2, and plane3 are consecutively and simultaneously accessed. The access mode corresponding to the four-column combination mode is a mode M4 in which four column regions linked together are consecutively accessed, specifically, an M40 mode in which column regions numbered plane0, plane1, plane2, and plane3 are consecutively and simultaneously accessed. As shown in fig. 4, specifically, the access pattern included in the memory area a having four row areas and four column areas, wherein the gray memory block is an effective block.
In this embodiment of the present application, after dividing the M storage blocks into N block combinations, step S103 is executed: and when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer. As a specific example, as shown in fig. 5a, before the re-combination, there are block combinations included in 16 storage blocks (where the 16 storage blocks respectively correspond to block numbers 0 to 15) under a B storage area having four rows and four columns, where the 16 storage blocks are divided according to the first preset rule, and the block combinations included after the division include a block combination a composed of storage blocks numbered 0, 1, 2, and 3, a block combination B composed of storage blocks numbered 7, a block combination c composed of storage blocks numbered 11, a block combination d composed of storage blocks numbered 13, 14, and 15, a block combination e composed of storage blocks numbered 4 and 5, a block combination f composed of storage blocks numbered 8 and 9, and the B storage area shown in fig. 5a includes six combinations a to f. When the memory block numbered 1 in the block combination becomes a bad block, the effective blocks under the B memory area are recombined and divided to obtain the block combination distribution situation shown in FIG. 5B. Specifically, the newly divided block combinations include a block combination a 'composed of storage blocks numbered 0, 5, 2, and 3, a block combination B' composed of storage blocks numbered 7, a block combination c 'composed of storage blocks numbered 11, a block combination d' composed of storage blocks numbered 13, 14, and 15, a block combination e 'composed of storage blocks numbered 4, and a block combination f' composed of storage blocks numbered 8 and 9, and in this case, the B storage area includes six block combinations a 'to f'. Of course, when a bad block occurs in different block combinations, the form of the block combination in the storage area may also be adjusted accordingly, which is not illustrated here.
In the embodiment of the present application, after obtaining the S block combinations after the recombination, step S104 is performed: and determining the current read-write mode corresponding to the S block combinations. Because each block combination is composed of different effective blocks, and the storage blocks included in the block combination are accessed simultaneously in the working process of the solid state disk, once the block combination is adjusted, the read-write mode of the block combination of the solid state disk is correspondingly adjusted. For example, before adjustment, the block combination a includes storage blocks with numbers of 0-3, and the corresponding read-write mode is that the solid state disk can simultaneously access the storage blocks with numbers of 0-3 in parallel. The adjusted block combination a' comprises storage blocks with numbers of 0, 5, 2 and 3, and the corresponding read-write mode is that the solid state disk can simultaneously access the storage blocks with numbers of 0, 5, 2 and 3 in parallel.
In this embodiment of the present application, after determining the current read-write mode corresponding to the S block combinations, step S105 is executed: and performing read-write operation on the S block combinations based on the current read-write mode. That is, after the current read-write mode corresponding to the S block combinations is determined, once the solid state disk is in a working state, corresponding read-write operations can be performed on each adjusted block combination based on the read-write mode. For example, when the current read-write mode is a read-write mode in which the solid state disk can simultaneously access the storage blocks numbered 0, 5, 2, and 3 in parallel, the solid state disk performs read-write operations on the storage blocks numbered 0, 5, 2, and 3 simultaneously.
In the embodiment of the present application, please refer to fig. 6, the method further includes:
s301: determining that a first block combination meeting a first preset condition exists in the N block combinations;
s302: when the bad block appears in the first block combination, determining the column position of the bad block in the first storage area;
s303: determining effective blocks which are positioned at the column positions and meet a second preset condition;
s304: controlling the valid block to replace the bad block;
s305: the S block combinations after the recombination are obtained.
In the specific implementation process, the specific implementation process of step S301 to step S305 is as follows:
first, it is determined that a first block combination meeting a first preset condition exists in the N block combinations. Still taking the B storage area including 16 storage blocks in four rows and four columns of fig. 5a as an example, since the more storage blocks in different column areas that the solid state disk can simultaneously access in parallel, the better the access performance of the solid state disk is. Specifically, for the B storage area, when the current block is combined into four valid blocks corresponding to the following four group combination modes in the same row area, the access performance of the solid state disk to the block combination is better than that of a block combination corresponding to a non-four group combination mode. For example, the block combination corresponding to the optimal access performance of the solid state disk in the B storage area is specifically a block combination a composed of storage blocks numbered 0, 1, 2, and 3.
Then, when the bad block occurs in the first block combination, the column position of the bad block in the first storage area is determined. Still taking fig. 5a as an example, when the memory block numbered 1 in the block combination a is a bad block, it is determined that the column position of the bad block in the B memory area is the column area corresponding to the plane 1.
Then, the effective blocks which are positioned at the column positions and meet the second preset condition are determined. For example, to improve the access performance of the solid state disk, the valid blocks meeting the second preset condition are found from other valid blocks (for example, valid storage blocks numbered 5, 9, and 13) located in the column area corresponding to the number plane 1. Further, the valid block is controlled to replace the bad block, for example, the bad block numbered 1 is replaced by the valid block numbered 9. Further, S block combinations after the recombination are obtained. In the specific implementation process, as long as a bad block appears in the block combination in the storage area, the bad block can be replaced by selecting other effective blocks, so that the dynamic adjustment of the block combination mode in the storage area is realized on one hand, and the access performance of the solid state disk is improved on the other hand.
In the embodiment of the present application, step S303: and determining the effective blocks which are located at the column positions and meet the second preset condition, wherein the following five implementation manners are provided specifically, but not limited to the following five implementation manners.
First implementation
A first implementation manner is a method for excluding the middle block, please refer to fig. 7, which specifically includes:
s401: determining a first effective block set located at the column position, wherein the first effective block set comprises at least two effective blocks;
s402: removing the middle block in the middle position of block combination from the first effective block set to obtain a second effective block set;
s403: determining the valid block from the second set of valid blocks.
In the specific implementation process, the specific implementation process of steps S401 to S403 is as follows:
first, a first set of valid blocks located at the column position is determined. Still taking fig. 5a as an example, when the memory block numbered 1 in the block combination a is a bad block, and the column position of the bad block in the B memory area is the column area corresponding to the plane1, the column area is the first valid block set composed of numbers 5, 9, and 13 except the bad block. Then, the intermediate blocks belonging to the current combination mode are excluded from the first effective block set. For example, when the access mode corresponding to the block combination in which the valid block that can be used to replace the bad block is located is M30 mode in fig. 4, and the bad block is located in the column region corresponding to the plane0, the valid block belongs to the middle block in the block combination correspondingly. Once the valid block serving as the intermediate block is selected to replace the bad block, the original block combination must be split into two block combinations, and the two access modes corresponding to the two block combinations are M10 and M11, respectively, so that the access performance of the solid state disk to the block combinations in the storage area is further greatly reduced. For another example, when the access mode corresponding to the block combination in which the valid block that can be used to replace the bad block is located is M31 mode in fig. 4, and the bad block is located in the column region corresponding to the plane2, correspondingly, the valid block belongs to the middle block in the block combination. Once the valid block serving as the intermediate block is selected to replace the bad block, the original block combination must be split into two block combinations, and the two access modes corresponding to the two block combinations are M11 and M13, respectively, so that the access performance of the solid state disk to the block combinations in the storage area is further greatly reduced. Therefore, in the implementation process, in order to improve the access performance of the solid state disk to the block combination, the intermediate blocks belonging to the current combination mode are excluded from the first effective block set located in the column position. Further, a second effective block set is obtained, the effective blocks are determined from the second effective block set, and then bad blocks are replaced.
Second implementation
The second implementation manner is specifically a method for excluding that the PE times are greater than the preset PE time threshold, please refer to fig. 8, which specifically includes:
s501: removing the first effective block set from which the read-write times are greater than the preset read-write times to obtain a third effective block set;
s502: determining the valid block from the third set of valid blocks.
In the specific implementation process, the specific implementation process of steps S501 to S502 is as follows:
specifically, whether the flash memory chip is an SLC flash memory chip, an MLC flash memory chip or a TLC flash memory chip, the flash memory chip has a certain erase/write life, and accordingly, the flash memory chip has a theoretical maximum PE frequency. When the PE times corresponding to the selected effective block are close to the PE time threshold, the effective block is indicated to be close to the service life, and if the effective block is selected to replace a bad block, the access performance of the solid state disk to the block combination in the storage area is reduced. Therefore, in a second implementation manner, the valid blocks with the read-write times greater than the preset read-write times are excluded from the first valid block set, so as to obtain a third valid block set, further determine valid blocks meeting conditions from the third valid block set, and further perform valid replacement on bad blocks. Because some effective blocks are removed from the qualified effective block set through the second implementation mode, the processing efficiency is ensured, and the access performance of the solid state disk to the block combination in the storage area is improved.
Third implementation
In the specific implementation process, after different access modes of the solid state disk for the block combinations are defined, the solid state disk has different access performances when accessing the different block combinations. Therefore, the third implementation manner may specifically be a method for selecting an appropriate replacement block according to the quality of the access performance corresponding to the access mode, please refer to fig. 9, which specifically includes:
s601: determining a block combination where each effective block in the first effective block set is located;
s602: and determining the effective blocks from the first effective block set according to the sequence selected by block combination.
In the specific implementation process, the specific implementation process of step S601 to step S602 is as follows:
firstly, determining the block combination where each effective block in the first effective block set is located. Still taking fig. 5a as an example, when the memory block numbered 1 in the block combination a is a bad block, it is determined that the column position of the bad block in the B memory area is the column area corresponding to the plane 1. The valid blocks under this column area include in particular the memory blocks numbered 5, 9, 13. The memory block numbered 5 corresponds to the block combination e, the memory block numbered 9 corresponds to the block combination f, and the memory block numbered 13 corresponds to the block combination d. And then determining the effective blocks from the first effective block set according to the sequence selected by block combination. The performance of the solid state disk for simultaneously accessing each effective block in the block combination is better when the effective blocks are more included in the block combination. Therefore, in the implementation process, when the storage block numbered 1 is a bad block, in order to ensure the access performance of the solid state disk to the maximum extent, the bad block is preferably replaced by an effective block in a block combination with a smaller number of effective blocks. For example, in the B storage area, an effective block located in the column area in the block combination of only 1 storage block is preferentially selected as the replacement block, an effective block located in the column area in the block combination split into 2 storage blocks is then selected as the replacement block, and an effective block located in the column area in the block combination split into 3 storage blocks is finally selected as the replacement block. Specifically, in this example, when the memory block numbered 1 is a bad block, the splitting block combination e is preferentially selected, and the bad block is replaced by the valid block numbered 5 in the block combination. Alternatively, split block combination f is selected and the bad block is replaced by the valid block numbered 9 in the block combination. Instead of choosing to split block combination d, the bad block is replaced by the valid block numbered 13 in its block combination.
Fourth mode of implementation
After determining the first valid block set located at the column position, when there are multiple valid blocks in the first valid block set, a fourth implementation manner may specifically be that the valid blocks whose read-write times are close to those of the bad blocks are determined from the first valid block set. Still taking fig. 5a as an example, when the memory block numbered 1 in the block combination a is a bad block, it is determined that the column position of the bad block in the B memory area is the column area corresponding to the plane 1. The valid blocks in the column area specifically include storage blocks numbered 5, 9, and 13, that is, the storage blocks numbered 5, 9, and 13 constitute a first valid block set. In a specific implementation process, in order to ensure that the service performance of the solid state disk is basically not affected after the bad block is replaced by the effective block selected from the first effective block set. Specifically, when the replacement block is used to replace the bad block, the effective block selected from the first effective block set should have a PE number similar to that of the bad block, so that when the replacement block is combined with other effective blocks in the block combination except the bad block, the performance of the solid state disk is better.
Fifth implementation
After the first effective block set located at the column position is determined, when a plurality of effective blocks exist in the first effective block set, in order to improve the accuracy of selecting the replacement blocks, the four implementation manners can be combined together to screen out effective blocks with better performance from the plurality of effective blocks. Specifically, referring to fig. 10, the fifth implementation specifically includes:
s701: removing the second effective block set from which the read-write times are larger than the preset read-write times to obtain a fourth effective block set;
s702: determining a block combination where each effective block in the fourth effective block set is located;
s703: determining a fifth effective block set from the fourth effective block set according to the sequence selected by block combination;
s704: and determining the effective blocks with the reading and writing times similar to those of the bad blocks from the fifth effective block set.
In the specific implementation process, the specific implementation process from step S701 to step S704 is as follows:
after the middle block in the middle position of block combination is removed from the first effective block set to obtain a second effective block set, firstly, the middle block with the reading and writing times larger than the preset reading and writing times is removed from the second effective block set to obtain a fourth effective block set. Still taking fig. 5a as an example, when the memory block numbered 1 in the block combination a is a bad block, it is determined that the column position of the bad block in the B memory area is the column area corresponding to the plane 1. The valid blocks in the column area specifically include storage blocks numbered 5, 9, and 13, that is, the storage blocks numbered 5, 9, and 13 constitute a first valid block set. It is assumed that the numbers of PEs corresponding to the memory blocks 1, 5, 9, and 13 are 1000, 980, 3100, and 1000, respectively. Since there are no intermediate blocks in the first set of valid blocks in fig. 5a, the second set of valid blocks comprises storage blocks numbered 5, 9, 13 in this example. Further, when the MLC flash memory cell is used, since its lifetime is 1 ten thousand PEs, the PE times of any valid block in the second valid block set does not exceed the preset PE threshold, and therefore, in this example, the fourth valid block set includes the memory blocks numbered 5, 9, and 13. Further, determining a block combination in which each valid block in the fourth valid block set is located, for example, a storage block with the number 5 corresponds to the block combination e, a storage block with the number 9 corresponds to the block combination f, and a storage block with the number 13 corresponds to the block combination d. And then, according to the sequence selected by the block combination, determining a fifth effective block set from the fourth effective block set. Specifically, in this example, when the memory block numbered 1 is a bad block, the splitting block combination e is preferentially selected, and the bad block is replaced by the valid block numbered 5 in the block combination. Alternatively, split block combination f is selected and the bad block is replaced by the valid block numbered 9 in the block combination. Therefore, in this example, according to the sequence of block combination, the fifth valid block set determined from the fourth valid block set includes valid blocks numbered 5 and 9. And then, determining the effective block with the reading and writing times similar to those of the bad block from the fifth effective block set. Specifically, in this example, since the number of PEs corresponding to the storage block with the number 5 is 980, which is closer to the number 1000 of PEs of the bad block, it is determined that the replacement block meeting the condition is specifically the storage block with the number 5, and then the storage area after the recombination is obtained, which is specifically shown in fig. 11.
Of course, for those skilled in the art, the above four implementation manners may be arbitrarily combined according to specific needs, where the fifth implementation manner is only one combination form of the first implementation manner to the fourth implementation manner. In addition, other implementations may be devised according to specific situations, which are not illustrated herein.
In the embodiment of the application, in order to sufficiently ensure the access performance of the solid state disk to the storage blocks in the block combination in the storage area. And when the effective block meeting the preset condition cannot be determined from the effective blocks after various implementation modes, performing degradation processing on the first block combination, adjusting the first block combination to a second block combination different from the first block combination, and obtaining the adjusted S block combinations comprising the second block combination. Still taking the storage area with four row areas and four column areas as an example, when a bad block occurs in the block combination corresponding to the mode M4, and after the above-mentioned several implementation manners, a suitable replacement block is still not found, at this time, the mode M4 may be degraded. For example, if a bad block occurs in the column region corresponding to the number 0 or 3, the mode M4 is degraded to the M31 mode or the M30 mode in the mode M3. If a bad block occurs in the column region corresponding to the number 1 or 2, the mode M4 is degraded to a mode M1 and a mode M2.
In addition, in the working process of the solid state disk, when bad blocks appear in other block combinations except the first block combination in the N block combinations, the other bad blocks are subjected to degradation processing, and the adjusted S block combinations are obtained. Still taking the storage area with four row areas and four column areas as an example, when a bad block occurs in the block combination corresponding to the mode M1, only one valid block corresponding to each of the four modes M10 to M13 included in the mode M1 is needed, and if the bad block is lost, the data needs to be removed, and a replacement block does not need to be found from the storage area to replace the bad block. When a bad block occurs in the corresponding block combination of the mode M2, each of the three modes M20 to M22 included in the mode M2 has two consecutive valid storage blocks, and if any one of the three modes is bad, the mode M2 can be degraded to be M1. When a bad block occurs in the block combination corresponding to the mode M3, each of the two modes M30 to M31 included in the mode M3 has three consecutive valid storage blocks, and if the bad storage block is not an intermediate block, the mode M2 is degraded. If the broken is the middle block, its corresponding block combination is split into two block combinations, which are respectively downgraded to mode M1. The specific degradation case is shown in fig. 12. Further, after obtaining the adjusted S block combinations, the solid state disk performs read-write operations on the S block combinations based on the read-write modes currently corresponding to the S block combinations. In addition, in the working process of the solid state disk, on one hand, when a bad block appears, the block combination can be adjusted in real time, and then the corresponding read-write mode is adjusted in real time. On the other hand, based on various access modes defined by the application, each effective block in the storage area is subjected to block combination, and when the effective blocks are fully utilized, once the solid state disk is used, the solid state disk can effectively read and write the block combination formed by the effective blocks, so that the access performance of the solid state disk is ensured, and the use performance of the solid state disk is greatly improved.
Example two
Based on the same inventive concept as the first embodiment of the present application, please refer to fig. 13, a second embodiment of the present application further provides a solid hard disk, including:
a housing 10;
a control unit 20 disposed inside the case 10;
a flash memory unit 30 connected to the control unit 20 and disposed in the housing 10;
wherein the control unit 20 is configured to:
determining M storage blocks included in a first storage area in the solid state disk, wherein M is an integer greater than 1;
dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1;
when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer;
determining a current read-write mode corresponding to the S block combinations;
and performing read-write operation on the S block combinations based on the current read-write mode.
In a specific implementation process, the solid state disk is a hard disk made of a solid state electronic memory chip array. The control unit 20 may be a main control chip. The flash memory unit 30 may be a flash memory chip. The flash memory chips are classified into SLC (Single-Level Cell, i.e., Single layer Cell, 1bit/Cell) flash memory chips, MLC (Multi-Level Cell, i.e., double layer Cell, 2bit/Cell) flash memory chips, TLC (Trinary-Level Cell, i.e., triple layer Cell, 3bit/Cell) flash memory chips, and the like.
In the embodiment of the present application, the control unit 20 is further specifically configured to:
determining that a first block combination meeting a first preset condition exists in the N block combinations;
when the bad block appears in the first block combination, determining the column position of the bad block in the first storage area;
determining effective blocks which are positioned at the column positions and meet a second preset condition;
controlling the valid block to replace the bad block;
the S block combinations after the recombination are obtained.
In the embodiment of the present application, the control unit 20 is further specifically configured to:
determining a first effective block set located at the column position, wherein the first effective block set comprises at least two effective blocks;
removing the middle block in the middle position of block combination from the first effective block set to obtain a second effective block set;
determining the valid block from the second set of valid blocks.
In this embodiment of the application, after determining the first valid block set located at the column position, the control unit 20 is further specifically configured to:
removing the first effective block set from which the read-write times are greater than the preset read-write times to obtain a third effective block set;
determining the valid block from the third set of valid blocks.
In this embodiment of the application, after determining the first valid block set located at the column position, the control unit 20 is further specifically configured to:
determining a block combination where each effective block in the first effective block set is located;
and determining the effective blocks from the first effective block set according to the sequence selected by block combination.
In this embodiment of the application, after determining the first valid block set located at the column position, the control unit 20 is further specifically configured to:
and determining the effective blocks with the reading and writing times similar to those of the bad blocks from the first effective block set.
In this embodiment of the present application, after the middle block located in the middle of the block combination is excluded from the first valid block set to obtain a second valid block set, the control unit 20 is further specifically configured to:
removing the second effective block set from which the read-write times are larger than the preset read-write times to obtain a fourth effective block set;
determining a block combination where each effective block in the fourth effective block set is located;
determining a fifth effective block set from the fourth effective block set according to the sequence selected by block combination;
and determining the effective blocks with the reading and writing times similar to those of the bad blocks from the fifth effective block set.
In the embodiment of the present application, the control unit 20 is further configured to:
when the effective block meeting the second preset condition does not exist, performing degradation processing on the first block combination, adjusting the first block combination to a second block combination different from the first block combination, and obtaining the adjusted S block combinations including the second block combination; alternatively, the first and second electrodes may be,
and when the bad block appears in other block combinations except the first block combination in the N block combinations, performing degradation processing on the other block combinations to obtain the adjusted S block combinations.
EXAMPLE III
Based on the same inventive concept as the first embodiment of the present application, please refer to fig. 14, a third embodiment of the present application further provides an electronic device, including:
a first determining unit 40, configured to determine M storage blocks included in a first storage area in the solid state disk, where M is an integer greater than 1;
a first dividing unit 50, configured to divide the M storage blocks into N block combinations according to a first preset rule, where N is an integer greater than 1;
a first obtaining unit 60, configured to, when a bad block occurs in any block combination, recombine the N block combinations according to a second preset rule to obtain S block combinations after the recombination, where S is a positive integer;
a second determining unit 70, configured to determine a current read-write mode corresponding to the S block combinations;
and a first processing unit 80, performing read-write operation on the S block combinations based on the current read-write mode.
In an embodiment of the present application, the electronic device further includes:
a third determining unit, configured to determine that a first block combination meeting a first preset condition exists in the N block combinations;
a fourth determining unit, configured to determine, when the bad block occurs in the first block combination, a column position of the bad block in the first storage area;
a fifth determining unit, configured to determine an effective block that meets a second preset condition and is located at the column position;
the first control unit is used for controlling the effective block to replace the bad block;
a second obtaining unit, configured to obtain the S block combinations after the recombination.
In this embodiment of the present application, the fifth determining unit specifically includes:
a first determining module, configured to determine a first valid block set located at the column position, where the first valid block set includes at least two valid blocks;
a first obtaining module, configured to exclude an intermediate block located in a middle position of a block combination from the first valid block set, and obtain a second valid block set;
a second determining module, configured to determine the valid block from the second valid block set.
In an embodiment of the present application, after the determining the first valid block set located at the column position, the electronic device further includes:
a second obtaining module, configured to exclude the number of times of reading and writing that is greater than a preset number of times of reading and writing from the first valid block set, and obtain a third valid block set;
a third determining module, configured to determine the valid block from the third valid block set.
In an embodiment of the present application, after the determining the first valid block set located at the column position, the electronic device further includes:
a fourth determining module, configured to determine a block combination in which each effective block in the first effective block set is located;
and a fifth determining module, configured to determine the valid block from the first valid block set according to a sequence selected by block combination.
In an embodiment of the present application, after the determining the first valid block set located at the column position, the electronic device further includes:
and a sixth determining module, configured to determine, from the first valid block set, the valid block whose read-write frequency is close to that of the bad block.
In this embodiment of the present application, after the removing, from the first valid block set, the middle block located in the middle of the block combination to obtain a second valid block set, the electronic device further includes:
a third obtaining module, configured to eliminate the second valid block set from which the read-write frequency is greater than a preset read-write frequency, and obtain a fourth valid block set;
a seventh determining module, configured to determine a block combination where each valid block in the fourth valid block set is located;
an eighth determining module, configured to determine a fifth effective block set from the fourth effective block set according to a sequence selected by block combination;
and a ninth determining module, configured to determine, from the fifth valid block set, the valid block whose read-write frequency is close to that of the bad block.
In an embodiment of the present application, the electronic device further includes:
a third obtaining unit, configured to, when there is no valid block that meets the second preset condition, perform degradation processing on the first block combination, adjust the first block combination to a second block combination different from the first block combination, and obtain the adjusted S block combinations including the second block combination; alternatively, the first and second electrodes may be,
a fourth obtaining unit, configured to, when the bad block occurs in another block combination of the N block combinations except the first block combination, perform degradation processing on the another block combination, and obtain the adjusted S block combination.
Through one or more technical solutions in the embodiments of the present application, one or more of the following technical effects can be achieved:
in the technical scheme of the embodiment of the application, M storage blocks included in a first storage area in the solid state disk are determined, wherein M is an integer greater than 1; dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1; when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer; determining a current read-write mode corresponding to the S block combinations; and performing read-write operation on the S block combinations based on the current read-write mode. That is to say, when a bad block occurs in any block combination of the N block combinations in the solid state disk, the N block combinations are recombined according to a second preset rule to obtain S block combinations after being recombined, and the solid state disk performs read-write operation on the S block combinations based on the read-write mode corresponding to the S block combinations after being recombined. Therefore, the technical problem that the data access performance of the SSD is poor in the prior art is solved, and the data access performance of the SSD is improved.
In the technical solution of the embodiment of the present application, when there is no valid block that meets the second preset condition, performing degradation processing on the first block combination, adjusting the first block combination to a second block combination different from the first block combination, and obtaining the adjusted S block combinations including the second block combination; or, when the first block combination meeting the first preset condition does not exist and the bad block appears in other block combinations except the first block combination in the N block combinations, performing degradation processing on the other block combinations to obtain the adjusted S block combinations. That is, when no available block replaces a bad block in a first block combination, the first block combination may be destaged; in addition, when the first block combination which meets the condition does not exist in the first storage area and a bad block appears in other block combinations, the block combination corresponding to the bad block can be subjected to degradation processing, so that S block combinations obtained after the original N block combinations are recombined are obtained. Further, the service performance of the solid state disk is improved.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
Specifically, the computer program instructions corresponding to the information processing method in the embodiment of the present application may be stored on a storage medium such as an optical disc, a hard disc, a usb disk, or the like, and when the computer program instructions corresponding to the information processing method in the storage medium are read or executed by an electronic device, the method includes the following steps:
determining M storage blocks included in a first storage area in the solid state disk, wherein M is an integer greater than 1;
dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1;
when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer;
determining a current read-write mode corresponding to the S block combinations;
and performing read-write operation on the S block combinations based on the current read-write mode.
Optionally, the computer instructions stored in the storage medium corresponding to the steps, when executed, the method further comprises:
determining that a first block combination meeting a first preset condition exists in the N block combinations;
when the bad block appears in the first block combination, determining the column position of the bad block in the first storage area;
determining effective blocks which are positioned at the column positions and meet a second preset condition;
controlling the valid block to replace the bad block;
the S block combinations after the recombination are obtained.
Optionally, the step stored in the storage medium, where the valid block that meets the second preset condition and is located at the column position is determined, when executed, the corresponding computer instruction specifically includes:
determining a first effective block set located at the column position, wherein the first effective block set comprises at least two effective blocks;
removing the middle block in the middle position of block combination from the first effective block set to obtain a second effective block set;
determining the valid block from the second set of valid blocks.
Optionally, the method further comprises, after determining the first set of valid blocks located at the column position, the step of storing in the storage medium corresponding computer instructions that, when executed, further comprise:
removing the first effective block set from which the read-write times are greater than the preset read-write times to obtain a third effective block set;
determining the valid block from the third set of valid blocks.
Optionally, the method further comprises, after determining the first set of valid blocks located at the column position, the step of storing in the storage medium corresponding computer instructions that, when executed, further comprise:
determining a block combination where each effective block in the first effective block set is located;
and determining the effective blocks from the first effective block set according to the sequence selected by block combination.
Optionally, the method further comprises, after determining the first set of valid blocks located at the column position, the step of storing in the storage medium corresponding computer instructions that, when executed, further comprise:
and determining the effective blocks with the reading and writing times similar to those of the bad blocks from the first effective block set.
Optionally, the computer instructions stored in the storage medium, when executed after excluding the middle block located in the middle of the block combination from the first valid block set to obtain a second valid block set, further include:
removing the second effective block set from which the read-write times are larger than the preset read-write times to obtain a fourth effective block set;
determining a block combination where each effective block in the fourth effective block set is located;
determining a fifth effective block set from the fourth effective block set according to the sequence selected by block combination;
and determining the effective blocks with the reading and writing times similar to those of the bad blocks from the fifth effective block set.
Optionally, the computer instructions stored in the storage medium corresponding to the steps, when executed, the method further comprises:
when the effective block meeting the second preset condition does not exist, performing degradation processing on the first block combination, adjusting the first block combination to a second block combination different from the first block combination, and obtaining the adjusted S block combinations including the second block combination; alternatively, the first and second electrodes may be,
and when the bad block appears in other block combinations except the first block combination in the N block combinations, performing degradation processing on the other block combinations to obtain the adjusted S block combinations. While preferred embodiments of the present invention have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all such alterations and modifications as fall within the scope of the invention.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (9)

1. An information processing method is applied to a solid state disk and comprises the following steps:
determining M storage blocks included in a first storage area in the solid state disk, wherein M is an integer greater than 1;
dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1;
when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer;
determining a current read-write mode corresponding to the S block combinations;
performing read-write operation on the S block combinations based on the current read-write mode;
the method further comprises the following steps:
determining that a first block combination meeting a first preset condition exists in the N block combinations;
when the bad block appears in the first block combination, determining the column position of the bad block in the first storage area;
determining effective blocks which are positioned at the column positions and meet a second preset condition;
controlling the valid block to replace the bad block;
obtaining the recombined S block combination;
and when the effective block meeting the second preset condition does not exist, performing degradation processing on the access mode corresponding to the first block combination, adjusting the first block combination to a second block combination different from the first block combination, and obtaining the adjusted S block combinations including the second block combination.
2. The method according to claim 1, wherein the determining the valid blocks located at the column positions and meeting the second preset condition specifically includes:
determining a first effective block set located at the column position, wherein the first effective block set comprises at least two effective blocks;
removing the middle block in the middle position of block combination from the first effective block set to obtain a second effective block set;
determining the valid block from the second set of valid blocks.
3. The method of claim 2, wherein after the determining the first set of valid blocks located at the column position, the method further comprises:
removing the first effective block set from which the read-write times are greater than the preset read-write times to obtain a third effective block set;
determining the valid block from the third set of valid blocks.
4. The method of claim 2, wherein after the determining the first set of valid blocks located at the column position, the method further comprises:
determining a block combination where each effective block in the first effective block set is located;
and determining the effective blocks from the first effective block set according to the sequence selected by block combination.
5. The method of claim 2, wherein after the determining the first set of valid blocks located at the column position, the method further comprises:
and determining the effective blocks with the reading and writing times similar to those of the bad blocks from the first effective block set.
6. The method of claim 2, wherein after said excluding from said first set of valid blocks intermediate blocks in a block combination, a second set of valid blocks, said method further comprises:
removing the second effective block set from which the read-write times are larger than the preset read-write times to obtain a fourth effective block set;
determining a block combination where each effective block in the fourth effective block set is located;
determining a fifth effective block set from the fourth effective block set according to the sequence selected by block combination;
and determining the effective blocks with the reading and writing times similar to those of the bad blocks from the fifth effective block set.
7. The method of claim 1, wherein the method further comprises:
and when the bad block appears in other block combinations except the first block combination in the N block combinations, performing degradation processing on the access modes corresponding to the other block combinations to obtain the adjusted S block combinations.
8. A solid state disk, comprising:
a housing;
a control unit disposed within the housing;
the flash memory unit is connected with the control unit and arranged in the shell;
wherein the control unit is configured to:
determining M storage blocks included in a first storage area in the solid state disk, wherein M is an integer greater than 1;
dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1;
when a bad block appears in any block combination, recombining the N block combinations according to a second preset rule to obtain S block combinations after recombination, wherein S is a positive integer;
determining a current read-write mode corresponding to the S block combinations;
performing read-write operation on the S block combinations based on the current read-write mode;
the control unit is further configured to:
determining that a first block combination meeting a first preset condition exists in the N block combinations;
when the bad block appears in the first block combination, determining the column position of the bad block in the first storage area;
determining effective blocks which are positioned at the column positions and meet a second preset condition;
controlling the valid block to replace the bad block;
obtaining the recombined S block combination;
and when the effective block meeting the second preset condition does not exist, performing degradation processing on the access mode corresponding to the first block combination, adjusting the first block combination to a second block combination different from the first block combination, and obtaining the adjusted S block combinations including the second block combination.
9. An electronic device, comprising:
the solid state disk comprises a first determining unit, a second determining unit and a control unit, wherein the first determining unit is used for determining M storage blocks included in a first storage area in the solid state disk, and M is an integer larger than 1;
the first dividing unit is used for dividing the M storage blocks into N block combinations according to a first preset rule, wherein N is an integer greater than 1;
a first obtaining unit, configured to, when a bad block occurs in any block combination, recombine the N block combinations according to a second preset rule to obtain S block combinations after the recombination, where S is a positive integer;
a second determining unit, configured to determine a current read-write mode corresponding to the S block combinations;
the first processing unit is used for performing read-write operation on the S block combinations based on the current read-write mode;
the electronic device further includes:
a third determining unit, configured to determine that a first block combination meeting a first preset condition exists in the N block combinations;
a fourth determining unit, configured to determine, when the bad block occurs in the first block combination, a column position of the bad block in the first storage area;
a fifth determining unit, configured to determine an effective block that meets a second preset condition and is located at the column position;
the first control unit is used for controlling the effective block to replace the bad block;
a second obtaining unit configured to obtain the S block combinations after the recombination;
and when the effective block meeting the second preset condition does not exist, performing degradation processing on the access mode corresponding to the first block combination, adjusting the first block combination to a second block combination different from the first block combination, and obtaining the adjusted S block combinations including the second block combination.
CN201610514444.6A 2016-06-30 2016-06-30 Information processing method, solid state disk and electronic equipment Active CN107562640B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610514444.6A CN107562640B (en) 2016-06-30 2016-06-30 Information processing method, solid state disk and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610514444.6A CN107562640B (en) 2016-06-30 2016-06-30 Information processing method, solid state disk and electronic equipment

Publications (2)

Publication Number Publication Date
CN107562640A CN107562640A (en) 2018-01-09
CN107562640B true CN107562640B (en) 2021-07-16

Family

ID=60968824

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610514444.6A Active CN107562640B (en) 2016-06-30 2016-06-30 Information processing method, solid state disk and electronic equipment

Country Status (1)

Country Link
CN (1) CN107562640B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108182960A (en) * 2018-01-12 2018-06-19 江苏华存电子科技有限公司 A kind of bad block management method for promoting storage device active volume
CN108469946B (en) * 2018-03-31 2021-04-20 深圳忆联信息系统有限公司 Chunking method and apparatus for improving SSD write-in efficiency
CN116991306A (en) * 2022-04-25 2023-11-03 深圳市江波龙电子股份有限公司 Processing method of storage device, storage device and computer readable storage device

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101499316A (en) * 2008-01-30 2009-08-05 群联电子股份有限公司 Flash memory block management method and controller employing the same
CN103106148A (en) * 2011-11-10 2013-05-15 群联电子股份有限公司 Block management method, storage controller and storage storing device

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101499316A (en) * 2008-01-30 2009-08-05 群联电子股份有限公司 Flash memory block management method and controller employing the same
CN103106148A (en) * 2011-11-10 2013-05-15 群联电子股份有限公司 Block management method, storage controller and storage storing device

Also Published As

Publication number Publication date
CN107562640A (en) 2018-01-09

Similar Documents

Publication Publication Date Title
US9734050B2 (en) Method and system for managing background operations in a multi-layer memory
US9465731B2 (en) Multi-layer non-volatile memory system having multiple partitions in a layer
US20140185376A1 (en) Method and system for asynchronous die operations in a non-volatile memory
US20140189206A1 (en) Method and system for managing block reclaim operations in a multi-layer memory
CN107562640B (en) Information processing method, solid state disk and electronic equipment
EP2939100A2 (en) Method and system for asynchronous die operations in a non-volatile memory
CN102880428A (en) Distributed RAID (redundant array of independent disks) establishing method and device
JP2010515179A (en) Flash memory block management method
US20120079170A1 (en) Method for performing block management, and associated memory device and controller thereof
US8683118B2 (en) Measure of health for writing to locations in flash
CN107562381A (en) A kind of data processing method and device
CN103370113A (en) Data storage method and data storage system
CN107025181A (en) Access the method for memory cell, distribute method, system and the Memory Controller of memory requests
CN111158579A (en) Solid state disk and data access method thereof
KR20170084194A (en) Memory wear leveling
WO2015030834A1 (en) Increased refresh interval and energy efficiency in a dram
CN104361907A (en) Counting method of FLASH memory
CN204332379U (en) The Memory Controller of nonvolatile memory and solid-state drive
EP3404662B1 (en) A method and system for implementing a non-volatile counter using non-volatile memory
CN108469946B (en) Chunking method and apparatus for improving SSD write-in efficiency
RU2640294C1 (en) Method of recording and recording apparatus for memory device
TWI781846B (en) Unbalanced plane management method, associated data storage device and controller thereof
CN110109621B (en) Method for improving performance and service life of solid state disk array system
WO2017218170A1 (en) Method and apparatus for programming wordlines of nand flash memory using alternating encoding schemes
JP4661566B2 (en) Access controller, flash memory system, and access control 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