Skip to content

Commit 369451d

Browse files
6by9popcornmix
authored andcommitted
drm/vc4: Do not include writeback conn load in load tracker
The transposer/writeback connector should be running with a lower priority, so shouldn't be factored into the load calculations. Signed-off-by: Dave Stevenson <[email protected]>
1 parent 0cb8524 commit 369451d

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed

drivers/gpu/drm/vc4/vc4_kms.c

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -660,17 +660,26 @@ static int vc4_load_tracker_atomic_check(struct drm_atomic_state *state)
660660
for_each_oldnew_plane_in_state(state, plane, old_plane_state,
661661
new_plane_state, i) {
662662
struct vc4_plane_state *vc4_plane_state;
663+
struct vc4_crtc *vc4_crtc;
663664

664665
if (old_plane_state->fb && old_plane_state->crtc) {
665666
vc4_plane_state = to_vc4_plane_state(old_plane_state);
666-
load_state->membus_load -= vc4_plane_state->membus_load;
667-
load_state->hvs_load -= vc4_plane_state->hvs_load;
667+
vc4_crtc = to_vc4_crtc(old_plane_state->crtc);
668+
669+
if (!vc4_crtc->feeds_txp) {
670+
load_state->membus_load -= vc4_plane_state->membus_load;
671+
load_state->hvs_load -= vc4_plane_state->hvs_load;
672+
}
668673
}
669674

670675
if (new_plane_state->fb && new_plane_state->crtc) {
671676
vc4_plane_state = to_vc4_plane_state(new_plane_state);
672-
load_state->membus_load += vc4_plane_state->membus_load;
673-
load_state->hvs_load += vc4_plane_state->hvs_load;
677+
vc4_crtc = to_vc4_crtc(new_plane_state->crtc);
678+
679+
if (!vc4_crtc->feeds_txp) {
680+
load_state->membus_load += vc4_plane_state->membus_load;
681+
load_state->hvs_load += vc4_plane_state->hvs_load;
682+
}
674683
}
675684
}
676685

0 commit comments

Comments
 (0)