brintos

brintos / linux-shallow public Read only

0
0
Text · 1.4 KiB · e6346c0 Raw
42 lines · c
1// SPDX-License-Identifier: MIT2//3// Copyright 2024 Advanced Micro Devices, Inc.4 5#ifndef _DMUB_REPLAY_H_6#define _DMUB_REPLAY_H_7 8#include "dc_types.h"9#include "dmub_cmd.h"10struct dc_link;11struct dmub_replay_funcs;12 13struct dmub_replay {14	struct dc_context *ctx;15	const struct dmub_replay_funcs *funcs;16};17 18struct dmub_replay_funcs {19	void (*replay_get_state)(struct dmub_replay *dmub, enum replay_state *state,20		uint8_t panel_inst);21	void (*replay_enable)(struct dmub_replay *dmub, bool enable, bool wait,22		uint8_t panel_inst);23	bool (*replay_copy_settings)(struct dmub_replay *dmub, struct dc_link *link,24		struct replay_context *replay_context, uint8_t panel_inst);25	void (*replay_set_power_opt)(struct dmub_replay *dmub, unsigned int power_opt,26		uint8_t panel_inst);27	void (*replay_send_cmd)(struct dmub_replay *dmub,28		enum replay_FW_Message_type msg, union dmub_replay_cmd_set *cmd_element);29	void (*replay_set_coasting_vtotal)(struct dmub_replay *dmub, uint32_t coasting_vtotal,30		uint8_t panel_inst);31	void (*replay_residency)(struct dmub_replay *dmub,32		uint8_t panel_inst, uint32_t *residency, const bool is_start, const enum pr_residency_mode mode);33	void (*replay_set_power_opt_and_coasting_vtotal)(struct dmub_replay *dmub,34		unsigned int power_opt, uint8_t panel_inst, uint32_t coasting_vtotal);35};36 37struct dmub_replay *dmub_replay_create(struct dc_context *ctx);38void dmub_replay_destroy(struct dmub_replay **dmub);39 40 41#endif /* _DMUB_REPLAY_H_ */42