Add PMD power management
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v20 Latest4 patches 5 repliesIn review
- v194 patches 0 repliesSuperseded
- v182 patches 0 repliesSuperseded
Earlier versions · 6
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v17 | 11 patches | 21 replies | Superseded | |
| v16 | 11 patches | 12 replies | Superseded | |
| v15 | 11 patches | 2 replies | Superseded | |
| v14 | 11 patches | 0 replies | Superseded | |
| v13 | 11 patches | 10 replies | Superseded | |
| v12 | 11 patches | 10 replies | Superseded |
Changes in v20 from the cover letter
- Moved callback removal before port close
Patches in v20 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | eal: rename power monitor condition memberdrivers/ drivers/ drivers/ +4 more | +18 | 1 reply | |
| 2/4 | eal: improve comments around power monitoring APIlib/ | +13 | 1 reply | |
| 3/4 | power: add PMD power management API and callbackdoc/ doc/ lib/ +3 more | +515 | 0 replies | |
| 4/4 | examples/l3fwd-power: enable PMD power mgmtdoc/ examples/ | +123 | 1 reply |
Reviews trailers per patch
All 4 patches have a Reviewed-by or Acked-by.
| Patch | David Hunt | Thomas Monjalon |
|---|---|---|
| 1/4 | A-b | |
| 2/4 | A-b | |
| 3/4 | A-b | |
| 4/4 | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [dpdk-dev] [PATCH v20 0/4] Add PMD power management
This patchset proposes a simple API for Ethernet drivers to cause the CPU to enter a power-optimized state while waiting for packets to arrive. There are multiple proposed mechanisms to achieve said power
savings: simple frequency scaling, idle loop, and monitoring the Rx queue for incoming packages. The latter is achieved through cooperation with the NIC driver that will allow us to know address of wake up event, and wait for writes on that address.
To achieve power savings, there is a very simple mechanism used: we're counting empty polls, and if a certain threshold is reached, we employ one of the suggested power management schemes automatically, from within a Rx callback inside the PMD. Once there's traffic again, the empty poll counter is reset.
Why are we putting it into ethdev as opposed to leaving this up to the application? Our customers specifically requested a way to do it with minimal changes to the application code. The current approach allows to just flip a switch and automatically have power savings.
Things of note:
- Only 1:1 core to queue mapping is supported, meaning that each lcore must at most handle RX on a single queue
- Support 3 type policies. Monitor/Pause/Frequency Scaling
- Power management is enabled per-queue
- The API doesn't extend to other device types
v20:
- Moved callback removal before port close
v19:
- Renamed "data_sz" to "size" and clarified struct comments
- Clarified documentation around rte_power_monitor/pause API
v18:
- Rebase on top of latest main
- Address review comments by Thomas
v17:
- Added exception for ethdev driver-only ABI
- Added memory barriers for monitor/wakeup (Konstantin)
- Fixed compiled issues on non-x86 platforms (hopefully!)
v16:
- Implemented Konstantin's suggestions and comments
- Added return values to the API
v15:
- Fixed incorrect check in UMWAIT callback
- Fixed accidental whitespace changes
v14:
- Fixed ARM/PPC builds
- Addressed various review comments
v13:
- Reworked the librte_power code to require less locking and handle invalid parameters better
- Fix numerous rebase errors present in v12
v12:
- Rebase on top of 21.02
- Rework of power intrinsics code
Anatoly Burakov (2):
eal: rename power monitor condition member
eal: improve comments around power monitoring API
Liang Ma (2):
power: add PMD power management API and callback examples/l3fwd-power: enable PMD power mgmt
doc/guides/prog_guide/power_man.rst | 41 ++ doc/guides/rel_notes/release_21_02.rst | 10 + .../sample_app_ug/l3_forward_power_man.rst | 35 ++ drivers/event/dlb/dlb.c | 2 +- drivers/event/dlb2/dlb2.c | 2 +- drivers/net/i40e/i40e_rxtx.c | 2 +- drivers/net/ice/ice_rxtx.c | 2 +- drivers/net/ixgbe/ixgbe_rxtx.c | 2 +- examples/l3fwd-power/main.c | 90 ++++- .../include/generic/rte_power_intrinsics.h | 39 +- lib/librte_eal/x86/rte_power_intrinsics.c | 4 +- lib/librte_power/meson.build | 5 +- lib/librte_power/rte_power_pmd_mgmt.c | 365 ++++++++++++++++++ lib/librte_power/rte_power_pmd_mgmt.h | 91 +++++ lib/librte_power/version.map | 5 + 15 files changed, 669 insertions(+), 26 deletions(-) create mode 100644 lib/librte_power/rte_power_pmd_mgmt.c create mode 100644 lib/librte_power/rte_power_pmd_mgmt.h
Signature · 1 line
2.25.1