2 * Copyright (C) 2017 The Linux Foundation. All rights reserved.
4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms of the GNU General Public License version 2 as published by
6 * the Free Software Foundation.
8 * This program is distributed in the hope that it will be useful, but WITHOUT
9 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
10 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
13 * You should have received a copy of the GNU General Public License along with
14 * this program. If not, see <http://www.gnu.org/licenses/>.
20 /* represents a hw Layer Mixer, one (or more) is dynamically assigned to a crtc */
21 struct mdp5_hw_mixer {
26 int lm; /* the LM instance # */
31 uint32_t flush_mask; /* used to commit LM registers */
34 /* global atomic state of assignment between CRTCs and Layer Mixers: */
35 struct mdp5_hw_mixer_state {
36 struct drm_crtc *hwmixer_to_crtc[8];
39 struct mdp5_hw_mixer *mdp5_mixer_init(const struct mdp5_lm_instance *lm);
40 void mdp5_mixer_destroy(struct mdp5_hw_mixer *lm);
41 int mdp5_mixer_assign(struct drm_atomic_state *s, struct drm_crtc *crtc,
42 uint32_t caps, struct mdp5_hw_mixer **mixer,
43 struct mdp5_hw_mixer **r_mixer);
44 void mdp5_mixer_release(struct drm_atomic_state *s,
45 struct mdp5_hw_mixer *mixer);
47 #endif /* __MDP5_LM_H__ */