Patent ID: 7412585
Filing Date: 2008-08-12
Classification: G06F

Abstract:
1. A method for controlling a disk drive including a storage medium; and a control unit that transmits/receives a command and data to/from a host to control write or read to or from the storage medium, said method comprising: receiving a write command from the host; reading out a logical block address included in the write command; when converting the read logical block address into a physical block address of the storage medium, converting the read logical block address into the next physical block address of a physical block address at which data has been written most recently so that data can be written to an unused area of the storage medium in an append manner; writing data specified by the host at the converted physical block address; writing a value of the logical block address specified by the host to a management area corresponding to the converted physical block address; storing as one entry the correspondence between the physical block address and the logical block address in an address translation table in a temporary storage area; comparing the number of entries stored in the address translation table with the allowable number of entries that is separately specified; as a result of the comparison, if the number of stored entries exceeds the allowable number of entries, selecting entries to be saved, the number of which is separately specified, from entries that are least recently used, in decreasing order of elapsed time after the last use; selecting the next physical block address of a physical block address at which a write has been made most recently; saving, to the storage medium, the address translation table in the temporary storage area by writing contents of the selected entries at the selected physical block address; writing a flag, indicating that written data is an entry of the address translation table, to a management area corresponding to the selected physical block address; saving a value of the selected physical block address in the temporary storage area; and when saving the address translation table on the storage medium, writing to the storage medium not only contents of the selected entries but also a value of a physical block address that was used when the address translation table stored in the temporary storage area has been saved on the storage medium last time.