Skip to content

RFC Current State of my clk patches

Karol Herbst nouveau 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest29 patches 20 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/29therm: split return code and value in nvkm_get_tempdrm/nouveau/include/nvkm/subdev/therm.h drm/nouveau/nouveau_hwmon.c drm/nouveau/nvkm/subdev/therm/base.c +6 more+55 -392 replies
2/29hwmon: properly check for errorsdrm/nouveau/nouveau_hwmon.c+26 -71 reply
3/29subdev/volt/gk104: return error when read failsdrm/nouveau/nvkm/subdev/volt/gk104.c+6 -12 replies
4/29clk: Rename nvkm_pstate_calc to nvkm_clk_update and export itdrm/nouveau/include/nvkm/subdev/clk.h drm/nouveau/nvkm/subdev/clk/base.c+17 -102 replies
5/29clk: Remove dstatedrm/nouveau/include/nvkm/subdev/clk.h drm/nouveau/nvkm/subdev/clk/base.c+2 -161 reply
6/29clk: Make pstate a pointer to nvkm_pstatedrm/nouveau/include/nvkm/subdev/clk.h drm/nouveau/nvkm/engine/device/ctrl.c drm/nouveau/nvkm/subdev/clk/base.c +1 more+26 -182 replies
7/29clk: Hold information about the current cstate statusdrm/nouveau/include/nvkm/subdev/clk.h drm/nouveau/nvkm/subdev/clk/base.c+27 -71 reply
8/29clk: We should pass the pstate id around not the index in the listdrm/nouveau/nouveau_debugfs.c drm/nouveau/nvkm/subdev/clk/base.c+41 -432 replies
9/29clk: Set clocks to pre suspend state after suspenddrm/nouveau/nvkm/subdev/clk/base.c+7 -31 reply
10/29core/device: Move therm behind clkdrm/nouveau/include/nvkm/core/device.h+1 -10 replies
11/29debugfs: Wake up GPU before doing any reclockingdrm/nouveau/nouveau_debugfs.c+4 -00 replies
12/29therm: Don't cancel the timerdrm/nouveau/nvkm/subdev/therm/base.c+2 -70 replies
13/29therm: Move the temp readout into the alarmdrm/nouveau/include/nvkm/subdev/therm.h drm/nouveau/nvkm/subdev/therm/base.c+21 -230 replies
14/29therm: Trigger reclock in temperature daemondrm/nouveau/nvkm/subdev/therm/base.c+8 -01 reply
15/29bios: add thermal policies tabledrm/nouveau/include/nvkm/subdev/bios/thermal_policies.h drm/nouveau/nvkm/subdev/bios/Kbuild drm/nouveau/nvkm/subdev/bios/thermal_policies.c+109 -02 replies
16/29clk: parse thermal policies for throttling thresholdsdrm/nouveau/include/nvkm/subdev/clk.h drm/nouveau/nvkm/subdev/clk/base.c+44 -02 replies
17/29clk: thermal throttlingdrm/nouveau/include/nvkm/subdev/clk.h drm/nouveau/nvkm/subdev/clk/base.c+33 -121 reply
18/29clk: Only do partial reclocks as requireddrm/nouveau/nvkm/subdev/clk/base.c drm/nouveau/nvkm/subdev/volt/base.c+21 -80 replies
19/29secboot/acr352: reset PMU after secbootdrm/nouveau/nvkm/subdev/secboot/acr_r352.c+13 -00 replies
20/29device: enable clk for Maxwell2drm/nouveau/nvkm/engine/device/base.c drm/nouveau/nvkm/subdev/clk/gk104.c+12 -10 replies
21/29clk: Save the max clock we can setdrm/nouveau/include/nvkm/subdev/clk.h drm/nouveau/nvkm/subdev/clk/base.c+3 -00 replies
22/29nvif: Add boost info and set operationsdrm/nouveau/include/nvif/if0001.h drm/nouveau/nvkm/engine/device/ctrl.c+76 -00 replies
23/29debugfs: Add boost interface to change the boost_modedrm/nouveau/nouveau_debugfs.c+80 -00 replies
24/29bios/vpstate: there are some fermi vbios with no boost or tdp entrydrm/nouveau/nvkm/subdev/bios/vpstate.c+8 -20 replies
25/29bios/vpstate: parse max battery iddrm/nouveau/include/nvkm/subdev/bios/vpstate.h drm/nouveau/nvkm/subdev/bios/vpstate.c+3 -10 replies
26/29clk: refactor the base and boost clock limits so that we can limit pstates as welldrm/nouveau/include/nvkm/subdev/clk.h drm/nouveau/nvkm/engine/device/ctrl.c drm/nouveau/nvkm/subdev/clk/base.c+36 -150 replies
27/29clk: implement limiting pstates just like we do for cstatesdrm/nouveau/nvkm/subdev/clk/base.c+52 -100 replies
28/29clk: move the switch out of the loop in nvkm_cstate_validdrm/nouveau/nvkm/subdev/clk/base.c+19 -170 replies
29/29clk: limit clocks on batterydrm/nouveau/include/nvkm/subdev/clk.h drm/nouveau/nvkm/subdev/clk/base.c+19 -00 replies

Reviews trailers per patch

14 of 29 patches have a Reviewed-by or Acked-by.

PatchMartin PeresPierre Moreau
1/29
2/29R-b
3/29R-b
4/29
5/29R-b R-b
6/29R-b
7/29R-b A-b
8/29R-b
9/29R-b R-b
10/29
11/29
12/29R-b
13/29
14/29R-b R-b
15/29A-b
16/29
17/29R-b
18/29
19/29
20/29
21/29R-b
22/29R-b
23/29R-b
24/29
25/29
26/29
27/29
28/29
29/29

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [RFC PATCH 00/29] Current State of my clk patches

Just wanted to post updated versions of my last series/patches. Reviews welcomed.

It would be also nice if we agree on features I should focus upstreaming, so that this work can be better splitted or reordered.

Sadly most of my patches depend on the rather big clk subdev rework and I think those patches shows best, why I think this rework is actually needed and makes things much easier to add later on.

Feature overview:
1- 3: Hwmon fixes on suspended device
4- 8: Clk subdev rework to decouple current and expected clock states
Fix reclocking while suspended
9: Restore clocks on Suspend
10: Fix reclocking while going into suspend
11: Fix reclocking while suspending
12-14: Thermal daemon triggers reclocks on temperature change when needed
includes volt updates and dropping cstates according to the vbios
15-17: Thermal throttling
18: Don't do full reclocks when only parts need to be updated
19-20: Hacky Workaround for enabling Maxwell2 reclocking (hidden behind module parameter) 21-23: debugfs file to change boost mode
24-29: Parse battery vpstate to throttle clocks when system is running on battery

Karol Herbst (29):
therm: split return code and value in nvkm_get_temp
hwmon: properly check for errors
subdev/volt/gk104: return error when read fails
clk: Rename nvkm_pstate_calc to nvkm_clk_update and export it
clk: Remove dstate
clk: Make pstate a pointer to nvkm_pstate
clk: Hold information about the current cstate status
clk: We should pass the pstate id around not the index in the list
clk: Set clocks to pre suspend state after suspend core/device: Move therm behind clk
debugfs: Wake up GPU before doing any reclocking
therm: Don't cancel the timer
therm: Move the temp readout into the alarm
therm: Trigger reclock in temperature daemon
bios: add thermal policies table
clk: parse thermal policies for throttling thresholds
clk: thermal throttling
clk: Only do partial reclocks as required secboot/acr352: reset PMU after secboot
device: enable clk for Maxwell2
clk: Save the max clock we can set
nvif: Add boost info and set operations
debugfs: Add boost interface to change the boost_mode bios/vpstate: there are some fermi vbios with no boost or tdp entry bios/vpstate: parse max battery id
clk: refactor the base and boost clock limits so that we can limit
pstates as well
clk: implement limiting pstates just like we do for cstates
clk: move the switch out of the loop in nvkm_cstate_valid
clk: limit clocks on battery

 drm/nouveau/include/nvif/if0001.h                  |  15 +
 drm/nouveau/include/nvkm/core/device.h             |   2 +-
 .../include/nvkm/subdev/bios/thermal_policies.h    |  27 ++
 drm/nouveau/include/nvkm/subdev/bios/vpstate.h     |   1 +
 drm/nouveau/include/nvkm/subdev/clk.h              |  23 +-
 drm/nouveau/include/nvkm/subdev/therm.h            |   3 +-
 drm/nouveau/nouveau_debugfs.c                      |  90 ++++-
 drm/nouveau/nouveau_hwmon.c                        |  48 ++-
 drm/nouveau/nvkm/engine/device/base.c              |   3 +
 drm/nouveau/nvkm/engine/device/ctrl.c              |  66 +++-
 drm/nouveau/nvkm/subdev/bios/Kbuild                |   1 +
 drm/nouveau/nvkm/subdev/bios/thermal_policies.c    |  81 +++++
 drm/nouveau/nvkm/subdev/bios/vpstate.c             |  13 +-
 drm/nouveau/nvkm/subdev/clk/base.c                 | 375 +++++++++++++++------
 drm/nouveau/nvkm/subdev/clk/gk104.c                |  10 +-
 drm/nouveau/nvkm/subdev/pmu/gk20a.c                |  18 +-
 drm/nouveau/nvkm/subdev/secboot/acr_r352.c         |  13 +
 drm/nouveau/nvkm/subdev/therm/base.c               |  59 ++--
 drm/nouveau/nvkm/subdev/therm/g84.c                |  11 +-
 drm/nouveau/nvkm/subdev/therm/gp100.c              |   9 +-
 drm/nouveau/nvkm/subdev/therm/nv40.c               |   9 +-
 drm/nouveau/nvkm/subdev/therm/nv50.c               |   9 +-
 drm/nouveau/nvkm/subdev/therm/priv.h               |   4 +-
 drm/nouveau/nvkm/subdev/therm/temp.c               |  16 +-
 drm/nouveau/nvkm/subdev/volt/base.c                |   3 +
 drm/nouveau/nvkm/subdev/volt/gk104.c               |   7 +-
 26 files changed, 723 insertions(+), 193 deletions(-)
 create mode 100644 drm/nouveau/include/nvkm/subdev/bios/thermal_policies.h
 create mode 100644 drm/nouveau/nvkm/subdev/bios/thermal_policies.c
Signature · 6 lines
2.14.1

_______________________________________________
Nouveau mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/nouveau