Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\kernel\tboot.c Create Date:2022-07-28 07:53:16
Last Modify:2022-05-22 06:45:44 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:tboot_sleep

Proto:static int tboot_sleep(u8 sleep_state, unsigned int pm1a_control, unsigned int pm1b_control)

Type:int

Parameter:

TypeParameterName
u8sleep_state
unsigned intpm1a_control
unsigned intpm1b_control
274  static unsigned int acpi_shutdown_map[6] = { - 1, - 1, - 1, TB_SHUTDOWN_S3, TB_SHUTDOWN_S4, TB_SHUTDOWN_S5}
280  If Not tboot_enabled() Then Return 0
283  tboot_copy_fadt( & acpi_gbl_FADT)
284  pm1a_cnt_val = pm1a_control
285  pm1b_cnt_val = pm1b_control
287  vector_width = 32
289  If sleep_state >= ACPI_S_STATE_COUNT || acpi_shutdown_map[sleep_state] == -1 Then
291  pr_warn("unsupported sleep state 0x%x\n", sleep_state)
292  Return -1
295  tboot_shutdown(acpi_shutdown_map[sleep_state])
296  Return 0