drivers/acpi/acpica/dbxface.c
Source file repositories/reference/linux-study-clean/drivers/acpi/acpica/dbxface.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/acpi/acpica/dbxface.c- Extension
.c- Size
- 13652 bytes
- Lines
- 523
- Domain
- Driver Families
- Bucket
- drivers/acpi
- Inferred role
- Driver Families: exported/initcall integration point
- Status
- integration 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.
- Exports symbols or registers init work; inspect boot/module ordering and who consumes the exported contract.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
acpi/acpi.haccommon.hamlcode.hacdebug.hacinterp.hacparser.h
Detected Declarations
function acpi_db_start_commandfunction acpi_db_signal_break_pointfunction acpi_db_single_stepfunction acpi_initialize_debuggerfunction acpi_terminate_debuggerfunction acpi_set_debugger_thread_id
Annotated Snippet
if (ACPI_FAILURE(status)) {
goto error_exit;
}
/* Wait the readiness of the command */
status = acpi_os_wait_command_ready();
if (ACPI_FAILURE(status)) {
goto error_exit;
}
status =
acpi_db_command_dispatch(acpi_gbl_db_line_buf, walk_state,
op);
}
/* acpi_ut_acquire_mutex (ACPI_MTX_NAMESPACE); */
error_exit:
if (ACPI_FAILURE(status) && status != AE_CTRL_TERMINATE) {
ACPI_EXCEPTION((AE_INFO, status,
"While parsing/handling command line"));
}
return (status);
}
/*******************************************************************************
*
* FUNCTION: acpi_db_signal_break_point
*
* PARAMETERS: walk_state - Current walk
*
* RETURN: Status
*
* DESCRIPTION: Called for AML_BREAKPOINT_OP
*
******************************************************************************/
void acpi_db_signal_break_point(struct acpi_walk_state *walk_state)
{
#ifndef ACPI_APPLICATION
if (acpi_gbl_db_thread_id != acpi_os_get_thread_id()) {
return;
}
#endif
/*
* Set the single-step flag. This will cause the debugger (if present)
* to break to the console within the AML debugger at the start of the
* next AML instruction.
*/
acpi_gbl_cm_single_step = TRUE;
acpi_os_printf("**break** Executed AML BreakPoint opcode\n");
}
#ifdef ACPI_DISASSEMBLER
/*******************************************************************************
*
* FUNCTION: acpi_db_get_display_op
*
* PARAMETERS: walk_state - Current walk
* op - Current executing op (from aml interpreter)
*
* RETURN: Opcode to display
*
* DESCRIPTION: Find the opcode to display during single stepping
*
******************************************************************************/
static union acpi_parse_object *acpi_db_get_display_op(struct acpi_walk_state
*walk_state,
union acpi_parse_object
*op)
{
union acpi_parse_object *display_op;
union acpi_parse_object *parent_op;
display_op = op;
parent_op = op->common.parent;
if (parent_op) {
if ((walk_state->control_state) &&
(walk_state->control_state->common.state ==
ACPI_CONTROL_PREDICATE_EXECUTING)) {
/*
* We are executing the predicate of an IF or WHILE statement
* Search upwards for the containing IF or WHILE so that the
* entire predicate can be displayed.
*/
while (parent_op) {
Annotation
- Immediate include surface: `acpi/acpi.h`, `accommon.h`, `amlcode.h`, `acdebug.h`, `acinterp.h`, `acparser.h`.
- Detected declarations: `function acpi_db_start_command`, `function acpi_db_signal_break_point`, `function acpi_db_single_step`, `function acpi_initialize_debugger`, `function acpi_terminate_debugger`, `function acpi_set_debugger_thread_id`.
- Atlas domain: Driver Families / drivers/acpi.
- Implementation status: integration 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.