Page MenuHomeFreeBSD

remove references to CONTIGMALLOC_WORKS in iflib
ClosedPublic

Authored by jacob.e.keller_intel.com on Feb 14 2019, 6:20 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Nov 7, 6:28 PM
Unknown Object (File)
Oct 18 2024, 8:06 PM
Unknown Object (File)
Oct 3 2024, 7:54 PM
Unknown Object (File)
Oct 1 2024, 8:20 PM
Unknown Object (File)
Sep 29 2024, 9:45 PM
Unknown Object (File)
Sep 28 2024, 8:19 AM
Unknown Object (File)
Sep 28 2024, 12:58 AM
Unknown Object (File)
Sep 23 2024, 12:04 PM
Subscribers

Details

Summary

The iflib_fl_setup() function tries to pick various buffer sizes based
on the max_frame_size value defined by the parent driver. However, this
code was wrapped under CONTIGMALLOC_WORKS, which was never actually
defined anywhere.

This same code pattern was used in the if_em.c, likely trying to match
what iflib uses.

Since COTIGMALLOC_WORKS is not defined, remove this dead code from
iflib_fl_setup and if_em.c

Given that various iflib drivers appear to be using a similar
calculation, it might be worth making this buffer size a value that the
driver can peek at in the future.

Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 22505
Build 21653: arc lint + arc unit

Event Timeline

I think it would be useful to actually expose the ifl_buf_size calculation somehow, since hardware needs this information. Currently, most drivers just calculate the value in the same way that iflib does, but that seems error prone if we ever do change this in the future.

TBH, that might actually be why no one ever saw a real increase here, because unless you program hardware to use a larger buffer size, increasing it would just waste memory...

This revision is now accepted and ready to land.Feb 14 2019, 7:33 PM
This revision was automatically updated to reflect the committed changes.