summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Documentation/devicetree/bindings/net/airoha,en7581-npu.yaml21
-rw-r--r--drivers/net/ethernet/airoha/airoha_npu.c8
2 files changed, 19 insertions, 10 deletions
diff --git a/Documentation/devicetree/bindings/net/airoha,en7581-npu.yaml b/Documentation/devicetree/bindings/net/airoha,en7581-npu.yaml
index 59c57f58116b..19860b41286f 100644
--- a/Documentation/devicetree/bindings/net/airoha,en7581-npu.yaml
+++ b/Documentation/devicetree/bindings/net/airoha,en7581-npu.yaml
@@ -42,14 +42,13 @@ properties:
- description: wlan irq line5
memory-region:
- oneOf:
- - items:
- - description: NPU firmware binary region
- - items:
- - description: NPU firmware binary region
- - description: NPU wlan offload RX buffers region
- - description: NPU wlan offload TX buffers region
- - description: NPU wlan offload TX packet identifiers region
+ items:
+ - description: NPU firmware binary region
+ - description: NPU wlan offload RX buffers region
+ - description: NPU wlan offload TX buffers region
+ - description: NPU wlan offload TX packet identifiers region
+ - description: NPU wlan Block Ack buffers region
+ minItems: 1
memory-region-names:
items:
@@ -57,6 +56,8 @@ properties:
- const: pkt
- const: tx-pkt
- const: tx-bufid
+ - const: ba
+ minItems: 1
required:
- compatible
@@ -93,7 +94,7 @@ examples:
<GIC_SPI 122 IRQ_TYPE_LEVEL_HIGH>,
<GIC_SPI 123 IRQ_TYPE_LEVEL_HIGH>;
memory-region = <&npu_firmware>, <&npu_pkt>, <&npu_txpkt>,
- <&npu_txbufid>;
- memory-region-names = "firmware", "pkt", "tx-pkt", "tx-bufid";
+ <&npu_txbufid>, <&npu_ba>;
+ memory-region-names = "firmware", "pkt", "tx-pkt", "tx-bufid", "ba";
};
};
diff --git a/drivers/net/ethernet/airoha/airoha_npu.c b/drivers/net/ethernet/airoha/airoha_npu.c
index 22f72c146065..a56b3780bb62 100644
--- a/drivers/net/ethernet/airoha/airoha_npu.c
+++ b/drivers/net/ethernet/airoha/airoha_npu.c
@@ -519,6 +519,14 @@ static int airoha_npu_wlan_init_memory(struct airoha_npu *npu)
if (err)
return err;
+ if (of_property_match_string(npu->dev->of_node, "memory-region-names",
+ "ba") >= 0) {
+ cmd = WLAN_FUNC_SET_WAIT_DRAM_BA_NODE_ADDR;
+ err = airoha_npu_wlan_set_reserved_memory(npu, 0, "ba", cmd);
+ if (err)
+ return err;
+ }
+
cmd = WLAN_FUNC_SET_WAIT_IS_FORCE_TO_CPU;
return airoha_npu_wlan_msg_send(npu, 0, cmd, &val, sizeof(val),
GFP_KERNEL);