Home
last modified time | relevance | path

Searched refs:ipa (Results 1 – 25 of 42) sorted by relevance

12

/drivers/net/ipa/
Dipa_main.c95 int ipa_setup(struct ipa *ipa) in ipa_setup() argument
99 struct device *dev = &ipa->pdev->dev; in ipa_setup()
102 ret = gsi_setup(&ipa->gsi); in ipa_setup()
106 ret = ipa_power_setup(ipa); in ipa_setup()
110 ipa_endpoint_setup(ipa); in ipa_setup()
115 command_endpoint = ipa->name_map[IPA_ENDPOINT_AP_COMMAND_TX]; in ipa_setup()
120 ret = ipa_mem_setup(ipa); /* No matching teardown required */ in ipa_setup()
124 ret = ipa_table_setup(ipa); /* No matching teardown required */ in ipa_setup()
131 exception_endpoint = ipa->name_map[IPA_ENDPOINT_AP_LAN_RX]; in ipa_setup()
136 ipa_endpoint_default_route_set(ipa, exception_endpoint->endpoint_id); in ipa_setup()
[all …]
Dipa_mem.c29 const struct ipa_mem *ipa_mem_find(struct ipa *ipa, enum ipa_mem_id mem_id) in ipa_mem_find() argument
33 for (i = 0; i < ipa->mem_count; i++) { in ipa_mem_find()
34 const struct ipa_mem *mem = &ipa->mem[i]; in ipa_mem_find()
47 struct ipa *ipa = container_of(trans->gsi, struct ipa, gsi); in ipa_mem_zero_region_add() local
48 const struct ipa_mem *mem = ipa_mem_find(ipa, mem_id); in ipa_mem_zero_region_add()
49 dma_addr_t addr = ipa->zero_addr; in ipa_mem_zero_region_add()
75 int ipa_mem_setup(struct ipa *ipa) in ipa_mem_setup() argument
77 dma_addr_t addr = ipa->zero_addr; in ipa_mem_setup()
87 trans = ipa_cmd_trans_alloc(ipa, 4); in ipa_mem_setup()
89 dev_err(&ipa->pdev->dev, "no transaction for memory setup\n"); in ipa_mem_setup()
[all …]
Dipa_modem.c43 struct ipa *ipa; member
51 struct ipa *ipa = priv->ipa; in ipa_open() local
55 dev = &ipa->pdev->dev; in ipa_open()
60 ret = ipa_endpoint_enable_one(ipa->name_map[IPA_ENDPOINT_AP_MODEM_TX]); in ipa_open()
64 ret = ipa_endpoint_enable_one(ipa->name_map[IPA_ENDPOINT_AP_MODEM_RX]); in ipa_open()
76 ipa_endpoint_disable_one(ipa->name_map[IPA_ENDPOINT_AP_MODEM_TX]); in ipa_open()
87 struct ipa *ipa = priv->ipa; in ipa_stop() local
91 dev = &ipa->pdev->dev; in ipa_stop()
98 ipa_endpoint_disable_one(ipa->name_map[IPA_ENDPOINT_AP_MODEM_RX]); in ipa_stop()
99 ipa_endpoint_disable_one(ipa->name_map[IPA_ENDPOINT_AP_MODEM_TX]); in ipa_stop()
[all …]
Dipa_table.c149 ipa_table_valid_one(struct ipa *ipa, enum ipa_mem_id mem_id, bool route) in ipa_table_valid_one() argument
151 const struct ipa_mem *mem = ipa_mem_find(ipa, mem_id); in ipa_table_valid_one()
152 struct device *dev = &ipa->pdev->dev; in ipa_table_valid_one()
160 if (!ipa_cmd_table_valid(ipa, mem, route)) in ipa_table_valid_one()
168 if (ipa_table_hash_support(ipa) && !mem->size) in ipa_table_valid_one()
178 bool ipa_table_valid(struct ipa *ipa) in ipa_table_valid() argument
182 valid = ipa_table_valid_one(ipa, IPA_MEM_V4_FILTER, false); in ipa_table_valid()
183 valid = valid && ipa_table_valid_one(ipa, IPA_MEM_V6_FILTER, false); in ipa_table_valid()
184 valid = valid && ipa_table_valid_one(ipa, IPA_MEM_V4_ROUTE, true); in ipa_table_valid()
185 valid = valid && ipa_table_valid_one(ipa, IPA_MEM_V6_ROUTE, true); in ipa_table_valid()
[all …]
Dipa_interrupt.c39 struct ipa *ipa; member
55 struct ipa *ipa = interrupt->ipa; in ipa_interrupt_process() local
62 offset = ipa_reg_irq_clr_offset(ipa->version); in ipa_interrupt_process()
64 iowrite32(mask, ipa->reg_virt + offset); in ipa_interrupt_process()
67 interrupt->handler[irq_id](interrupt->ipa, irq_id); in ipa_interrupt_process()
74 iowrite32(mask, ipa->reg_virt + offset); in ipa_interrupt_process()
81 struct ipa *ipa = interrupt->ipa; in ipa_isr_thread() local
89 dev = &ipa->pdev->dev; in ipa_isr_thread()
98 offset = ipa_reg_irq_stts_offset(ipa->version); in ipa_isr_thread()
99 pending = ioread32(ipa->reg_virt + offset); in ipa_isr_thread()
[all …]
Dipa_uc.c118 static struct ipa_uc_mem_area *ipa_uc_shared(struct ipa *ipa) in ipa_uc_shared() argument
120 const struct ipa_mem *mem = ipa_mem_find(ipa, IPA_MEM_UC_SHARED); in ipa_uc_shared()
121 u32 offset = ipa->mem_offset + mem->offset; in ipa_uc_shared()
123 return ipa->mem_virt + offset; in ipa_uc_shared()
127 static void ipa_uc_event_handler(struct ipa *ipa, enum ipa_irq_id irq_id) in ipa_uc_event_handler() argument
129 struct ipa_uc_mem_area *shared = ipa_uc_shared(ipa); in ipa_uc_event_handler()
130 struct device *dev = &ipa->pdev->dev; in ipa_uc_event_handler()
141 static void ipa_uc_response_hdlr(struct ipa *ipa, enum ipa_irq_id irq_id) in ipa_uc_response_hdlr() argument
143 struct ipa_uc_mem_area *shared = ipa_uc_shared(ipa); in ipa_uc_response_hdlr()
144 struct device *dev = &ipa->pdev->dev; in ipa_uc_response_hdlr()
[all …]
Dipa_power.c159 static int ipa_interconnect_enable(struct ipa *ipa) in ipa_interconnect_enable() argument
162 struct ipa_power *power = ipa->power; in ipa_interconnect_enable()
172 dev_err(&ipa->pdev->dev, in ipa_interconnect_enable()
190 static int ipa_interconnect_disable(struct ipa *ipa) in ipa_interconnect_disable() argument
193 struct ipa_power *power = ipa->power; in ipa_interconnect_disable()
194 struct device *dev = &ipa->pdev->dev; in ipa_interconnect_disable()
217 static int ipa_power_enable(struct ipa *ipa) in ipa_power_enable() argument
221 ret = ipa_interconnect_enable(ipa); in ipa_power_enable()
225 ret = clk_prepare_enable(ipa->power->core); in ipa_power_enable()
227 dev_err(&ipa->pdev->dev, "error %d enabling core clock\n", ret); in ipa_power_enable()
[all …]
Dipa_endpoint.c78 static bool ipa_endpoint_data_valid_one(struct ipa *ipa, u32 count, in ipa_endpoint_data_valid_one() argument
83 struct device *dev = &ipa->pdev->dev; in ipa_endpoint_data_valid_one()
167 static bool ipa_endpoint_data_valid(struct ipa *ipa, u32 count, in ipa_endpoint_data_valid() argument
171 struct device *dev = &ipa->pdev->dev; in ipa_endpoint_data_valid()
193 limit = aggr_byte_limit_max(ipa->version) * SZ_1K; in ipa_endpoint_data_valid()
220 if (!ipa_endpoint_data_valid_one(ipa, count, data, dp)) in ipa_endpoint_data_valid()
230 struct gsi *gsi = &endpoint->ipa->gsi; in ipa_endpoint_trans_alloc()
246 struct ipa *ipa = endpoint->ipa; in ipa_endpoint_init_ctrl() local
255 WARN_ON(ipa->version == IPA_VERSION_4_2); in ipa_endpoint_init_ctrl()
257 WARN_ON(ipa->version >= IPA_VERSION_4_0); in ipa_endpoint_init_ctrl()
[all …]
Dipa_endpoint.h19 struct ipa;
74 struct ipa *ipa; member
95 void ipa_endpoint_modem_hol_block_clear_all(struct ipa *ipa);
97 void ipa_endpoint_modem_pause_all(struct ipa *ipa, bool enable);
99 int ipa_endpoint_modem_exception_reset_all(struct ipa *ipa);
109 void ipa_endpoint_suspend(struct ipa *ipa);
110 void ipa_endpoint_resume(struct ipa *ipa);
112 void ipa_endpoint_setup(struct ipa *ipa);
113 void ipa_endpoint_teardown(struct ipa *ipa);
115 int ipa_endpoint_config(struct ipa *ipa);
[all …]
Dipa_qmi.c86 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()
128 struct ipa *ipa = container_of(ipa_qmi, struct ipa, qmi); in ipa_qmi_ready() local
148 ipa = container_of(ipa_qmi, struct ipa, qmi); in ipa_qmi_ready()
149 ret = ipa_modem_start(ipa); in ipa_qmi_ready()
151 dev_err(&ipa->pdev->dev, "error %d starting modem\n", ret); in ipa_qmi_ready()
186 struct ipa *ipa; in ipa_server_indication_register() local
190 ipa = container_of(ipa_qmi, struct ipa, qmi); in ipa_server_indication_register()
202 dev_err(&ipa->pdev->dev, in ipa_server_indication_register()
215 struct ipa *ipa; in ipa_server_driver_init_complete() local
[all …]
Dipa_cmd.c175 bool ipa_cmd_table_valid(struct ipa *ipa, const struct ipa_mem *mem, bool route) in ipa_cmd_table_valid() argument
180 struct device *dev = &ipa->pdev->dev; in ipa_cmd_table_valid()
193 ipa->mem_offset > offset_max - mem->offset) { in ipa_cmd_table_valid()
196 ipa->mem_offset, mem->offset, offset_max); in ipa_cmd_table_valid()
202 if (mem->offset > ipa->mem_size || in ipa_cmd_table_valid()
203 mem->size > ipa->mem_size - mem->offset) { in ipa_cmd_table_valid()
206 mem->offset, mem->size, ipa->mem_size); in ipa_cmd_table_valid()
215 static bool ipa_cmd_header_valid(struct ipa *ipa) in ipa_cmd_header_valid() argument
217 struct device *dev = &ipa->pdev->dev; in ipa_cmd_header_valid()
235 mem = ipa_mem_find(ipa, IPA_MEM_MODEM_HEADER); in ipa_cmd_header_valid()
[all …]
Dipa_table.h11 struct ipa;
28 bool ipa_table_valid(struct ipa *ipa);
37 bool ipa_filter_map_valid(struct ipa *ipa, u32 filter_mask);
43 static inline bool ipa_table_hash_support(struct ipa *ipa) in ipa_table_hash_support() argument
45 return ipa->version != IPA_VERSION_4_2; in ipa_table_hash_support()
53 void ipa_table_reset(struct ipa *ipa, bool modem);
59 int ipa_table_hash_flush(struct ipa *ipa);
67 int ipa_table_setup(struct ipa *ipa);
75 void ipa_table_config(struct ipa *ipa);
81 int ipa_table_init(struct ipa *ipa);
[all …]
Dipa_sysfs.c14 static const char *ipa_version_string(struct ipa *ipa) in ipa_version_string() argument
16 switch (ipa->version) { in ipa_version_string()
47 struct ipa *ipa = dev_get_drvdata(dev); in version_show() local
49 return scnprintf(buf, PAGE_SIZE, "%s\n", ipa_version_string(ipa)); in version_show()
63 static const char *ipa_offload_string(struct ipa *ipa) in ipa_offload_string() argument
65 return ipa->version < IPA_VERSION_4_5 ? "MAPv4" : "MAPv5"; in ipa_offload_string()
71 struct ipa *ipa = dev_get_drvdata(dev); in rx_offload_show() local
73 return scnprintf(buf, PAGE_SIZE, "%s\n", ipa_offload_string(ipa)); in rx_offload_show()
81 struct ipa *ipa = dev_get_drvdata(dev); in tx_offload_show() local
83 return scnprintf(buf, PAGE_SIZE, "%s\n", ipa_offload_string(ipa)); in tx_offload_show()
[all …]
Dipa_smp2p.c61 struct ipa *ipa; member
94 dev = &smp2p->ipa->pdev->dev; in ipa_smp2p_notify()
130 ipa_uc_panic_notifier(smp2p->ipa); in ipa_smp2p_panic_notifier()
159 if (smp2p->ipa->setup_complete) in ipa_smp2p_modem_setup_ready_isr()
163 dev = &smp2p->ipa->pdev->dev; in ipa_smp2p_modem_setup_ready_isr()
171 ret = ipa_setup(smp2p->ipa); in ipa_smp2p_modem_setup_ready_isr()
185 struct device *dev = &smp2p->ipa->pdev->dev; in ipa_smp2p_irq_init()
189 ret = platform_get_irq_byname(smp2p->ipa->pdev, name); in ipa_smp2p_irq_init()
209 static void ipa_smp2p_power_release(struct ipa *ipa) in ipa_smp2p_power_release() argument
211 struct device *dev = &ipa->pdev->dev; in ipa_smp2p_power_release()
[all …]
Dipa_power.h11 struct ipa;
23 u32 ipa_core_clock_rate(struct ipa *ipa);
29 void ipa_power_modem_queue_stop(struct ipa *ipa);
35 void ipa_power_modem_queue_wake(struct ipa *ipa);
41 void ipa_power_modem_queue_active(struct ipa *ipa);
48 void ipa_power_retention(struct ipa *ipa, bool enable);
56 int ipa_power_setup(struct ipa *ipa);
62 void ipa_power_teardown(struct ipa *ipa);
Dipa_mem.h9 struct ipa;
92 const struct ipa_mem *ipa_mem_find(struct ipa *ipa, enum ipa_mem_id mem_id);
94 int ipa_mem_config(struct ipa *ipa);
95 void ipa_mem_deconfig(struct ipa *ipa);
97 int ipa_mem_setup(struct ipa *ipa); /* No ipa_mem_teardown() needed */
99 int ipa_mem_zero_modem(struct ipa *ipa);
101 int ipa_mem_init(struct ipa *ipa, const struct ipa_mem_data *mem_data);
102 void ipa_mem_exit(struct ipa *ipa);
Dipa_gsi.c17 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()
Dipa_modem.h9 struct ipa;
13 int ipa_modem_start(struct ipa *ipa);
14 int ipa_modem_stop(struct ipa *ipa);
21 int ipa_modem_init(struct ipa *ipa, bool modem_init);
22 void ipa_modem_exit(struct ipa *ipa);
24 int ipa_modem_config(struct ipa *ipa);
25 void ipa_modem_deconfig(struct ipa *ipa);
Dipa_resource.c29 static bool ipa_resource_limits_valid(struct ipa *ipa, in ipa_resource_limits_valid() argument
72 ipa_resource_config_common(struct ipa *ipa, u32 offset, in ipa_resource_config_common() argument
85 iowrite32(val, ipa->reg_virt + offset); in ipa_resource_config_common()
88 static void ipa_resource_config_src(struct ipa *ipa, u32 resource_type, in ipa_resource_config_src() argument
100 ipa_resource_config_common(ipa, offset, &resource->limits[0], ylimits); in ipa_resource_config_src()
107 ipa_resource_config_common(ipa, offset, &resource->limits[2], ylimits); in ipa_resource_config_src()
114 ipa_resource_config_common(ipa, offset, &resource->limits[4], ylimits); in ipa_resource_config_src()
121 ipa_resource_config_common(ipa, offset, &resource->limits[6], ylimits); in ipa_resource_config_src()
124 static void ipa_resource_config_dst(struct ipa *ipa, u32 resource_type, in ipa_resource_config_dst() argument
136 ipa_resource_config_common(ipa, offset, &resource->limits[0], ylimits); in ipa_resource_config_dst()
[all …]
Dipa_reg.c12 int ipa_reg_init(struct ipa *ipa) in ipa_reg_init() argument
14 struct device *dev = &ipa->pdev->dev; in ipa_reg_init()
18 res = platform_get_resource_byname(ipa->pdev, IORESOURCE_MEM, 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()
30 ipa->reg_addr = res->start; in ipa_reg_init()
35 void ipa_reg_exit(struct ipa *ipa) in ipa_reg_exit() argument
37 iounmap(ipa->reg_virt); in ipa_reg_exit()
Dipa_uc.h9 struct ipa;
15 void ipa_uc_config(struct ipa *ipa);
21 void ipa_uc_deconfig(struct ipa *ipa);
35 void ipa_uc_power(struct ipa *ipa);
44 void ipa_uc_panic_notifier(struct ipa *ipa);
Dipa_smp2p.h11 struct ipa;
21 int ipa_smp2p_init(struct ipa *ipa, bool modem_init);
27 void ipa_smp2p_exit(struct ipa *ipa);
35 void ipa_smp2p_irq_disable_setup(struct ipa *ipa);
45 void ipa_smp2p_notify_reset(struct ipa *ipa);
Dipa_interrupt.h12 struct ipa;
23 typedef void (*ipa_irq_handler_t)(struct ipa *ipa, enum ipa_irq_id irq_id);
94 void ipa_interrupt_irq_enable(struct ipa *ipa);
102 void ipa_interrupt_irq_disable(struct ipa *ipa);
110 struct ipa_interrupt *ipa_interrupt_config(struct ipa *ipa);
Dipa_cmd.h15 struct ipa;
68 bool ipa_cmd_table_valid(struct ipa *ipa, const struct ipa_mem *mem,
77 bool ipa_cmd_data_valid(struct ipa *ipa);
164 void ipa_cmd_pipeline_clear_wait(struct ipa *ipa);
174 struct gsi_trans *ipa_cmd_trans_alloc(struct ipa *ipa, u32 tre_count);
Dipa_qmi.h12 struct ipa;
56 int ipa_qmi_setup(struct ipa *ipa);
62 void ipa_qmi_teardown(struct ipa *ipa);

12