Hi,

> -----Original Message-----
> From: Rongwei Liu <[email protected]>
> Sent: Monday, June 12, 2023 11:04 AM
> To: [email protected]; Matan Azrad <[email protected]>; Slava Ovsiienko
> <[email protected]>; Ori Kam <[email protected]>; Suanming Mou
> <[email protected]>; NBU-Contact-Thomas Monjalon (EXTERNAL)
> <[email protected]>
> Subject: [PATCH v1] net/mlx5: adapt parse graph header length limitation
> 
> Firmware exports the parse graph header length capability via hca_attr and the
> current value is 6.
> The user must specify the header length field via field_size.
> Field size implies the mask implicitly as 2^field_size-1
> 
> 1. If field_size is bigger than 6, PMD needs to add an extra offset 
> internally, let
> HW only parses the 6 LSBs as length.
>            length
> |--------|--------|--------|--------|
> The actual header length offset 8 doesn't work well with new firmware, only
> the bits 8-13 are read and parsed as a length field.
> Need to change the offset to 10 (8 + 2) internally. Field mask can't be bigger
> than 0x3F (2^6-1).
> 
> 2. If filed_size is smaller that 6, PMD needs to subtract an offset to fit 6 
> bits
> exactly.
>          length
> |--------|----|------------|--------|
> The actual header length offset 8 doesn't work well with new firmware
> because firmware will read two more bits from the next field.
> Need to change the offset to 6 (8 -2) internally.
> 
> Signed-off-by: Rongwei Liu <[email protected]>
> Acked-by: Viacheslav Ovsiienko <[email protected]>

Patch applied to next-net-mlx,

Kindest regards,
Raslan Darawsheh

Reply via email to