Lines Matching refs:new_dbuf_state
651 struct intel_dbuf_state *new_dbuf_state = in skl_crtc_allocate_ddb() local
662 if (new_dbuf_state->weight[pipe] == 0) { in skl_crtc_allocate_ddb()
663 skl_ddb_entry_init(&new_dbuf_state->ddb[pipe], 0, 0); in skl_crtc_allocate_ddb()
667 dbuf_slice_mask = new_dbuf_state->slices[pipe]; in skl_crtc_allocate_ddb()
673 intel_crtc_dbuf_weights(new_dbuf_state, pipe, in skl_crtc_allocate_ddb()
679 skl_ddb_entry_init(&new_dbuf_state->ddb[pipe], in skl_crtc_allocate_ddb()
684 if (old_dbuf_state->slices[pipe] == new_dbuf_state->slices[pipe] && in skl_crtc_allocate_ddb()
686 &new_dbuf_state->ddb[pipe])) in skl_crtc_allocate_ddb()
689 ret = intel_atomic_lock_global_state(&new_dbuf_state->base); in skl_crtc_allocate_ddb()
701 crtc_state->wm.skl.ddb.start = mbus_offset + new_dbuf_state->ddb[pipe].start; in skl_crtc_allocate_ddb()
702 crtc_state->wm.skl.ddb.end = mbus_offset + new_dbuf_state->ddb[pipe].end; in skl_crtc_allocate_ddb()
707 old_dbuf_state->slices[pipe], new_dbuf_state->slices[pipe], in skl_crtc_allocate_ddb()
709 new_dbuf_state->ddb[pipe].start, new_dbuf_state->ddb[pipe].end, in skl_crtc_allocate_ddb()
710 old_dbuf_state->active_pipes, new_dbuf_state->active_pipes); in skl_crtc_allocate_ddb()
2493 struct intel_dbuf_state *new_dbuf_state = NULL; in skl_compute_ddb() local
2499 new_dbuf_state = intel_atomic_get_dbuf_state(state); in skl_compute_ddb()
2500 if (IS_ERR(new_dbuf_state)) in skl_compute_ddb()
2501 return PTR_ERR(new_dbuf_state); in skl_compute_ddb()
2507 if (!new_dbuf_state) in skl_compute_ddb()
2510 new_dbuf_state->active_pipes = in skl_compute_ddb()
2513 if (old_dbuf_state->active_pipes != new_dbuf_state->active_pipes) { in skl_compute_ddb()
2514 ret = intel_atomic_lock_global_state(&new_dbuf_state->base); in skl_compute_ddb()
2520 new_dbuf_state->joined_mbus = in skl_compute_ddb()
2521 adlp_check_mbus_joined(new_dbuf_state->active_pipes); in skl_compute_ddb()
2523 if (old_dbuf_state->joined_mbus != new_dbuf_state->joined_mbus) { in skl_compute_ddb()
2524 ret = intel_cdclk_state_set_joined_mbus(state, new_dbuf_state->joined_mbus); in skl_compute_ddb()
2533 new_dbuf_state->slices[pipe] = in skl_compute_ddb()
2534 skl_compute_dbuf_slices(crtc, new_dbuf_state->active_pipes, in skl_compute_ddb()
2535 new_dbuf_state->joined_mbus); in skl_compute_ddb()
2537 if (old_dbuf_state->slices[pipe] == new_dbuf_state->slices[pipe]) in skl_compute_ddb()
2540 ret = intel_atomic_lock_global_state(&new_dbuf_state->base); in skl_compute_ddb()
2545 new_dbuf_state->enabled_slices = intel_dbuf_enabled_slices(new_dbuf_state); in skl_compute_ddb()
2547 if (old_dbuf_state->enabled_slices != new_dbuf_state->enabled_slices || in skl_compute_ddb()
2548 old_dbuf_state->joined_mbus != new_dbuf_state->joined_mbus) { in skl_compute_ddb()
2549 ret = intel_atomic_serialize_global_state(&new_dbuf_state->base); in skl_compute_ddb()
2556 new_dbuf_state->enabled_slices, in skl_compute_ddb()
2559 str_yes_no(new_dbuf_state->joined_mbus)); in skl_compute_ddb()
2565 new_dbuf_state->weight[pipe] = intel_crtc_ddb_weight(new_crtc_state); in skl_compute_ddb()
2567 if (old_dbuf_state->weight[pipe] == new_dbuf_state->weight[pipe]) in skl_compute_ddb()
2570 ret = intel_atomic_lock_global_state(&new_dbuf_state->base); in skl_compute_ddb()
3478 const struct intel_dbuf_state *new_dbuf_state, *old_dbuf_state; in intel_mbus_dbox_update() local
3485 new_dbuf_state = intel_atomic_get_new_dbuf_state(state); in intel_mbus_dbox_update()
3487 if (!new_dbuf_state || in intel_mbus_dbox_update()
3488 (new_dbuf_state->joined_mbus == old_dbuf_state->joined_mbus && in intel_mbus_dbox_update()
3489 new_dbuf_state->active_pipes == old_dbuf_state->active_pipes)) in intel_mbus_dbox_update()
3502 val |= new_dbuf_state->joined_mbus ? MBUS_DBOX_A_CREDIT(12) : in intel_mbus_dbox_update()
3506 val |= new_dbuf_state->joined_mbus ? MBUS_DBOX_A_CREDIT(6) : in intel_mbus_dbox_update()
3524 for_each_intel_crtc_in_pipe_mask(&i915->drm, crtc, new_dbuf_state->active_pipes) { in intel_mbus_dbox_update()
3529 new_dbuf_state->active_pipes)) in intel_mbus_dbox_update()
3582 const struct intel_dbuf_state *new_dbuf_state = in intel_dbuf_mdclk_min_tracker_update() local
3591 mdclk_cdclk_ratio = new_dbuf_state->mdclk_cdclk_ratio; in intel_dbuf_mdclk_min_tracker_update()
3595 new_dbuf_state->joined_mbus); in intel_dbuf_mdclk_min_tracker_update()
3624 const struct intel_dbuf_state *new_dbuf_state = in intel_dbuf_mbus_join_update() local
3630 str_yes_no(new_dbuf_state->joined_mbus), in intel_dbuf_mbus_join_update()
3633 if (new_dbuf_state->joined_mbus) in intel_dbuf_mbus_join_update()
3650 const struct intel_dbuf_state *new_dbuf_state = in intel_dbuf_mbus_pre_ddb_update() local
3655 if (!new_dbuf_state) in intel_dbuf_mbus_pre_ddb_update()
3658 if (!old_dbuf_state->joined_mbus && new_dbuf_state->joined_mbus) { in intel_dbuf_mbus_pre_ddb_update()
3659 enum pipe pipe = intel_mbus_joined_pipe(state, new_dbuf_state); in intel_dbuf_mbus_pre_ddb_update()
3661 WARN_ON(!new_dbuf_state->base.changed); in intel_dbuf_mbus_pre_ddb_update()
3672 const struct intel_dbuf_state *new_dbuf_state = in intel_dbuf_mbus_post_ddb_update() local
3677 if (!new_dbuf_state) in intel_dbuf_mbus_post_ddb_update()
3680 if (old_dbuf_state->joined_mbus && !new_dbuf_state->joined_mbus) { in intel_dbuf_mbus_post_ddb_update()
3683 WARN_ON(!new_dbuf_state->base.changed); in intel_dbuf_mbus_post_ddb_update()
3694 } else if (old_dbuf_state->joined_mbus == new_dbuf_state->joined_mbus && in intel_dbuf_mbus_post_ddb_update()
3695 old_dbuf_state->active_pipes != new_dbuf_state->active_pipes) { in intel_dbuf_mbus_post_ddb_update()
3696 WARN_ON(!new_dbuf_state->base.changed); in intel_dbuf_mbus_post_ddb_update()
3707 const struct intel_dbuf_state *new_dbuf_state = in intel_dbuf_pre_plane_update() local
3713 if (!new_dbuf_state) in intel_dbuf_pre_plane_update()
3717 new_slices = old_dbuf_state->enabled_slices | new_dbuf_state->enabled_slices; in intel_dbuf_pre_plane_update()
3722 WARN_ON(!new_dbuf_state->base.changed); in intel_dbuf_pre_plane_update()
3730 const struct intel_dbuf_state *new_dbuf_state = in intel_dbuf_post_plane_update() local
3736 if (!new_dbuf_state) in intel_dbuf_post_plane_update()
3739 old_slices = old_dbuf_state->enabled_slices | new_dbuf_state->enabled_slices; in intel_dbuf_post_plane_update()
3740 new_slices = new_dbuf_state->enabled_slices; in intel_dbuf_post_plane_update()
3745 WARN_ON(!new_dbuf_state->base.changed); in intel_dbuf_post_plane_update()