US 11,704,240 B2
Garbage data scrubbing method, and device
Chao Yu, Shenzhen (CN); Hao Chen, Shenzhen (CN); Bifeng Tong, Shenzhen (CN); Chengliang Zheng, Shenzhen (CN); and Xiyu Zhou, Shanghai (CN)
Assigned to HUAWEI TECHNOLOGIES CO., LTD., Shenzhen (CN)
Filed by Huawei Technologies Co., Ltd., Shenzhen (CN)
Filed on Sep. 1, 2021, as Appl. No. 17/464,174.
Application 17/464,174 is a continuation of application No. 16/754,537, granted, now 11,126,546, previously published as PCT/CN2017/106200, filed on Oct. 13, 2017.
Claims priority of application No. 201710931551.3 (CN), filed on Oct. 9, 2017.
Prior Publication US 2022/0058118 A1, Feb. 24, 2022
This patent is subject to a terminal disclaimer.
Int. Cl. G06F 12/02 (2006.01); G06F 16/17 (2019.01); G06F 12/10 (2016.01)
CPC G06F 12/0253 (2013.01) [G06F 12/10 (2013.01); G06F 16/1727 (2019.01); G06F 2212/1044 (2013.01)] 17 Claims
OG exemplary drawing
 
1. A garbage data scrubbing method, implemented by a terminal comprising a storage device, wherein the garbage data scrubbing method comprises:
obtaining an input/output (IO) busy/idle status of the terminal at a current moment, wherein the IO busy/idle status comprises a busy state or an idle state;
delivering a discard message to the storage device when the IO busy/idle status is the idle state, wherein the discard message comprises an initial address and a size of to-be-scrubbed physical space in the storage device, and wherein the discard message instructs the storage device to unbind a mapping relationship between a physical address of the to-be-scrubbed physical space and a corresponding logical address;
obtaining a first busy/idle status of a block layer, a second busy/idle status of the storage device, a third busy/idle status of an application layer, and a probability that the IO busy/idle status is the busy state; and
determining the IO busy/idle status based on the first busy/idle status, the second busy/idle status, the third busy/idle status, and the probability.