36 #ifndef __MHAL_MBOX_H__
37 #define __MHAL_MBOX_H__
39 #include <mhal_osai.h>
107 #define MBOX_EDEFAULT 1
111 #define MBOX_EEMPTY 3
Get 'enable software interrupt' mask.
Definition: mhal_mbox.h:183
u32 ne_sts
Status: FIFO Non-Empty interrupt.
Definition: mhal_mbox.h:268
int enable
Software interrupt enable/disable.
Definition: mhal_mbox.h:227
Control software interrupt.
Definition: mhal_mbox.h:185
mbox_transfer_type
User should specify the transfer type when reading/writing FIFO.
Definition: mhal_mbox.h:152
enum mbox_int_type type
FIFO interrupt type.
Definition: mhal_mbox.h:235
Clear FIFO interrupt.
Definition: mhal_mbox.h:198
u32 nf_sts
Status: FIFO Non-Full interrupt.
Definition: mhal_mbox.h:263
SEM CM4 LOCK.
Definition: mhal_mbox.h:144
Only write/read cmd to/from FIFO.
Definition: mhal_mbox.h:154
enum mbox_ioctl_type mbox_ioctl_t
Users should specify the ioctl type when setting/getting information to/from MBOX HW...
Get FIFO interrupt status.
Definition: mhal_mbox.h:196
int mtk_mhal_mbox_fifo_write(void __iomem *base, const struct mbox_fifo_item *buf, mbox_tr_type_t type)
This function is used to write data to MBOX channel FIFO.
FIFO Write interrupt.
Definition: mhal_mbox.h:130
FIFO Read interrupt.
Definition: mhal_mbox.h:134
Invalid State.
Definition: mhal_mbox.h:148
Meaningless transfer type.
Definition: mhal_mbox.h:158
mbox_ioctl_type
Users should specify the ioctl type when setting/getting information to/from MBOX HW...
Definition: mhal_mbox.h:164
Clear software interrupt.
Definition: mhal_mbox.h:189
u32 channel
MBOX channel.
Definition: mhal_mbox.h:248
mbox_sem_status
Semaphore status, only used between CA7 and CM4.
Definition: mhal_mbox.h:140
Release sema.
Definition: mhal_mbox.h:174
enum mbox_transfer_type mbox_tr_type_t
User should specify the transfer type when reading/writing FIFO.
Get read FIFO count(CMD FIFO).
Definition: mhal_mbox.h:203
Set FIFO Non-Full threshold.
Definition: mhal_mbox.h:170
Trigger software interrupt.
Definition: mhal_mbox.h:179
u32 wr_int
Status: Write FIFO interrupt.
Definition: mhal_mbox.h:258
FIFO Non-Full interrupt.
Definition: mhal_mbox.h:132
Invalid.
Definition: mhal_mbox.h:136
Enable FIFO interrupt.
Definition: mhal_mbox.h:192
u32 id
Software interrupt id.
Definition: mhal_mbox.h:229
Acquire sema.
Definition: mhal_mbox.h:176
SEM UNLOCK.
Definition: mhal_mbox.h:142
Get FIFO Non-Empty threshold.
Definition: mhal_mbox.h:168
Set FIFO Non-Empty threshold.
Definition: mhal_mbox.h:166
u32 data
The data written to/read from MBOX FIFO.
Definition: mhal_mbox.h:219
u32 channel
MBOX channel.
Definition: mhal_mbox.h:274
int mtk_mhal_mbox_fifo_read(void __iomem *base, struct mbox_fifo_item *buf, mbox_tr_type_t type)
This function is used to read MBOX channel FIFO data.
int mtk_mhal_mbox_ioctl(void __iomem *base, mbox_ioctl_t ctrl, void *arg)
Control various hardware settings of MBOX.
FIFO Non-Empty interrupt.
Definition: mhal_mbox.h:128
Write/read both data and cmd to/from FIFO.
Definition: mhal_mbox.h:156
Enable software interrupt.
Definition: mhal_mbox.h:181
Get software interrupt status.
Definition: mhal_mbox.h:187
u32 rd_int
Status: Read FIFO interrupt.
Definition: mhal_mbox.h:253
Get FIFO Non-Full threshold.
Definition: mhal_mbox.h:172
Software interrupt information.
Definition: mhal_mbox.h:272
Get write FIFO count(CMD FIFO).
Definition: mhal_mbox.h:201
Get 'enable FIFO interrupt' mask.
Definition: mhal_mbox.h:194
To enable/disable FIFO interrupt specified by type.
Definition: mhal_mbox.h:233
FIFO interrupt status information or enable mask.
Definition: mhal_mbox.h:246
SEM CA7 LOCK.
Definition: mhal_mbox.h:146
u32 cmd
The cmd written to/read from MBOX FIFO.
Definition: mhal_mbox.h:221
The data and cmd written to/read from MBOX FIFO.
Definition: mhal_mbox.h:217
u32 swint_sts
Software interrupt status.
Definition: mhal_mbox.h:276
int mtk_mhal_mbox_reset(void __iomem *base)
This function is used to reset MBOX channel.
mbox_int_type
FIFO interrupt type.
Definition: mhal_mbox.h:126
u32 enable
FIFO interrupt enable/disable.
Definition: mhal_mbox.h:237
To enable/disable software interrupt specified by id.
Definition: mhal_mbox.h:225