/Linux-v5.10/drivers/net/ipa/ |
D | ipa_main.c | 22 #include "ipa.h" 38 * This driver supports the Qualcomm IP Accelerator (IPA), which is a 39 * networking component found in many Qualcomm SoCs. The IPA is connected 43 * The IPA is the conduit between the AP and the modem that carries network 47 * The IPA provides protocol checksum calculation, offloading this work 48 * from the AP. The IPA offers additional functionality, including routing, 54 * There are two distinct layers that implement the IPA hardware, and this 56 * interface (GSI) is an integral component of the IPA, providing a 57 * well-defined communication layer between the AP subsystem and the IPA 59 * between the AP and the IPA. [all …]
|
D | ipa_mem.c | 15 #include "ipa.h" 33 struct ipa *ipa = container_of(trans->gsi, struct ipa, gsi); in ipa_mem_zero_region_add() local 34 dma_addr_t addr = ipa->zero_addr; in ipa_mem_zero_region_add() 43 * ipa_mem_setup() - Set up IPA AP and modem shared memory areas 44 * @ipa: IPA pointer 46 * Set up the shared memory regions in IPA local memory. This involves 48 * the IPA where it's located. 58 int ipa_mem_setup(struct ipa *ipa) in ipa_mem_setup() argument 60 dma_addr_t addr = ipa->zero_addr; in ipa_mem_setup() 68 trans = ipa_cmd_trans_alloc(ipa, 4); in ipa_mem_setup() [all …]
|
D | ipa_interrupt.c | 7 /* DOC: IPA Interrupts 9 * The IPA has an interrupt line distinct from the interrupt used by the GSI 11 * transfer completions), IPA interrupts are related to other events related 12 * to the IPA. Some of the IPA interrupts come from a microcontroller 13 * embedded in the IPA. Each IPA interrupt type can be both masked and 16 * Two of the IPA interrupts are initiated by the microcontroller. A third 17 * can be generated to signal the need for a wakeup/resume when an IPA 18 * endpoint has been suspended. There are other IPA events, but at this 25 #include "ipa.h" 32 * struct ipa_interrupt - IPA interrupt information [all …]
|
D | ipa_modem.c | 14 #include "ipa.h" 34 /** struct ipa_priv - IPA network device private data */ 36 struct ipa *ipa; member 43 struct ipa *ipa = priv->ipa; in ipa_open() local 46 ret = ipa_endpoint_enable_one(ipa->name_map[IPA_ENDPOINT_AP_MODEM_TX]); in ipa_open() 49 ret = ipa_endpoint_enable_one(ipa->name_map[IPA_ENDPOINT_AP_MODEM_RX]); in ipa_open() 58 ipa_endpoint_disable_one(ipa->name_map[IPA_ENDPOINT_AP_MODEM_TX]); in ipa_open() 67 struct ipa *ipa = priv->ipa; in ipa_stop() local 71 ipa_endpoint_disable_one(ipa->name_map[IPA_ENDPOINT_AP_MODEM_RX]); in ipa_stop() 72 ipa_endpoint_disable_one(ipa->name_map[IPA_ENDPOINT_AP_MODEM_TX]); in ipa_stop() [all …]
|
D | ipa_table.h | 11 struct ipa; 26 * @ipa: IPA pointer 30 bool ipa_table_valid(struct ipa *ipa); 34 * @ipa: IPA pointer 38 bool ipa_filter_map_valid(struct ipa *ipa, u32 filter_mask); 42 static inline bool ipa_table_valid(struct ipa *ipa) in ipa_table_valid() argument 47 static inline bool ipa_filter_map_valid(struct ipa *ipa, u32 filter_mask) in ipa_filter_map_valid() argument 56 * @ipa: IPA pointer 59 void ipa_table_reset(struct ipa *ipa, bool modem); 63 * @ipa: IPA pointer [all …]
|
D | ipa_table.c | 17 #include "ipa.h" 28 * DOC: IPA Filter and Route Tables 30 * The IPA has tables defined in its local shared memory that define filter 39 * Hashed operation is not supported by all IPA hardware. 49 * and so on. Space is set aside in IPA local memory to hold as many 56 * IPA filtering functionality. 58 * IPA Filter Table 77 * though the AP currently does not use the IPA routing functionality. 79 * IPA Route Table 99 /* IPA hardware constrains filter and route tables alignment */ [all …]
|
D | ipa_endpoint.h | 19 struct ipa; 43 * struct ipa_endpoint - IPA endpoint information 48 struct ipa *ipa; member 70 void ipa_endpoint_modem_hol_block_clear_all(struct ipa *ipa); 72 void ipa_endpoint_modem_pause_all(struct ipa *ipa, bool enable); 74 int ipa_endpoint_modem_exception_reset_all(struct ipa *ipa); 86 void ipa_endpoint_suspend(struct ipa *ipa); 87 void ipa_endpoint_resume(struct ipa *ipa); 89 void ipa_endpoint_setup(struct ipa *ipa); 90 void ipa_endpoint_teardown(struct ipa *ipa); [all …]
|
D | ipa_cmd.c | 15 #include "ipa.h" 22 * DOC: IPA Immediate Commands 24 * The AP command TX endpoint is used to issue immediate commands to the IPA. 25 * An immediate command is generally used to request the IPA do something 74 /* For IPA v4.0+, this opcode gets modified with pipeline clear options */ 80 __le16 flags; /* Unused/reserved for IPA v3.5.1 */ 84 __le32 clear_options; /* Unused/reserved for IPA v4.0+ */ 88 /* The next field is present for IPA v4.0 and above */ 90 /* The next field is present for IPA v3.5.1 only */ 93 /* The next field and its values are present for IPA v3.5.1 only */ [all …]
|
D | ipa_endpoint.c | 16 #include "ipa.h" 81 * IPA hardware as a number of KB. We don't use "hard byte in ipa_endpoint_validate_build() 102 static bool ipa_endpoint_data_valid_one(struct ipa *ipa, u32 count, in ipa_endpoint_data_valid_one() argument 107 struct device *dev = &ipa->pdev->dev; in ipa_endpoint_data_valid_one() 183 static bool ipa_endpoint_data_valid(struct ipa *ipa, u32 count, in ipa_endpoint_data_valid() argument 187 struct device *dev = &ipa->pdev->dev; in ipa_endpoint_data_valid() 217 if (!ipa_endpoint_data_valid_one(ipa, count, data, dp)) in ipa_endpoint_data_valid() 225 static bool ipa_endpoint_data_valid(struct ipa *ipa, u32 count, in ipa_endpoint_data_valid() argument 237 struct gsi *gsi = &endpoint->ipa->gsi; in ipa_endpoint_trans_alloc() 247 * Note that suspend is not supported starting with IPA v4.0. [all …]
|
D | ipa_clock.c | 13 #include "ipa.h" 18 * DOC: IPA Clocking 20 * The "IPA Clock" manages both the IPA core clock and the interconnects 21 * (buses) the IPA depends on as a single logical entity. A reference count 26 * all buses at a fixed average and peak bandwidth. As more advanced IPA 29 * An IPA clock reference must be held for any access to IPA hardware. 45 * struct ipa_clock - IPA clocking information 48 * @core: IPA core clock 75 /* Initialize interconnects required for IPA operation */ 114 static int ipa_interconnect_enable(struct ipa *ipa) in ipa_interconnect_enable() argument [all …]
|
D | ipa_uc.c | 11 #include "ipa.h" 16 * DOC: The IPA embedded microcontroller 18 * The IPA incorporates a microcontroller that is able to do some additional 28 * A 128 byte block of structured memory within the IPA SRAM is used together 30 * AP and the IPA microcontroller. Each side writes data to the shared area 63 * A shared memory area at the base of IPA resident memory is used for 117 static struct ipa_uc_mem_area *ipa_uc_shared(struct ipa *ipa) in ipa_uc_shared() argument 119 u32 offset = ipa->mem_offset + ipa->mem[IPA_MEM_UC_SHARED].offset; in ipa_uc_shared() 121 return ipa->mem_virt + offset; in ipa_uc_shared() 124 /* Microcontroller event IPA interrupt handler */ [all …]
|
D | ipa_smp2p.c | 15 #include "ipa.h" 20 * DOC: IPA SMP2P communication with the modem 23 * the modem. The IPA driver uses this for two purposes: to enable the modem 25 * state of the IPA clock in the event of a crash. 29 * latter case, the modem uses an SMP2P interrupt to tell the AP IPA driver 32 * The modem is also able to inquire about the current state of the IPA 37 * is set, and at that time records whether the AP has the IPA clock enabled. 44 * struct ipa_smp2p - IPA SMP2P information 45 * @ipa: IPA pointer 51 * @clock_query_irq: IPA interrupt triggered by modem for clock query [all …]
|
D | ipa_clock.h | 11 struct ipa; 14 * ipa_clock_rate() - Return the current IPA core clock rate 15 * @ipa: IPA structure 19 u32 ipa_clock_rate(struct ipa *ipa); 22 * ipa_clock_init() - Initialize IPA clocking 23 * @dev: IPA device 31 * @clock: IPA clock pointer 36 * ipa_clock_get() - Get an IPA clock reference 37 * @ipa: IPA pointer 41 void ipa_clock_get(struct ipa *ipa); [all …]
|
D | ipa_interrupt.h | 12 struct ipa; 16 * enum ipa_irq_id - IPA interrupt type 32 * typedef ipa_irq_handler_t - IPA interrupt handler function type 33 * @ipa: IPA pointer 37 * IPA interrupt type 39 typedef void (*ipa_irq_handler_t)(struct ipa *ipa, enum ipa_irq_id irq_id); 42 * ipa_interrupt_add() - Register a handler for an IPA interrupt type 43 * @irq_id: IPA interrupt type 46 * Add a handler for an IPA interrupt and enable it. IPA interrupt 54 * ipa_interrupt_remove() - Remove the handler for an IPA interrupt type [all …]
|
D | ipa_qmi.c | 13 #include "ipa.h" 28 * complete, the AP and modem may begin IPA operation. This occurs 29 * only when the AP IPA driver, modem IPA driver, and IPA microcontroller 36 * contains a success result, the AP knows the modem IPA driver is ready. 38 * The modem is responsible for loading firmware on the IPA microcontroller. 53 * - Whenever the AP learns the modem has booted and its IPA QMI service 56 * - On the initial boot, the modem sets up the IPA microcontroller, and 86 struct ipa *ipa = container_of(ipa_qmi, struct ipa, qmi); in ipa_server_init_complete() local 99 dev_err(&ipa->pdev->dev, in ipa_server_init_complete() 118 * We know everything (else) is ready when we know the IPA driver on [all …]
|
D | ipa_smp2p.h | 11 struct ipa; 14 * ipa_smp2p_init() - Initialize the IPA SMP2P subsystem 15 * @ipa: IPA pointer 21 int ipa_smp2p_init(struct ipa *ipa, bool modem_init); 25 * @ipa: IPA pointer 27 void ipa_smp2p_exit(struct ipa *ipa); 30 * ipa_smp2p_disable() - Prevent "ipa-setup-ready" interrupt handling 31 * @IPA: IPA pointer 36 void ipa_smp2p_disable(struct ipa *ipa); 40 * @ipa: IPA pointer [all …]
|
D | ipa_cmd.h | 15 struct ipa; 21 * enum ipa_cmd_opcode: IPA immediate commands 24 * The numeric values here are the opcodes for IPA v3.5.1 hardware. 43 * struct ipa_cmd_info - information needed for an IPA immediate command 58 * @ipa: - IPA pointer 59 * @mem: - IPA memory region descriptor 66 bool ipa_cmd_table_valid(struct ipa *ipa, const struct ipa_mem *mem, 71 * @ipa: - IPA pointer 75 bool ipa_cmd_data_valid(struct ipa *ipa); 79 static inline bool ipa_cmd_table_valid(struct ipa *ipa, in ipa_cmd_table_valid() argument [all …]
|
D | ipa_mem.h | 9 struct ipa; 13 * DOC: IPA Local Memory 15 * The IPA has a block of shared memory, divided into regions used for 19 * the "ipa-shared" memory range) and size found in the IPA_SHARED_MEM_SIZE 25 * of canaries for all IPA hardware versions. Still, the number used is 43 /* IPA-resident memory region ids */ 59 IPA_MEM_PDN_CONFIG, /* 2 canaries (IPA v4.0 and above) */ 60 IPA_MEM_STATS_QUOTA, /* 2 canaries (IPA v4.0 and above) */ 61 IPA_MEM_STATS_TETHERING, /* 0 canaries (IPA v4.0 and above) */ 62 IPA_MEM_STATS_DROP, /* 0 canaries (IPA v4.0 and above) */ [all …]
|
D | ipa_modem.h | 9 struct ipa; 14 int ipa_modem_start(struct ipa *ipa); 15 int ipa_modem_stop(struct ipa *ipa); 22 int ipa_modem_init(struct ipa *ipa, bool modem_init); 23 void ipa_modem_exit(struct ipa *ipa); 25 int ipa_modem_config(struct ipa *ipa); 26 void ipa_modem_deconfig(struct ipa *ipa); 28 int ipa_modem_setup(struct ipa *ipa); 29 void ipa_modem_teardown(struct ipa *ipa);
|
D | ipa.h | 31 * enum ipa_flag - IPA state flags 33 * @IPA_FLAG_COUNT: Number of defined IPA flags 41 * struct ipa - IPA information 44 * @version: IPA hardware version 48 * @clock: IPA clocking information 51 * @interrupt: IPA Interrupt information 53 * @reg_addr: DMA address used for IPA register access 54 * @reg_virt: Virtual address used for IPA register access 55 * @mem_addr: DMA address of IPA-local memory space 56 * @mem_virt: Virtual address of IPA-local memory space [all …]
|
D | ipa_gsi.c | 11 #include "ipa.h" 17 struct ipa *ipa = container_of(trans->gsi, struct ipa, gsi); in ipa_gsi_trans_complete() local 19 ipa_endpoint_trans_complete(ipa->channel_map[trans->channel_id], trans); in ipa_gsi_trans_complete() 24 struct ipa *ipa = container_of(trans->gsi, struct ipa, gsi); in ipa_gsi_trans_release() local 26 ipa_endpoint_trans_release(ipa->channel_map[trans->channel_id], trans); in ipa_gsi_trans_release() 32 struct ipa *ipa = container_of(gsi, struct ipa, gsi); in ipa_gsi_channel_tx_queued() local 35 endpoint = ipa->channel_map[channel_id]; in ipa_gsi_channel_tx_queued() 43 struct ipa *ipa = container_of(gsi, struct ipa, gsi); in ipa_gsi_channel_tx_completed() local 46 endpoint = ipa->channel_map[channel_id]; in ipa_gsi_channel_tx_completed()
|
D | ipa_reg.c | 9 #include "ipa.h" 12 int ipa_reg_init(struct ipa *ipa) in ipa_reg_init() argument 14 struct device *dev = &ipa->pdev->dev; in ipa_reg_init() 17 /* Setup IPA register memory */ in ipa_reg_init() 18 res = platform_get_resource_byname(ipa->pdev, IORESOURCE_MEM, in ipa_reg_init() 19 "ipa-reg"); in ipa_reg_init() 21 dev_err(dev, "DT error getting \"ipa-reg\" memory property\n"); in ipa_reg_init() 25 ipa->reg_virt = ioremap(res->start, resource_size(res)); in ipa_reg_init() 26 if (!ipa->reg_virt) { in ipa_reg_init() 27 dev_err(dev, "unable to remap \"ipa-reg\" memory\n"); in ipa_reg_init() [all …]
|
D | ipa_uc.h | 9 struct ipa; 12 * ipa_uc_setup() - set up the IPA microcontroller subsystem 13 * @ipa: IPA pointer 15 void ipa_uc_setup(struct ipa *ipa); 19 * @ipa: IPA pointer 21 void ipa_uc_teardown(struct ipa *ipa); 25 * @ipa: IPA pointer 30 void ipa_uc_panic_notifier(struct ipa *ipa);
|
D | ipa_data.h | 16 * DOC: IPA/GSI Configuration Data 19 * IPA and GSI resources to use for a given platform. This data is supplied 24 * Resources are data structures used internally by the IPA hardware. The 28 * Endpoint configuration data defines properties of both IPA endpoints and 30 * communication path between the IPA and a particular execution environment 35 * An endpoint is an IPA construct representing a single channel anywhere 36 * in the system. An IPA endpoint ID maps directly to an (EE, channel_id) 39 * added. IPA endpoint and GSI channel configuration data are defined 43 * are common to IPA and GSI (EE ID, channel ID, endpoint ID, and direction); 45 * the IPA endpoint. [all …]
|
/Linux-v5.10/Documentation/devicetree/bindings/net/ |
D | qcom,ipa.yaml | 4 $id: http://devicetree.org/schemas/net/qcom,ipa.yaml# 7 title: Qualcomm IP Accelerator (IPA) 13 This binding describes the Qualcomm IPA. The IPA is capable of offloading 17 The IPA sits between multiple independent "execution environments," 18 including the Application Processor (AP) and the modem. The IPA presents 20 The GSI is an integral part of the IPA, but it is logically isolated 40 | IPA | 46 const: "qcom,sdm845-ipa" 50 - description: IPA registers 51 - description: IPA shared memory [all …]
|