Page MenuHomeFreeBSD

rge: make int_rx_mod a sysctl tunable
Needs ReviewPublic

Authored by chris.longros_gmail.com on Thu, Mar 26, 9:00 PM.
Tags
None
Referenced Files
F153010819: D56102.diff
Sat, Apr 18, 2:59 PM
Unknown Object (File)
Fri, Apr 17, 2:00 PM
Unknown Object (File)
Sat, Apr 11, 8:04 PM
Unknown Object (File)
Sat, Apr 11, 12:26 PM
Unknown Object (File)
Wed, Apr 8, 9:59 AM
Unknown Object (File)
Tue, Apr 7, 8:23 PM
Unknown Object (File)
Tue, Apr 7, 4:45 PM
Unknown Object (File)
Mon, Apr 6, 1:37 PM
Subscribers

Details

Reviewers
adrian
Summary

The interrupt moderation timer value was hardcoded to 0x2600. Add a
per-interface sysctl dev.rge.%d.int_rx_mod tunable so users can
adjust this value at runtime.

Signed-off-by: Christos Longros <chris.longros@gmail.com>

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 71733
Build 68616: arc lint + arc unit

Event Timeline

@adrian could you please review the commit when you have time? Thanks :)

can you add some validation of the parameter before programming it into the register? surely it's not a single 32 bit field?

I've pushed D56103; please rebase this on top of -HEAD as of today and please address limiting the rx moderation value appropriately (just do it when you program; don't bother going through creating a SYSCTL_PROC hook to validate it on read/write..)

can you add some validation of the parameter before programming it into the register? surely it's not a single 32 bit field?

Added validation in rge_setup_sim_im() to clamp negative values before programming the register. I probed TIMERINT0 on hardware via PCI BAR0: writing 0xFFFFFFFF reads back 0xFFFFFFFF, so the register stores 32 bits. Could you confirm the timer field width so I can add an upper bound if needed?