@@ -103,28 +103,6 @@ struct ipa_cmd_ip_packet_init {
103103/* Field masks for ipa_cmd_ip_packet_init dest_endpoint field */
104104#define IPA_PACKET_INIT_DEST_ENDPOINT_FMASK GENMASK(4, 0)
105105
106- /* IPA_CMD_DMA_TASK_32B_ADDR */
107-
108- /* This opcode gets modified with a DMA operation count */
109-
110- #define DMA_TASK_32B_ADDR_OPCODE_COUNT_FMASK GENMASK(15, 8)
111-
112- struct ipa_cmd_hw_dma_task_32b_addr {
113- __le16 flags ;
114- __le16 size ;
115- __le32 addr ;
116- __le16 packet_size ;
117- u8 reserved [6 ];
118- };
119-
120- /* Field masks for ipa_cmd_hw_dma_task_32b_addr flags field */
121- #define DMA_TASK_32B_ADDR_FLAGS_SW_RSVD_FMASK GENMASK(10, 0)
122- #define DMA_TASK_32B_ADDR_FLAGS_CMPLT_FMASK GENMASK(11, 11)
123- #define DMA_TASK_32B_ADDR_FLAGS_EOF_FMASK GENMASK(12, 12)
124- #define DMA_TASK_32B_ADDR_FLAGS_FLSH_FMASK GENMASK(13, 13)
125- #define DMA_TASK_32B_ADDR_FLAGS_LOCK_FMASK GENMASK(14, 14)
126- #define DMA_TASK_32B_ADDR_FLAGS_UNLOCK_FMASK GENMASK(15, 15)
127-
128106/* IPA_CMD_DMA_SHARED_MEM */
129107
130108/* For IPA v4.0+, this opcode gets modified with pipeline clear options */
@@ -163,7 +141,6 @@ union ipa_cmd_payload {
163141 struct ipa_cmd_hw_hdr_init_local hdr_init_local ;
164142 struct ipa_cmd_register_write register_write ;
165143 struct ipa_cmd_ip_packet_init ip_packet_init ;
166- struct ipa_cmd_hw_dma_task_32b_addr dma_task_32b_addr ;
167144 struct ipa_cmd_hw_dma_mem_mem dma_shared_mem ;
168145 struct ipa_cmd_ip_packet_tag_status ip_packet_tag_status ;
169146};
@@ -508,42 +485,6 @@ static void ipa_cmd_ip_packet_init_add(struct gsi_trans *trans, u8 endpoint_id)
508485 direction , opcode );
509486}
510487
511- /* Use a 32-bit DMA command to zero a block of memory */
512- void ipa_cmd_dma_task_32b_addr_add (struct gsi_trans * trans , u16 size ,
513- dma_addr_t addr , bool toward_ipa )
514- {
515- struct ipa * ipa = container_of (trans -> gsi , struct ipa , gsi );
516- enum ipa_cmd_opcode opcode = IPA_CMD_DMA_TASK_32B_ADDR ;
517- struct ipa_cmd_hw_dma_task_32b_addr * payload ;
518- union ipa_cmd_payload * cmd_payload ;
519- enum dma_data_direction direction ;
520- dma_addr_t payload_addr ;
521- u16 flags ;
522-
523- /* assert(addr <= U32_MAX); */
524- addr &= GENMASK_ULL (31 , 0 );
525-
526- /* The opcode encodes the number of DMA operations in the high byte */
527- opcode |= u16_encode_bits (1 , DMA_TASK_32B_ADDR_OPCODE_COUNT_FMASK );
528-
529- direction = toward_ipa ? DMA_TO_DEVICE : DMA_FROM_DEVICE ;
530-
531- /* complete: 0 = don't interrupt; eof: 0 = don't assert eot */
532- flags = DMA_TASK_32B_ADDR_FLAGS_FLSH_FMASK ;
533- /* lock: 0 = don't lock endpoint; unlock: 0 = don't unlock */
534-
535- cmd_payload = ipa_cmd_payload_alloc (ipa , & payload_addr );
536- payload = & cmd_payload -> dma_task_32b_addr ;
537-
538- payload -> flags = cpu_to_le16 (flags );
539- payload -> size = cpu_to_le16 (size );
540- payload -> addr = cpu_to_le32 ((u32 )addr );
541- payload -> packet_size = cpu_to_le16 (size );
542-
543- gsi_trans_cmd_add (trans , payload , sizeof (* payload ), payload_addr ,
544- direction , opcode );
545- }
546-
547488/* Use a DMA command to read or write a block of IPA-resident memory */
548489void ipa_cmd_dma_shared_mem_add (struct gsi_trans * trans , u32 offset , u16 size ,
549490 dma_addr_t addr , bool toward_ipa )
0 commit comments