mirror of
https://github.com/torvalds/linux.git
synced 2026-06-01 19:13:47 +02:00
wifi: mt76: connac: rework macros for unified command
Rework some macros for connac3 unified command. This is a preliminary patch to add mt7996 chipset support. Signed-off-by: Peter Chiu <chui-hao.chiu@mediatek.com> Signed-off-by: Shayne Chen <shayne.chen@mediatek.com> Signed-off-by: Felix Fietkau <nbd@nbd.name>
This commit is contained in:
parent
41ac53c899
commit
4c07129b05
|
|
@ -63,7 +63,7 @@ struct mt76_connac2_mcu_txd {
|
|||
} __packed __aligned(4);
|
||||
|
||||
/**
|
||||
* struct mt76_connac2_mcu_uni_txd - mcu command descriptor for firmware v3
|
||||
* struct mt76_connac2_mcu_uni_txd - mcu command descriptor for connac2 and connac3
|
||||
* @txd: hardware descriptor
|
||||
* @len: total length not including txd
|
||||
* @cid: command identifier
|
||||
|
|
@ -1079,10 +1079,11 @@ enum {
|
|||
|
||||
#define MCU_CMD_ACK BIT(0)
|
||||
#define MCU_CMD_UNI BIT(1)
|
||||
#define MCU_CMD_QUERY BIT(2)
|
||||
#define MCU_CMD_SET BIT(2)
|
||||
|
||||
#define MCU_CMD_UNI_EXT_ACK (MCU_CMD_ACK | MCU_CMD_UNI | \
|
||||
MCU_CMD_QUERY)
|
||||
MCU_CMD_SET)
|
||||
#define MCU_CMD_UNI_QUERY_ACK (MCU_CMD_ACK | MCU_CMD_UNI)
|
||||
|
||||
#define __MCU_CMD_FIELD_ID GENMASK(7, 0)
|
||||
#define __MCU_CMD_FIELD_EXT_ID GENMASK(15, 8)
|
||||
|
|
@ -1090,6 +1091,7 @@ enum {
|
|||
#define __MCU_CMD_FIELD_UNI BIT(17)
|
||||
#define __MCU_CMD_FIELD_CE BIT(18)
|
||||
#define __MCU_CMD_FIELD_WA BIT(19)
|
||||
#define __MCU_CMD_FIELD_WM BIT(20)
|
||||
|
||||
#define MCU_CMD(_t) FIELD_PREP(__MCU_CMD_FIELD_ID, \
|
||||
MCU_CMD_##_t)
|
||||
|
|
@ -1111,6 +1113,16 @@ enum {
|
|||
FIELD_PREP(__MCU_CMD_FIELD_EXT_ID, \
|
||||
MCU_WA_PARAM_CMD_##_t))
|
||||
|
||||
#define MCU_WM_UNI_CMD(_t) (MCU_UNI_CMD(_t) | \
|
||||
__MCU_CMD_FIELD_WM)
|
||||
#define MCU_WM_UNI_CMD_QUERY(_t) (MCU_UNI_CMD(_t) | \
|
||||
__MCU_CMD_FIELD_QUERY | \
|
||||
__MCU_CMD_FIELD_WM)
|
||||
#define MCU_WA_UNI_CMD(_t) (MCU_UNI_CMD(_t) | \
|
||||
__MCU_CMD_FIELD_WA)
|
||||
#define MCU_WMWA_UNI_CMD(_t) (MCU_WM_UNI_CMD(_t) | \
|
||||
__MCU_CMD_FIELD_WA)
|
||||
|
||||
enum {
|
||||
MCU_EXT_CMD_EFUSE_ACCESS = 0x01,
|
||||
MCU_EXT_CMD_RF_REG_ACCESS = 0x02,
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user