summaryrefstree
path: root/kernel/techpack/display/msm/sde/sde_hw_rc.h
blob: 9cf3e6c5523536b6d00cc4c7ca4417b0922f2fe5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
/* SPDX-License-Identifier: GPL-2.0-only */
/*
 * Copyright (c) 2020, The Linux Foundation. All rights reserved.
 */

#ifndef _SDE_HW_RC_H
#define _SDE_HW_RC_H

#include "sde_hw_mdss.h"


/**
 * sde_hw_rc_init -  Initialize RC internal state object and ops
 * @hw_dspp: DSPP instance.
 * Return: 0 on success, non-zero otherwise.
 */
int sde_hw_rc_init(struct sde_hw_dspp *hw_dspp);

/**
 * sde_hw_rc_check_mask -  Validate RC mask configuration
 * @hw_dspp: DSPP instance.
 * @cfg: Pointer to configuration blob.
 * Return: 0 on success, non-zero otherwise.
 */
int sde_hw_rc_check_mask(struct sde_hw_dspp *hw_dspp, void *cfg);

/**
 * sde_hw_rc_setup_mask -  Setup RC mask configuration
 * @hw_dspp: DSPP instance.
 * @cfg: Pointer to configuration blob.
 * Return: 0 on success, non-zero otherwise.
 */
int sde_hw_rc_setup_mask(struct sde_hw_dspp *hw_dspp, void *cfg);

/**
 * sde_hw_rc_check_pu_roi -  Validate RC partial update region of interest
 * @hw_dspp: DSPP instance.
 * @cfg: Pointer to configuration blob.
 * Return: 0 on success.
 *         > 0 on early return.
 *         < 0 on error.
 */
int sde_hw_rc_check_pu_roi(struct sde_hw_dspp *hw_dspp, void *cfg);

/**
 * sde_hw_rc_setup_pu_roi -  Setup RC partial update region of interest
 * @hw_dspp: DSPP instance.
 * @cfg: Pointer to configuration blob.
 * Return: 0 on success.
 *         > 0 on early return.
 *         < 0 on error.
 */
int sde_hw_rc_setup_pu_roi(struct sde_hw_dspp *hw_dspp, void *cfg);

/**
 * sde_hw_rc_setup_data_ahb - Program mask data with AHB
 * @hw_dspp: DSPP instance.
 * @cfg: Pointer to configuration blob.
 * Return: 0 on success, non-zero otherwise.
 */
int sde_hw_rc_setup_data_ahb(struct sde_hw_dspp *hw_dspp, void *cfg);

/**
 * sde_hw_rc_setup_data_dma - Program mask data with DMA
 * @hw_dspp: DSPP instance.
 * @cfg: Pointer to configuration blob.
 * Return: 0 on success, non-zero otherwise.
 */
int sde_hw_rc_setup_data_dma(struct sde_hw_dspp *hw_dspp, void *cfg);

#endif