drivers/gpu/drm/amd/display/dc/bios/command_table_helper2.c
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/amd/display/dc/bios/command_table_helper2.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/amd/display/dc/bios/command_table_helper2.c- Extension
.c- Size
- 7622 bytes
- Lines
- 286
- 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.hObjectID.hatomfirmware.hinclude/bios_parser_types.hcommand_table_helper2.h
Detected Declarations
function filesfunction dal_cmd_table_helper_controller_id_to_atom2function dal_cmd_table_helper_transmitter_bp_to_atom2function dal_cmd_table_helper_encoder_mode_bp_to_atom2function dal_cmd_table_helper_clock_source_id_to_ref_clk_src2function dal_cmd_table_helper_encoder_id_to_atom2
Annotated Snippet
#include "dm_services.h"
#include "ObjectID.h"
#include "atomfirmware.h"
#include "include/bios_parser_types.h"
#include "command_table_helper2.h"
bool dal_bios_parser_init_cmd_tbl_helper2(
const struct command_table_helper **h,
enum dce_version dce)
{
switch (dce) {
#if defined(CONFIG_DRM_AMD_DC_SI)
case DCE_VERSION_6_0:
case DCE_VERSION_6_1:
case DCE_VERSION_6_4:
*h = dal_cmd_tbl_helper_dce60_get_table();
return true;
#endif
case DCE_VERSION_8_0:
case DCE_VERSION_8_1:
case DCE_VERSION_8_3:
*h = dal_cmd_tbl_helper_dce80_get_table();
return true;
case DCE_VERSION_10_0:
*h = dal_cmd_tbl_helper_dce110_get_table();
return true;
case DCE_VERSION_11_0:
*h = dal_cmd_tbl_helper_dce110_get_table();
return true;
case DCE_VERSION_11_2:
case DCE_VERSION_11_22:
case DCE_VERSION_12_0:
case DCE_VERSION_12_1:
*h = dal_cmd_tbl_helper_dce112_get_table2();
return true;
case DCN_VERSION_1_0:
case DCN_VERSION_1_01:
case DCN_VERSION_2_0:
case DCN_VERSION_2_1:
case DCN_VERSION_2_01:
case DCN_VERSION_3_0:
case DCN_VERSION_3_01:
case DCN_VERSION_3_02:
case DCN_VERSION_3_03:
case DCN_VERSION_3_1:
case DCN_VERSION_3_14:
case DCN_VERSION_3_15:
case DCN_VERSION_3_16:
case DCN_VERSION_3_2:
case DCN_VERSION_3_21:
case DCN_VERSION_3_5:
case DCN_VERSION_3_51:
case DCN_VERSION_3_6:
case DCN_VERSION_4_01:
case DCN_VERSION_4_2:
case DCN_VERSION_4_2B:
*h = dal_cmd_tbl_helper_dce112_get_table2();
return true;
default:
*h = dal_cmd_tbl_helper_dce112_get_table2();
return false;
}
}
/* real implementations */
bool dal_cmd_table_helper_controller_id_to_atom2(
enum controller_id id,
uint8_t *atom_id)
{
if (atom_id == NULL) {
BREAK_TO_DEBUGGER();
return false;
}
switch (id) {
case CONTROLLER_ID_D0:
*atom_id = ATOM_CRTC1;
return true;
case CONTROLLER_ID_D1:
*atom_id = ATOM_CRTC2;
return true;
Annotation
- Immediate include surface: `dm_services.h`, `ObjectID.h`, `atomfirmware.h`, `include/bios_parser_types.h`, `command_table_helper2.h`.
- Detected declarations: `function files`, `function dal_cmd_table_helper_controller_id_to_atom2`, `function dal_cmd_table_helper_transmitter_bp_to_atom2`, `function dal_cmd_table_helper_encoder_mode_bp_to_atom2`, `function dal_cmd_table_helper_clock_source_id_to_ref_clk_src2`, `function dal_cmd_table_helper_encoder_id_to_atom2`.
- 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.