Skip to content

Commit b756b0c

Browse files
committed
drm/atomic-helper: Change parameter name of drm_atomic_helper_fake_vblank()
drm_atomic_helper_fake_vblank() fake a vblank event if needed when a new commit is being applied. It takes the drm_atomic_state being committed as a parameter. However, that parameter name is called (and documented) as old_state, which is pretty confusing. Let's rename that variable as state. Reviewed-by: Dmitry Baryshkov <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Maxime Ripard <[email protected]>
1 parent f129660 commit b756b0c

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

drivers/gpu/drm/drm_atomic_helper.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2472,7 +2472,7 @@ EXPORT_SYMBOL(drm_atomic_helper_wait_for_dependencies);
24722472

24732473
/**
24742474
* drm_atomic_helper_fake_vblank - fake VBLANK events if needed
2475-
* @old_state: atomic state object with old state structures
2475+
* @state: atomic state object being committed
24762476
*
24772477
* This function walks all CRTCs and fakes VBLANK events on those with
24782478
* &drm_crtc_state.no_vblank set to true and &drm_crtc_state.event != NULL.
@@ -2488,25 +2488,25 @@ EXPORT_SYMBOL(drm_atomic_helper_wait_for_dependencies);
24882488
* This is part of the atomic helper support for nonblocking commits, see
24892489
* drm_atomic_helper_setup_commit() for an overview.
24902490
*/
2491-
void drm_atomic_helper_fake_vblank(struct drm_atomic_state *old_state)
2491+
void drm_atomic_helper_fake_vblank(struct drm_atomic_state *state)
24922492
{
24932493
struct drm_crtc_state *new_crtc_state;
24942494
struct drm_crtc *crtc;
24952495
int i;
24962496

2497-
for_each_new_crtc_in_state(old_state, crtc, new_crtc_state, i) {
2497+
for_each_new_crtc_in_state(state, crtc, new_crtc_state, i) {
24982498
unsigned long flags;
24992499

25002500
if (!new_crtc_state->no_vblank)
25012501
continue;
25022502

2503-
spin_lock_irqsave(&old_state->dev->event_lock, flags);
2503+
spin_lock_irqsave(&state->dev->event_lock, flags);
25042504
if (new_crtc_state->event) {
25052505
drm_crtc_send_vblank_event(crtc,
25062506
new_crtc_state->event);
25072507
new_crtc_state->event = NULL;
25082508
}
2509-
spin_unlock_irqrestore(&old_state->dev->event_lock, flags);
2509+
spin_unlock_irqrestore(&state->dev->event_lock, flags);
25102510
}
25112511
}
25122512
EXPORT_SYMBOL(drm_atomic_helper_fake_vblank);

0 commit comments

Comments
 (0)