Sound Open Firmware
Loading...
Searching...
No Matches
mailbox.h
Go to the documentation of this file.
1/* SPDX-License-Identifier: BSD-3-Clause
2 *
3 * Copyright(c) 2020 Intel Corporation. All rights reserved.
4 *
5 * Author: Adrian Bonislawski <adrian.bonislawski@linux.intel.com>
6 */
7
14#ifndef __KERNEL_MAILBOX_H__
15#define __KERNEL_MAILBOX_H__
16
17#if CONFIG_IPC_MAJOR_4
18#include <ipc4/fw_reg.h>
19#endif
20
25#if CONFIG_IPC_MAJOR_4
26#define SRAM_REG_FW_STATUS offsetof(struct ipc4_fw_registers, fsr)
27#define SRAM_REG_LAST_ERROR_CODE offsetof(struct ipc4_fw_registers, lec)
28#define SRAM_REG_FW_PWR_STATUS offsetof(struct ipc4_fw_registers, fps)
29#define SRAM_REG_LNEC offsetof(struct ipc4_fw_registers, lnec)
30#define SRAM_REG_LTR offsetof(struct ipc4_fw_registers, ltr)
31#define SRAM_REG_ROM_INFO offsetof(struct ipc4_fw_registers, rom_info)
32#define SRAM_REG_ABI_VER offsetof(struct ipc4_fw_registers, abi_ver)
33#define SRAM_REG_SLAVE_CORE_STS offsetof(struct ipc4_fw_registers, slave_core_sts)
34#define SRAM_REG_PIPELINE_REGS offsetof(struct ipc4_fw_registers, pipeline_regs)
35#define SRAM_REG_PEAK_VOL_REGS offsetof(struct ipc4_fw_registers, peak_vol_regs)
36#define SRAM_REG_LLP_GPDMA_READING_SLOTS offsetof(struct ipc4_fw_registers, llp_gpdma_reading_slots)
37#define SRAM_REG_LLP_SNDW_READING_SLOTS offsetof(struct ipc4_fw_registers, llp_sndw_reading_slots)
38#define SRAM_REG_LLP_EVAD_SLOTS offsetof(struct ipc4_fw_registers, llp_evad_reading_slot)
39#define SRAM_REG_FW_END sizeof(struct ipc4_fw_registers)
40#else /* CONFIG_IPC_MAJOR_4 */
41#define SRAM_REG_ROM_STATUS 0x0
42#define SRAM_REG_FW_STATUS 0x4
43#define SRAM_REG_FW_TRACEP 0x8
44#define SRAM_REG_FW_IPC_RECEIVED_COUNT 0xc
45#define SRAM_REG_FW_IPC_PROCESSED_COUNT 0x10
46#define SRAM_REG_FW_TRACEP_SECONDARY_CORE_BASE 0x14
47#define SRAM_REG_FW_TRACEP_SECONDARY_CORE_1 SRAM_REG_FW_TRACEP_SECONDARY_CORE_BASE
48#define SRAM_REG_FW_TRACEP_SECONDARY_CORE_2 0x18
49#define SRAM_REG_FW_TRACEP_SECONDARY_CORE_3 0x1C
50#define SRAM_REG_FW_TRACEP_SECONDARY_CORE_4 0x20
51#define SRAM_REG_FW_TRACEP_SECONDARY_CORE_5 0x24
52#define SRAM_REG_FW_TRACEP_SECONDARY_CORE_6 0x28
53#define SRAM_REG_FW_TRACEP_SECONDARY_CORE_7 0x2C
54#define SRAM_REG_R_STATE_TRACE_BASE 0x30
55#define SRAM_REG_R0_STATE_TRACE SRAM_REG_R_STATE_TRACE_BASE
56#define SRAM_REG_R1_STATE_TRACE 0x38
57#define SRAM_REG_R2_STATE_TRACE 0x40
58#define SRAM_REG_FW_END (SRAM_REG_R2_STATE_TRACE + 0x8)
59#endif
60
63#endif /* __KERNEL_MAILBOX_H__ */
IPC4 firmware registers in mailbox window 0 for host telemetry and status.