OCP_2_5_Group_6
DSSD_25_Expected_Value_Of_NSID_Field_Of_DSSD_Power_State_Set_Feature_Test_Case.py
- This test case will verify the following:
Using NSID = 0 in the set features command passes as expected.
Using NSID = FFFFFFFFh in the set features command passes as expected.
Using NSID = NN+1 (invalid NSID) fails with Invalid Field in Command status.
NSID = any NSID between 1 and NN (valid NSID) fails with Feature Not Namespace Specific status.
Open Compute Project Datacenter NVMe SSD Spec v2.5 requirements referenced by this script:
SDSSDPS-6
DSSD_25_Idle_Power_Verification_Test_Case.py
- This script will run the following tests:
Loop over power states from 0 to NPSS
Verify IDLP multiplied by IPS = 5W
Set power state to the current power state in the loop and verify it was set correctly
Collect 30 idle power measurements at 1 second intervals
Compute average idle power of the measurements and verify it’s <= 5W + 5% margin
Repeat steps 2-5 for each operational power state
Pass/Fail: Script passes if all tests pass
Open Compute Project Datacenter NVMe SSD Spec v2.5 requirements referenced by this script:
PWR-1/6
DSSD_25_Maximum_Average_Power_Verification_Test_Case.py
- This script will run the following tests:
Precondition the namespace twice with 128KiB sequential writes and 4KiB Random Writes
Loop over power states from 0 to NPSS
Loop over the I/O Profile
Collect sample power consumption at a 2ms sampling rate
Compute average maximum power consumption
Verify it’s <= Maximum Power for the power state for any continuous 1s (250000 samples)
Repeat after step 3 with each I/O Profile
Repeat after step 2 with each power state
Pass/Fail: Script passes if all tests pass
Open Compute Project Datacenter NVMe SSD Spec v2.5 requirements referenced by this script:
PCM-1, PWR-1/3, FFM2-14
- execute_io_profile(dut, test_type, io_profile, io_runtime=-1, io_pattern=1)
- Executes each of the IO Profiles listed in Table 4
Sequential Read (MiB/s) (128kiB, QD = 128)
Sequential Write (MiB/s) (128kiB, QD = 128)
Random Read (KIOPS) (4kiB, QD = 128)
Random Writes (KIOPS) (4kiB, QD = 128)
Random 70R:30W mix (KIOPS) (4kiB, QD = 128)
- Parameters:
dut (XML_API) – Device object under test
test_type (str) – Either ‘Sequential’ | ‘Random’
io_profile (str) – IO Profile to be executed
io_runtime (int) – Time in seconds for IO to execute
io_pattern (int) – Pattern for io to be executed
- Return type:
dict
DSSD_25_Peak_Power_Verification_Test_Case.py
- This script will run the following tests:
Precondition the namespace twice with 128KiB sequential writes and 4KiB Random Writes
Loop over power states from 0 to NPSS
Loop over the I/O Profile
Collect sample power consumption at a 4us sampling rate
Add every 500th (2ms sampling rate) peak power sample to create a running maximum average power value.
Collect the first 500 samples at 2ms to compute the first Maximum Average Power value
7. Verify the maximum average power value with 25W, and then verify that the current peak power sample with the running maximum average power measurement. 8. Compute the maximum average power consumption for any continuous 25 sample/100us window 9. Verify the maximum average power value with 25W, and then verify the peak power samples with the computed maximum average power value. 10. Repeat after step 3 with each I/O Profile 11. Repeat after step 2 with each power state
Pass/Fail: Script passes if all tests pass
Open Compute Project Datacenter NVMe SSD Spec v2.5 requirements referenced by this script:
PCM-2/3, PWR-1/3, FFM2-14
- execute_io_profile(dut, test_type, io_profile, io_runtime=0, io_pattern=1)
- Executes each of the IO Profiles listed in Table 4
Sequential Read (MiB/s) (128kiB, QD = 128)
Sequential Write (MiB/s) (128kiB, QD = 128)
Random Read (KIOPS) (4kiB, QD = 128)
Random Writes (KIOPS) (4kiB, QD = 128)
Random 70R:30W mix (KIOPS) (4kiB, QD = 128)
- Parameters:
dut (XML_API) – Device object under test
test_type (str) – Either ‘Sequential’ | ‘Random’
io_profile (str) – IO Profile to be executed
io_runtime (int) – Time in seconds for IO to execute (Default 0 = Unlimited)
io_pattern (int) – Pattern for io to be executed
- Return type:
dict
DSSD_25_Power_Management_Feature_Test_Case.py
The objective of this test case is to verify the following:
That the power state descriptors provided as parameterization data are supported and returned by the Identify command controller dataset populated as expected.
Verify that the device uses a unique Maximum Power (MP) value in each supported NVMe Power State Descriptor.
That the Get/Set Features 02h and C7h commands are supported for the Power Management Feature.
That when a new power state is set using the set features command with the SV bit set, the new power state setting is retained through power cycles and is reported as the current value following a power cycle.
That all valid power states reported in the power state descriptor table are supported by the device by setting the power state via the set features command and verifying the power consumption changes to reflect the MP for the new power state.
That when an NVMe power state is set using set features 02h, the power state value is returned when using get features 02h, but the corresponding DSSD power state is reported when using get features C7.
That when a DSSD power state is set using set features C7h, the DSSD power state is reported using get features C7, but the corresponding NVMe power state is reported when using get features 02h.
Open Compute Project Datacenter NVMe SSD Spec v2.5 requirements referenced by this script:
PWR-1/5/8, DSSDPSS-1/2/3, SDSSDPS-1 to SDSSDPS-15, DSSDPSG-1/2, GDSSDPS-1/2, OCP 2.5 Section 4.8.11
- get_dssd_power_state(result, nvme_power_state)
Return the DSSD Power State corresponding to the given NVMe Power State.
Multiple DSSD Power States may reference a single NVMe Power State. The purpose of this function is to return the DSSD Power State a drive should report upon the selection of an NVMe Power State as defined by DSSDPSG-2:
OCP 2.5 Requirement DSSDPSG-2 If a DSSD Power State (Feature Identifier C7h) Get Feature command is executed and the current NVMe Power State was not selected because of a DSSD Power State Set Feature command, the device shall report the lowest power DSSD Power State whose number is greater than or equal to the Maximum Power in watts of the current NVMe Power State
- get_maximum_power_watts(result, nvme_power_state)
Calculate the Maximum Power, in watts, of the given NVMe Power State
- get_nvme_power_state(result, dssd_power_state)
Return the NVMe Power State corresponding to the given DSSD Power State
- postcondition(dut, ps)
Sets the current power state back to the default value
- Parameters:
dut (XML_API) – Device object under test
ps (int) – Power State to set device to
- Return type:
None