IP Library › Granted Patent US 11,249,926
Granted Patent B1
US 11,249,926 · App. 17/011,432 · Granted Feb 15, 2022

Host state monitoring by a peripheral device

Inventors: JinKi Han (San Jose, CA); Jongman Yoon (San Jose, CA)
Assignee: PETAIO INC.
G06F13/1642G06F9/3857G06F13/1668G06F13/24G06F13/28
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,249,926
App. No.
17/011,432
Granted
Feb 15, 2022
Kind
B1
Abstract

A peripheral device implements a plurality of queue sets each including a submission queue and a completion queue. Changes to the queues are monitored and arbitration parameters are adjusted, the arbitration parameters defining how submission queues are selected for retrieval of a command. An arbitration burst for a submission queue may be increased in response to tail movement for the submission queue being larger than for another submission queue. Priorities used for weighted round robin arbitration may also be adjusted based on tail movement. Arbitration burst quantities and priorities of groups of queues may also be adjusted. Head movement of the completion queues is monitored and may be used to lower priority, enable interrupt coalescing, or pause command retrieval where head movement does not meet a threshold condition.

Claims (92)

1. A method comprising:

selecting a queue set from among a plurality of queue sets according to arbitration parameters, the plurality of queue sets including the queue set and another queue set;

removing a command from a corresponding submission queue of the queue set;

executing the command;

evaluating a change in depth of the submission queue over time including calculating a tail movement of the queue set;

determining that the tail movement is greater than another tail movement of the other queue set; and

in response to the change in depth and determined greater tail movement, altering the arbitration parameters including increasing a priority of the queue set relative to the other queue set.

2. The method of claim 1 , further comprising:

calculating tail movement of a tail of a corresponding submission queue for each queue set in the plurality of queue sets;

determining a longest tail movement of the tail movements of the plurality of queue sets;

for each queue set of the plurality of queue sets, calculating a distance ratio that is a ratio of the tail movement of the each queue set relative to the longest tail movement;

setting a burst quantity for each queue set of the plurality of queue sets as a function of the distance ratio;

selecting a further queue set from among the plurality of queue sets according to priorities of the plurality of queue sets; and

processing a group of commands from the submission queue of the further queue set in number equal to the burst quantity of the queue set.

3. The method of claim 1 , further comprising:

calculating tail movement of a tail of a corresponding submission queue for each queue set in the plurality of queue sets;

determining a longest tail movement of the tail movements of the plurality of queue sets;

for each queue set of the plurality of queue sets for which the tail movement thereof meets a first significance condition, calculating a distance ratio of the tail movement relative to the longest tail movement; and

setting a burst quantity for each queue set of the plurality of queue sets as a function of the distance ratio.

4. The method of claim 3 , further comprising:

selecting the queue set from among the plurality of queue sets according to the arbitration parameters; and

processing a number of commands from the submission queue of the queue set equal to the burst quantity of the queue set.

5. The method of claim 3 , further comprising:

defining a plurality of queue groups, each queue group including a subset of the plurality of queue sets; and

for each queue group of the plurality of queue groups:

aggregating tail movements of the tails of the corresponding submission queues of the subset of the plurality of queue sets to obtain an aggregate tail movement;

determining a longest aggregate tail movement of the aggregate tail movements of the plurality of queue groups;

for each queue group of the plurality of queue groups for which the aggregate tail movement thereof meet a second significance condition, calculating an aggregate distance ratio of the longest aggregate tail movement relative to the aggregate tail movement of the each queue group; and

setting an aggregate quantity for each queue group according to the aggregate distance ratio.

6. The method of claim 1 , further comprising, for each queue set of the plurality of queue sets:

monitoring a state of a head of the completion queue of the each queue set; and

when the state of the completion queue of the each queue set has a change over time lower than a first threshold condition, reducing priority of the each queue set in the arbitration parameters.

7. The method of claim 6 , further comprising when the state of the completion queue of the each queue set has a change over time lower than a second threshold condition that is lower than the first threshold condition, pausing command execution for the each queue set.

8. The method of claim 1 , further comprising:

generating interrupts to a host device;

removing results from completion queues of the plurality of queue sets in response to the interrupts and updating heads of the completion queues; and

performing for each queue set of the plurality of queue sets:

monitoring a state of the head of the completion queue of the each queue set; and

when the state of the completion queue of the each queue set has a change over time lower than a threshold condition, enabling interrupt coalescing for the each queue set such that interrupts are generated only when a number of results in the completion queue is above an aggregation threshold.

9. The method of claim 1 , further comprising:

removing a command from a submission queue in accordance with the altered arbitration parameters and a set burst quantity corresponding to the submission queue; and

executing the command.

10. A peripheral device comprising:

a processor; and

system memory coupled to the processor and storing instructions configured to cause the processor to:

select a queue set from among a plurality of queue sets according to arbitration parameters, the plurality of queue sets including the queue set and another queue set;

remove a command from a corresponding submission queue of the queue set;

execute the command;

evaluate a change in depth of the submission queue over time including calculating tail movement of the queue set;

determine the tail movement is greater than another tail movement of the other queue set; and

in response to the change in depth and determined greater tail movement, alter the arbitration parameters including increasing a priority of the queue set relative to the other queue set.

11. The peripheral device of claim 10 , further comprising instructions configured to:

calculate tail movement of a tail of a corresponding submission queue for each queue set in the plurality of queue sets;

determine a longest tail movement of the tail movements of the plurality of queue sets;

for each queue set of the plurality of queue sets for which the tail movement thereof meets a first significance condition, calculate a distance ratio that is a ratio of the tail movement of the each queue set relative to the longest tail movement;

set a burst quantity for each queue set of the plurality of queue sets as a function of the distance ratio;

select a further queue set from among the plurality of queue sets according to priorities of the plurality of queue sets; and

process groups of commands from the submission queue of the queue set in number equal to the burst quantity of the queue set.

12. The peripheral device of claim 10 , further comprising instructions configured to:

calculate tail movement of a tail of corresponding submission queue for each queue set in the plurality of queue sets;

determine a longest tail movement of the tail movements of the plurality of queue sets;

for each queue set of the plurality of queue sets for which the tail movement thereof meets a significance condition, calculate a distance ratio of the tail movement relative to the longest tail movement; and

set a burst quantity for each queue set of the plurality of queue sets as a function of the distance ratio.

13. The peripheral device of claim 12 , further comprising instructions configured to:

select the queue set from among the plurality of queue sets according to the arbitration parameters; and

process a number of commands from the submission queue of the queue set equal to the burst quantity of the queue set.

14. The peripheral device of claim 12 , further comprising instructions configured to:

define a plurality of queue groups, each queue group including a subset of the plurality of queue sets; and

for each queue group of the plurality of queue groups:

aggregate tail movements of the tails of the corresponding submission queues of the subset of the plurality of queue sets to obtain an aggregate tail movement;

determine a longest aggregate tail movement of the aggregate tail movements of the plurality of queue groups;

for each queue group of the plurality of queue groups for which the aggregate movement thereof meets a second significance condition, calculate an aggregate distance ratio of the longest aggregate tail movement relative to the aggregate tail movement of the each queue group; and

set an aggregate quantity for each queue group according to the aggregate distance ratio.

15. The peripheral device of claim 10 , further comprising instructions configured to:

monitor a state of a head of the completion queue of the each queue set; and

when the state of the completion queue of the each queue set has a change over time lower than a first threshold condition, reduce priority of the each queue set in the arbitration parameters.

16. The peripheral device of claim 15 , further comprising instructions configured to, when the state of the completion queue of the each queue set has a change over time lower than a second threshold condition that is lower than the first threshold condition, pausing command execution for the each queue set.

17. The peripheral device of claim 10 , further comprising instructions configured to:

generate interrupts to a host device; and

perform for each queue set of the plurality of queue sets:

monitoring a state of a head of the completion queue of the each queue set; and

when the state of the completion queue of the each queue set has a change over time lower than a threshold condition, enabling interrupt coalescing for the each queue set such that interrupts are generated only when a number of results in the completion queue is above an aggregation threshold.

18. A method comprising:

evaluating a change in depth of corresponding submission queues of a plurality of queue sets over time including calculating a tail movement for each of the plurality of queue sets;

determining the longest calculated tail movement from among the calculated tail movements;

for each of the plurality of queue sets having a calculated tail movement that meets a significance condition:

calculating a distance ratio of the calculated tail movement relative to the longest calculated tail movement; and

setting a burst quantity for the queue set as a function of the calculated distance ratio; and

altering arbitration parameters associated with the plurality of queue sets including changing a priority of at least one queue set in the plurality of queue sets based on the calculated tail movements.

19. The method of claim 18 , further comprising:

selecting a queue set from among the plurality of queue sets according to the altered arbitration parameters; and

processing a number of commands from the submission queue of the queue set in accordance with the corresponding burst quantity.

Assignments (2)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jul 14, 2025
From: PETAIO INC.
To: PETAIO MEMORY TECHNOLOGY (NANJING) CO., LTD.
Reel/Frame 071686/0234 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Nov 16, 2020
From: HAN, JINKI; YOON, JONGMAN
To: PETAIO INC.
Reel/Frame 054381/0451 →
Cited By (2)
US 12,326,808 US 12,657,138