| 1 | /* SPDX-License-Identifier: MIT */ |
| 2 | /* |
| 3 | * Copyright © 2020 Intel Corporation |
| 4 | */ |
| 5 | |
| 6 | #ifndef _SKL_UNIVERSAL_PLANE_H_ |
| 7 | #define _SKL_UNIVERSAL_PLANE_H_ |
| 8 | |
| 9 | #include <linux/types.h> |
| 10 | |
| 11 | struct intel_crtc; |
| 12 | struct intel_display; |
| 13 | struct intel_initial_plane_config; |
| 14 | struct intel_plane_state; |
| 15 | struct skl_ddb_entry; |
| 16 | struct skl_wm_level; |
| 17 | |
| 18 | enum pipe; |
| 19 | enum plane_id; |
| 20 | |
| 21 | struct intel_plane * |
| 22 | skl_universal_plane_create(struct intel_display *display, |
| 23 | enum pipe pipe, enum plane_id plane_id); |
| 24 | |
| 25 | void skl_get_initial_plane_config(struct intel_crtc *crtc, |
| 26 | struct intel_initial_plane_config *plane_config); |
| 27 | bool skl_fixup_initial_plane_config(struct intel_crtc *crtc, |
| 28 | const struct intel_initial_plane_config *plane_config); |
| 29 | |
| 30 | int skl_format_to_fourcc(int format, bool rgb_order, bool alpha); |
| 31 | |
| 32 | int skl_calc_main_surface_offset(const struct intel_plane_state *plane_state, |
| 33 | int *x, int *y, u32 *offset); |
| 34 | |
| 35 | void icl_link_nv12_planes(struct intel_plane_state *uv_plane_state, |
| 36 | struct intel_plane_state *y_plane_state); |
| 37 | |
| 38 | bool icl_is_nv12_y_plane(struct intel_display *display, |
| 39 | enum plane_id plane_id); |
| 40 | u8 icl_hdr_plane_mask(void); |
| 41 | bool icl_is_hdr_plane(struct intel_display *display, enum plane_id plane_id); |
| 42 | |
| 43 | u32 skl_plane_aux_dist(const struct intel_plane_state *plane_state, |
| 44 | int color_plane); |
| 45 | |
| 46 | #endif |
| 47 | |