Skip to content

Commit

Permalink
drm/v3d: Correct clock settng calls to new APIs
Browse files Browse the repository at this point in the history
There was a report that 6.12 kernel has lower benchmark
scores than 6.6.

I can confirm, and found it started with 6.8 kernel
which moved some code into a new file (v3d_submit.c)
and in two places the change to the clock api were missed.

The effect of the bug is the v3d clock sometimes
unwantedly drops to a lower rate.

With this patch the benchmark scores are good again.

Fixes: 8696303

Signed-off-by: Dom Cobley <[email protected]>
  • Loading branch information
popcornmix committed Dec 10, 2024
1 parent 37cb5f7 commit 2b062ea
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/gpu/drm/v3d/v3d_submit.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ v3d_clock_down_work(struct work_struct *work)
container_of(work, struct v3d_dev, clk_down_work.work);
int ret;

ret = clk_set_rate(v3d->clk, v3d->clk_down_rate);
ret = clk_set_min_rate(v3d->clk, v3d->clk_down_rate);
v3d->clk_up = false;
WARN_ON_ONCE(ret != 0);
}
Expand All @@ -32,7 +32,7 @@ v3d_clock_up_get(struct v3d_dev *v3d)
if (!v3d->clk_up) {
int ret;

ret = clk_set_rate(v3d->clk, v3d->clk_up_rate);
ret = clk_set_min_rate(v3d->clk, v3d->clk_up_rate);
WARN_ON_ONCE(ret != 0);
v3d->clk_up = true;
}
Expand Down

0 comments on commit 2b062ea

Please sign in to comment.