1/* SPDX-License-Identifier: MIT */
2/*
3 * Copyright © 2023 Intel Corporation
4 */
5
6#ifndef __INTEL_PMDEMAND_H__
7#define __INTEL_PMDEMAND_H__
8
9#include <linux/types.h>
10
11enum pipe;
12struct intel_atomic_state;
13struct intel_crtc_state;
14struct intel_display;
15struct intel_encoder;
16struct intel_global_state;
17struct intel_plane_state;
18struct intel_pmdemand_state;
19
20struct intel_pmdemand_state *to_intel_pmdemand_state(struct intel_global_state *obj_state);
21
22void intel_pmdemand_init_early(struct intel_display *display);
23int intel_pmdemand_init(struct intel_display *display);
24void intel_pmdemand_init_pmdemand_params(struct intel_display *display,
25 struct intel_pmdemand_state *pmdemand_state);
26void intel_pmdemand_update_port_clock(struct intel_display *display,
27 struct intel_pmdemand_state *pmdemand_state,
28 enum pipe pipe, int port_clock);
29void intel_pmdemand_update_phys_mask(struct intel_display *display,
30 struct intel_encoder *encoder,
31 struct intel_pmdemand_state *pmdemand_state,
32 bool clear_bit);
33void intel_pmdemand_program_dbuf(struct intel_display *display,
34 u8 dbuf_slices);
35void intel_pmdemand_pre_plane_update(struct intel_atomic_state *state);
36void intel_pmdemand_post_plane_update(struct intel_atomic_state *state);
37int intel_pmdemand_atomic_check(struct intel_atomic_state *state);
38
39#endif /* __INTEL_PMDEMAND_H__ */
40