US 12,367,136 B2
Method and non-transitory computer-readable storage medium and apparatus for executing host write commands
Shen-Ting Chiu, Miaoli County (TW)
Assigned to Silicon Motion, Inc., Zhubei (TW)
Filed by Silicon Motion, Inc., Zhubei (TW)
Filed on Oct. 24, 2023, as Appl. No. 18/383,063.
Claims priority of application No. 202211606841.8 (CN), filed on Dec. 14, 2022.
Prior Publication US 2024/0202112 A1, Jun. 20, 2024
This patent is subject to a terminal disclaimer.
Int. Cl. G06F 12/02 (2006.01)
CPC G06F 12/0246 (2013.01) 20 Claims
OG exemplary drawing
 
1. A method for executing host write commands, performed by a processing unit, comprising:
providing a sequential-write command queue (SCQ), a random-write command queue (RCQ) and a mark queue, wherein the SCQ stores a plurality of sequential write commands and the RCQ stores a plurality of random write commands;
receiving a host write command from a host side; and
pushing a record into the mark queue and pushing the host write command into the SCQ or the RCQ according to a length of a first logical address range carried in the host write command when detecting that the first logical address range carried in the host write command conflicts with a second logical address range carried in at least one sequential write command stored in the SCQ and/or a third logical address range carried in at least one random write command stored in the RCQ, wherein the record indicates that a conflicting sequential write command stored in the SCQ and/or a conflicting random write command stored in the RCQ needs to be processed earlier than the host write command,
thereby enabling user data of the second logical address range indicated by the conflicting sequential write command and/or of the third logical address range indicated by the conflicting random write command to be programmed into a flash module earlier than user data of the first logical address range indicated by the host write command.