drivers/gpu/drm/amd/display/dc/dm_services.h
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/amd/display/dc/dm_services.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/amd/display/dc/dm_services.h- Extension
.h- Size
- 10076 bytes
- Lines
- 310
- Domain
- Driver Families
- Bucket
- drivers/gpu
- Inferred role
- Driver Families: implementation source
- Status
- source implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
dm_services_types.hlogger_interface.hlink_service_types.h
Detected Declarations
struct dmub_srvstruct dc_dmub_srvstruct persistent_data_flagfunction dm_read_index_regfunction dm_write_index_regfunction get_reg_field_value_exfunction set_reg_field_value_exfunction dm_get_timestamp
Annotated Snippet
struct persistent_data_flag {
bool save_per_link;
bool save_per_edid;
};
bool dm_query_extended_brightness_caps
(struct dc_context *ctx, enum dm_acpi_display_type display,
struct dm_acpi_atif_backlight_caps *pCaps);
bool dm_dmcu_set_pipe(struct dc_context *ctx, unsigned int controller_id);
/*
*
* print-out services
*
*/
#define dm_log_to_buffer(buffer, size, fmt, args)\
vsnprintf(buffer, size, fmt, args)
static inline unsigned long long dm_get_timestamp(struct dc_context *ctx)
{
return ktime_get_raw_ns();
}
unsigned long long dm_get_elapse_time_in_ns(struct dc_context *ctx,
unsigned long long current_time_stamp,
unsigned long long last_time_stamp);
/*
* performance tracing
*/
void dm_perf_trace_timestamp(const char *func_name, unsigned int line, struct dc_context *ctx);
#define PERF_TRACE() dm_perf_trace_timestamp(__func__, __LINE__, CTX)
#define PERF_TRACE_CTX(__CTX) dm_perf_trace_timestamp(__func__, __LINE__, __CTX)
/*
* SMU message tracing
*/
void dm_trace_smu_enter(uint32_t msg_id, uint32_t param_in, unsigned int delay, struct dc_context *ctx);
void dm_trace_smu_exit(bool success, uint32_t response, struct dc_context *ctx);
#define TRACE_SMU_MSG_DELAY(msg_id, param_in, delay, ctx) dm_trace_smu_enter(msg_id, param_in, delay, ctx)
#define TRACE_SMU_MSG(msg_id, param_in, ctx) dm_trace_smu_enter(msg_id, param_in, 0, ctx)
#define TRACE_SMU_MSG_ENTER(msg_id, param_in, ctx) dm_trace_smu_enter(msg_id, param_in, 0, ctx)
#define TRACE_SMU_MSG_EXIT(success, response, ctx) dm_trace_smu_exit(success, response, ctx)
/*
* DMUB Interfaces
*/
bool dm_execute_dmub_cmd(const struct dc_context *ctx, union dmub_rb_cmd *cmd, enum dm_dmub_wait_type wait_type);
bool dm_execute_dmub_cmd_list(const struct dc_context *ctx, unsigned int count, union dmub_rb_cmd *cmd, enum dm_dmub_wait_type wait_type);
/*
* ACPI Interfaces
*/
void dm_acpi_process_phy_transition_interlock(
const struct dc_context *ctx,
struct dm_process_phy_transition_init_params process_phy_transition_init_params);
/*
* Debug and verification hooks
*/
void dm_dtn_log_begin(struct dc_context *ctx,
struct dc_log_buffer_ctx *log_ctx);
void dm_dtn_log_append_v(struct dc_context *ctx,
struct dc_log_buffer_ctx *log_ctx,
const char *msg, ...);
void dm_dtn_log_end(struct dc_context *ctx,
struct dc_log_buffer_ctx *log_ctx);
char *dce_version_to_string(const int version);
bool dc_supports_vrr(const enum dce_version v);
#endif /* __DM_SERVICES_H__ */
Annotation
- Immediate include surface: `dm_services_types.h`, `logger_interface.h`, `link_service_types.h`.
- Detected declarations: `struct dmub_srv`, `struct dc_dmub_srv`, `struct persistent_data_flag`, `function dm_read_index_reg`, `function dm_write_index_reg`, `function get_reg_field_value_ex`, `function set_reg_field_value_ex`, `function dm_get_timestamp`.
- Atlas domain: Driver Families / drivers/gpu.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.