summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/xe/xe_guc_pc_types.h
blob: 2afd0dbc354268cadf9ca66c4984862c57a4a924 (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
/* SPDX-License-Identifier: MIT */
/*
 * Copyright © 2022 Intel Corporation
 */

#ifndef _XE_GUC_PC_TYPES_H_
#define _XE_GUC_PC_TYPES_H_

#include <linux/mutex.h>
#include <linux/types.h>

/**
 * struct xe_guc_pc - GuC Power Conservation (PC)
 */
struct xe_guc_pc {
	/** @bo: GGTT buffer object that is shared with GuC PC */
	struct xe_bo *bo;
	/** @rp0_freq: HW RP0 frequency - The Maximum one */
	u32 rp0_freq;
	/** @rpe_freq: HW RPe frequency - The Efficient one */
	u32 rpe_freq;
	/** @rpn_freq: HW RPN frequency - The Minimum one */
	u32 rpn_freq;
	/** @user_requested_min: Stash the minimum requested freq by user */
	u32 user_requested_min;
	/** @user_requested_max: Stash the maximum requested freq by user */
	u32 user_requested_max;
	/** @freq_lock: Let's protect the frequencies */
	struct mutex freq_lock;
	/** @freq_ready: Only handle freq changes, if they are really ready */
	bool freq_ready;
};

#endif	/* _XE_GUC_PC_TYPES_H_ */