Skip to content

Clear bits 31:16 on RSS indirection table reads - #83

Open
sidcraftscode wants to merge 1 commit into
Xilinx:mainfrom
sidcraftscode:rss-table-readback
Open

sidcraftscode wants to merge 1 commit into
Xilinx:mainfrom
sidcraftscode:rss-table-readback

Conversation

@sidcraftscode

Copy link
Copy Markdown

In src/qdma_subsystem/qdma_subsystem_function_register.sv, a read of the RSS indirection table (0x400 to 0x5FF) only assigns reg_dout[15:0]. The other read paths write all 32 bits, so bits 31:16 of a table read keep whatever the previous read left: 0xDEAD after an unmapped address, q_base after the queue config register, or the top half of a hash key word. The register map at the top of the file lists those bits as reserved.

The fix zero-extends the entry: reg_dout <= {16'b0, reg_table[reg_addr[8:2]]};

open-nic-driver masks the value with 0xFFFF in onic_get_rxfh(), so ethtool -x is fine today. Anything else that reads the table back as a full word sees the stale bits.

Checked with a Verilator testbench over AXI-Lite. Reading table[5] (set to 3) right after an unmapped read, a qconf read and a hash key read returned 0xDEAD0003, 0x00100003 and 0xD6E30003 before the change, and 0x00000003 each time after.

A read of the indirection table (0x400 - 0x5FF) in
qdma_subsystem_function_register only assigns reg_dout[15:0], so bits
31:16 keep whatever the previous read left there: 0xDEAD after an
unmapped address, q_base after the queue config register, or part of a
hash key word. The register map lists those bits as reserved.

Zero-extend the table entry so the upper half reads as 0.

Signed-off-by: Sid Chaudhary <sidchaudhary04@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant