Skip to contentSkip to conversation

Fix tests/test_device.py

PATCH In review Bob Pearson 2 participants 2 messages Aug 25, 2020 InfiniBand

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Fix tests/test_device.py

Removed a test case which requires vendor_part_id to be non zero. Per IBTA A3.3.1 VENDOR INFORMATION it is not required that the vendor part ID field be set to a non-zero value:

The following components are vendor specific: VendorID, DeviceID, De- vice Version, Subsystem VendorID, SubsystemID, ID String.

The vendor places its IEEE assigned Organization Unique Identifier (OUI) in the VendorId field and *MAY PLACE ANY VALUE IN THE DEVICEID* and Device Version fields. The vendor may also provide an ASCII string of its choice in the ID String field.

The Subsystem VendorID and SubsystemID provide additional informa- tion when a subsystem vendor uses components provided by other ven- dors. In this case the subsystem vendor provides its OUI in the Subsystem VendorID field and may specify any value in the SubsystemD field. A vendor that produces a generic controller (i.e., one that supports a stan- dard I/O protocol such as SRP), which does not have vendor specific de- vice drivers, may use the value of 0xFFFFFF in the VendorID field. However, such a value prevents the vendor from ever providing vendor specific drivers for the product.

---
 tests/test_device.py | 1 -
 1 file changed, 1 deletion(-)
tests/test_device.py +0 -1
index c23caae1..d552f402 100644
@@ -86,7 +86,6 @@ class DeviceTest(PyverbsAPITestCase):
         assert attr.max_mr_size > PAGE_SIZE
         assert attr.page_size_cap >= PAGE_SIZE
         assert attr.vendor_id != 0
-        assert attr.vendor_part_id != 0
         assert attr.max_qp > 0
         assert attr.max_qp_wr > 0
         assert attr.max_sge > 0
Signature · 1 line
2.25.1
#1 lore raw
Quoted 22 lines · Bob Pearson

Removed a test case which requires vendor_part_id to be non zero. Per IBTA A3.3.1 VENDOR INFORMATION it is not required that the vendor part ID field be set to a non-zero value:

The following components are vendor specific: VendorID, DeviceID, De- vice Version, Subsystem VendorID, SubsystemID, ID String.

The vendor places its IEEE assigned Organization Unique Identifier (OUI) in the VendorId field and *MAY PLACE ANY VALUE IN THE DEVICEID* and Device Version fields. The vendor may also provide an ASCII string of its choice in the ID String field.

The Subsystem VendorID and SubsystemID provide additional informa- tion when a subsystem vendor uses components provided by other ven- dors. In this case the subsystem vendor provides its OUI in the Subsystem VendorID field and may specify any value in the SubsystemD field. A vendor that produces a generic controller (i.e., one that supports a stan- dard I/O protocol such as SRP), which does not have vendor specific de- vice drivers, may use the value of 0xFFFFFF in the VendorID field. However, such a value prevents the vendor from ever providing vendor specific drivers for the product.

Quoted 4 lines
---
 tests/test_device.py | 1 -
 1 file changed, 1 deletion(-)

Thanks, I'll pick to rdma-core later this week if no objections come.