xref: /wlan-dirver/qca-wifi-host-cmn/qdf/inc/qdf_ipa.h (revision 6ecd284e5a94a1c96e26d571dd47419ac305990d)
1 /*
2  * Copyright (c) 2017-2018, The Linux Foundation. All rights reserved.
3  *
4  * Permission to use, copy, modify, and/or distribute this software for any
5  * purpose with or without fee is hereby granted, provided that the above
6  * copyright notice and this permission notice appear in all copies.
7  *
8  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10  * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
13  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
14  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15  */
16 
17 #ifndef _QDF_IPA_H
18 #define _QDF_IPA_H
19 
20 #ifdef IPA_OFFLOAD
21 
22 #include <i_qdf_ipa.h>
23 
24 /**
25  * enum qdf_ipa_wlan_event - QDF IPA events
26  * @QDF_IPA_CLIENT_CONNECT: Client Connects
27  * @QDF_IPA_CLIENT_DISCONNECT: Client Disconnects
28  * @QDF_IPA_AP_CONNECT: SoftAP is started
29  * @QDF_IPA_AP_DISCONNECT: SoftAP is stopped
30  * @QDF_IPA_STA_CONNECT: STA associates to AP
31  * @QDF_IPA_STA_DISCONNECT: STA dissociates from AP
32  * @QDF_IPA_CLIENT_CONNECT_EX: Peer associates/re-associates to softap
33  * @QDF_SWITCH_TO_SCC: WLAN interfaces in scc mode
34  * @QDF_SWITCH_TO_MCC: WLAN interfaces in mcc mode
35  * @QDF_WDI_ENABLE: WDI enable complete
36  * @QDF_WDI_DISABLE: WDI teardown
37  * @QDF_IPA_WLAN_EVENT_MAX: Max value for the enum
38  */
39 typedef enum {
40 	QDF_IPA_CLIENT_CONNECT,
41 	QDF_IPA_CLIENT_DISCONNECT,
42 	QDF_IPA_AP_CONNECT,
43 	QDF_IPA_AP_DISCONNECT,
44 	QDF_IPA_STA_CONNECT,
45 	QDF_IPA_STA_DISCONNECT,
46 	QDF_IPA_CLIENT_CONNECT_EX,
47 	QDF_SWITCH_TO_SCC,
48 	QDF_SWITCH_TO_MCC,
49 	QDF_WDI_ENABLE,
50 	QDF_WDI_DISABLE,
51 	QDF_IPA_WLAN_EVENT_MAX
52 } qdf_ipa_wlan_event;
53 
54 /**
55  * qdf_ipa_wdi_meter_evt_type_t - type of event client callback is
56  * for AP+STA mode metering
57  * @IPA_GET_WDI_SAP_STATS: get IPA_stats betwen SAP and STA -
58  *			use ipa_get_wdi_sap_stats structure
59  * @IPA_SET_WIFI_QUOTA: set quota limit on STA -
60  *			use ipa_set_wifi_quota structure
61  */
62 typedef __qdf_ipa_wdi_meter_evt_type_t qdf_ipa_wdi_meter_evt_type_t;
63 
64 typedef __qdf_ipa_get_wdi_sap_stats_t qdf_ipa_get_wdi_sap_stats_t;
65 
66 /**
67  * qdf_ipa_set_wifi_quota_t - structure used for
68  *                                   IPA_SET_WIFI_QUOTA.
69  */
70 typedef __qdf_ipa_set_wifi_quota_t qdf_ipa_set_wifi_quota_t;
71 
72 /**
73  * qdf_ipa_connect_params_t - low-level client connect input parameters. Either
74  * client allocates the data and desc FIFO and specifies that in data+desc OR
75  * specifies sizes and pipe_mem pref and IPA does the allocation.
76  */
77 typedef __qdf_ipa_connect_params_t qdf_ipa_connect_params_t;
78 
79 /**
80  * qdf_ipa_tx_meta_t - meta-data for the TX packet
81  */
82 typedef __qdf_ipa_tx_meta_t qdf_ipa_tx_meta_t;
83 
84 /**
85  *  __qdf_ipa_sps_params_t - SPS related output parameters resulting from
86  */
87 typedef __qdf_ipa_sps_params_t qdf_ipa_sps_params_t;
88 
89 /**
90  * qdf_ipa_tx_intf_t - interface tx properties
91  */
92 typedef __qdf_ipa_tx_intf_t qdf_ipa_tx_intf_t;
93 
94 /**
95  * qdf_ipa_rx_intf_t - interface rx properties
96  */
97 typedef __qdf_ipa_rx_intf_t qdf_ipa_rx_intf_t;
98 
99 /**
100  * qdf_ipa_ext_intf_t - interface ext properties
101  */
102 typedef __qdf_ipa_ext_intf_t qdf_ipa_ext_intf_t;
103 
104 /**
105  * qdf_ipa_sys_connect_params_t - information needed to setup an IPA end-point
106  * in system-BAM mode
107  */
108 typedef __qdf_ipa_sys_connect_params_t qdf_ipa_sys_connect_params_t;
109 
110 /**
111  * __qdf_pa_rm_event_t - IPA RM events
112  *
113  * Indicate the resource state change
114  */
115 typedef __qdf_ipa_rm_event_t qdf_ipa_rm_event_t;
116 
117 /**
118  * struct qdf_ipa_rm_register_params_t - information needed to
119  *      register IPA RM client with IPA RM
120  */
121 typedef __qdf_ipa_rm_register_params_t qdf_ipa_rm_register_params_t;
122 
123 /**
124  * struct qdf_ipa_rm_create_params_t - information needed to initialize
125  *				the resource
126  *
127  * IPA RM client is expected to perform non blocking operations only
128  * in request_resource and release_resource functions and
129  * release notification context as soon as possible.
130  */
131 typedef __qdf_ipa_rm_create_params_t qdf_ipa_rm_create_params_t;
132 
133 /**
134  * qdf_ipa_rm_perf_profile_t - information regarding IPA RM client performance
135  * profile
136  */
137 typedef __qdf_ipa_rm_perf_profile_t qdf_ipa_rm_perf_profile_t;
138 
139 /**
140  * qdf_ipa_tx_data_desc_t - information needed
141  * to send data packet to HW link: link to data descriptors
142  * priv: client specific private data
143  */
144 typedef __qdf_ipa_tx_data_desc_t qdf_ipa_tx_data_desc_t;
145 
146 /**
147  * qdf_ipa_rx_data_t - information needed
148  * to send to wlan driver on receiving data from ipa hw
149  */
150 typedef __qdf_ipa_rx_data_t qdf_ipa_rx_data_t;
151 
152 /**
153  * qdf_ipa_wdi_ul_params_t - WDI_RX configuration
154  */
155 typedef __qdf_ipa_wdi_ul_params_t qdf_ipa_wdi_ul_params_t;
156 
157 /**
158  * qdf_ipa_wdi_ul_params_smmu_t - WDI_RX configuration (with WLAN SMMU)
159  */
160 typedef __qdf_ipa_wdi_ul_params_smmu_t qdf_ipa_wdi_ul_params_smmu_t;
161 
162 /**
163  * qdf_ipa_wdi_dl_params_t - WDI_TX configuration
164  */
165 typedef __qdf_ipa_wdi_dl_params_t qdf_ipa_wdi_dl_params_t;
166 
167 /**
168  * qdf_ipa_wdi_dl_params_smmu_t - WDI_TX configuration (with WLAN SMMU)
169  */
170 typedef __qdf_ipa_wdi_dl_params_smmu_t qdf_ipa_wdi_dl_params_smmu_t;
171 
172 /**
173  * qdf_ipa_wdi_in_params_t - information provided by WDI client
174  */
175 typedef __qdf_ipa_wdi_in_params_t qdf_ipa_wdi_in_params_t;
176 
177 /**
178  * qdf_ipa_wdi_out_params_t - information provided to WDI client
179  */
180 typedef __qdf_ipa_wdi_out_params_t qdf_ipa_wdi_out_params_t;
181 
182 /**
183  * qdf_ipa_wdi_db_params_t - information provided to retrieve
184  *       physical address of uC doorbell
185  */
186 typedef __qdf_ipa_wdi_db_params_t qdf_ipa_wdi_db_params_t;
187 
188 /**
189  * qdf_ipa_wdi_uc_ready_params_t - uC ready CB parameters
190  */
191 typedef void (*qdf_ipa_uc_ready_cb)(void *priv);
192 typedef __qdf_ipa_wdi_uc_ready_params_t qdf_ipa_wdi_uc_ready_params_t;
193 
194 /**
195  * qdf_ipa_wdi_buffer_info_t - address info of a WLAN allocated buffer
196  *
197  * IPA driver will create/release IOMMU mapping in IPA SMMU from iova->pa
198  */
199 typedef __qdf_ipa_wdi_buffer_info_t qdf_ipa_wdi_buffer_info_t;
200 
201 /**
202  * qdf_ipa_gsi_ep_config_t - IPA GSI endpoint configurations
203  */
204 typedef __qdf_ipa_gsi_ep_config_t qdf_ipa_gsi_ep_config_t;
205 
206 /**
207  * qdf_ipa_dp_evt_type_t - type of event client callback is
208  * invoked for on data path
209  * @IPA_RECEIVE: data is struct sk_buff
210  * @IPA_WRITE_DONE: data is struct sk_buff
211  */
212 typedef __qdf_ipa_dp_evt_type_t qdf_ipa_dp_evt_type_t;
213 
214 typedef __qdf_ipa_hdr_add_t qdf_ipa_hdr_add_t;
215 typedef __qdf_ipa_hdr_del_t qdf_ipa_hdr_del_t;
216 typedef __qdf_ipa_ioc_add_hdr_t qdf_ipa_ioc_add_hdr_t;
217 typedef __qdf_ipa_ioc_del_hdr_t qdf_ipa_ioc_del_hdr_t;
218 typedef __qdf_ipa_ioc_get_hdr_t qdf_ipa_ioc_get_hdr_t;
219 typedef __qdf_ipa_ioc_copy_hdr_t qdf_ipa_ioc_copy_hdr_t;
220 typedef __qdf_ipa_ioc_add_hdr_proc_ctx_t qdf_ipa_ioc_add_hdr_proc_ctx_t;
221 typedef __qdf_ipa_ioc_del_hdr_proc_ctx_t qdf_ipa_ioc_del_hdr_proc_ctx_t;
222 typedef __qdf_ipa_msg_meta_t qdf_ipa_msg_meta_t;
223 typedef __qdf_ipa_client_type_t qdf_ipa_client_type_t;
224 typedef __qdf_ipa_hw_stats_wdi_info_data_t qdf_ipa_hw_stats_wdi_info_data_t;
225 typedef __qdf_ipa_rm_resource_name_t  qdf_ipa_rm_resource_name_t;
226 typedef __qdf_ipa_wlan_event_t qdf_ipa_wlan_event_t;
227 typedef __qdf_ipa_wlan_msg_t qdf_ipa_wlan_msg_t;
228 typedef __qdf_ipa_wlan_msg_ex_t qdf_ipa_wlan_msg_ex_t;
229 typedef __qdf_ipa_ioc_tx_intf_prop_t qdf_ipa_ioc_tx_intf_prop_t;
230 typedef __qdf_ipa_ioc_rx_intf_prop_t qdf_ipa_ioc_rx_intf_prop_t;
231 typedef __qdf_ipa_wlan_hdr_attrib_val_t qdf_ipa_wlan_hdr_attrib_val_t;
232 typedef int (*qdf_ipa_msg_pull_fn)(void *buff, u32 len, u32 type);
233 typedef void (*qdf_ipa_ready_cb)(void *user_data);
234 
235 #define QDF_IPA_SET_META_MSG_TYPE(meta, msg_type) \
236 	__QDF_IPA_SET_META_MSG_TYPE(meta, msg_type)
237 
238 #define QDF_IPA_RM_RESOURCE_GRANTED __QDF_IPA_RM_RESOURCE_GRANTED
239 #define QDF_IPA_RM_RESOURCE_RELEASED __QDF_IPA_RM_RESOURCE_RELEASED
240 
241 #define QDF_IPA_VOLTAGE_LEVEL __QDF_IPA_VOLTAGE_LEVEL
242 
243 #define QDF_IPA_RM_RESOURCE_WLAN_PROD __QDF_IPA_RM_RESOURCE_WLAN_PROD
244 #define QDF_IPA_RM_RESOURCE_WLAN_CONS __QDF_IPA_RM_RESOURCE_WLAN_CONS
245 #define QDF_IPA_RM_RESOURCE_APPS_CONS __QDF_IPA_RM_RESOURCE_APPS_CONS
246 
247 #define QDF_IPA_CLIENT_WLAN1_PROD __QDF_IPA_CLIENT_WLAN1_PROD
248 #define QDF_IPA_CLIENT_WLAN2_CONS __QDF_IPA_CLIENT_WLAN2_CONS
249 #define QDF_IPA_CLIENT_WLAN3_CONS __QDF_IPA_CLIENT_WLAN3_CONS
250 #define QDF_IPA_CLIENT_WLAN4_CONS __QDF_IPA_CLIENT_WLAN4_CONS
251 
252 /*
253  * Resume / Suspend
254  */
255 static inline int qdf_ipa_reset_endpoint(u32 clnt_hdl)
256 {
257 	return __qdf_ipa_reset_endpoint(clnt_hdl);
258 }
259 
260 /*
261  * Remove ep delay
262  */
263 static inline int qdf_ipa_clear_endpoint_delay(u32 clnt_hdl)
264 {
265 	return __qdf_ipa_clear_endpoint_delay(clnt_hdl);
266 }
267 
268 /*
269  * Header removal / addition
270  */
271 static inline int qdf_ipa_add_hdr(qdf_ipa_ioc_add_hdr_t *hdrs)
272 {
273 	return __qdf_ipa_add_hdr(hdrs);
274 }
275 
276 static inline int qdf_ipa_del_hdr(qdf_ipa_ioc_del_hdr_t *hdls)
277 {
278 	return __qdf_ipa_del_hdr(hdls);
279 }
280 
281 static inline int qdf_ipa_commit_hdr(void)
282 {
283 	return __qdf_ipa_commit_hdr();
284 }
285 
286 static inline int qdf_ipa_reset_hdr(void)
287 {
288 	return __qdf_ipa_reset_hdr();
289 }
290 
291 static inline int qdf_ipa_get_hdr(qdf_ipa_ioc_get_hdr_t *lookup)
292 {
293 	return __qdf_ipa_get_hdr(lookup);
294 }
295 
296 static inline int qdf_ipa_put_hdr(u32 hdr_hdl)
297 {
298 	return __qdf_ipa_put_hdr(hdr_hdl);
299 }
300 
301 static inline int qdf_ipa_copy_hdr(qdf_ipa_ioc_copy_hdr_t *copy)
302 {
303 	return __qdf_ipa_copy_hdr(copy);
304 }
305 
306 /*
307  * Header Processing Context
308  */
309 static inline int qdf_ipa_add_hdr_proc_ctx(
310 				qdf_ipa_ioc_add_hdr_proc_ctx_t *proc_ctxs)
311 {
312 	return __qdf_ipa_add_hdr_proc_ctx(proc_ctxs);
313 }
314 
315 static inline int qdf_ipa_del_hdr_proc_ctx(qdf_ipa_ioc_del_hdr_proc_ctx_t *hdls)
316 {
317 	return __qdf_ipa_del_hdr_proc_ctx(hdls);
318 }
319 
320 /*
321  * Messaging
322  */
323 static inline int qdf_ipa_send_msg(qdf_ipa_msg_meta_t *meta, void *buff,
324 		ipa_msg_free_fn callback)
325 {
326 	return __qdf_ipa_send_msg(meta, buff, callback);
327 }
328 
329 static inline int qdf_ipa_register_pull_msg(qdf_ipa_msg_meta_t *meta,
330 		qdf_ipa_msg_pull_fn callback)
331 {
332 	return __qdf_ipa_register_pull_msg(meta, callback);
333 }
334 
335 static inline int qdf_ipa_deregister_pull_msg(qdf_ipa_msg_meta_t *meta)
336 {
337 	return __qdf_ipa_deregister_pull_msg(meta);
338 }
339 
340 /*
341  * Interface
342  */
343 static inline int qdf_ipa_register_intf(const char *name,
344 				     const qdf_ipa_tx_intf_t *tx,
345 				     const qdf_ipa_rx_intf_t *rx)
346 {
347 	return __qdf_ipa_register_intf(name, tx, rx);
348 }
349 
350 static inline int qdf_ipa_register_intf_ext(const char *name,
351 		const qdf_ipa_tx_intf_t *tx,
352 		const qdf_ipa_rx_intf_t *rx,
353 		const qdf_ipa_ext_intf_t *ext)
354 {
355 	return __qdf_ipa_register_intf_ext(name, tx, rx, ext);
356 }
357 
358 static inline int qdf_ipa_deregister_intf(const char *name)
359 {
360 	return __qdf_ipa_deregister_intf(name);
361 }
362 
363 /*
364  * Data path
365  */
366 static inline int qdf_ipa_tx_dp(qdf_ipa_client_type_t dst, struct sk_buff *skb,
367 		qdf_ipa_tx_meta_t *metadata)
368 {
369 	return __qdf_ipa_tx_dp(dst, skb, metadata);
370 }
371 
372 /*
373  * To transfer multiple data packets
374  */
375 static inline int qdf_ipa_tx_dp_mul(
376 	qdf_ipa_client_type_t dst,
377 	qdf_ipa_tx_data_desc_t *data_desc)
378 {
379 	return __qdf_ipa_tx_dp_mul(dst, data_desc);
380 }
381 
382 static inline void qdf_ipa_free_skb(qdf_ipa_rx_data_t *rx_in)
383 {
384 	return __qdf_ipa_free_skb(rx_in);;
385 }
386 
387 /*
388  * System pipes
389  */
390 static inline u16 qdf_ipa_get_smem_restr_bytes(void)
391 {
392 	return __qdf_ipa_get_smem_restr_bytes();
393 }
394 
395 static inline int qdf_ipa_setup_sys_pipe(qdf_ipa_sys_connect_params_t *sys_in,
396 		u32 *clnt_hdl)
397 {
398 	return __qdf_ipa_setup_sys_pipe(sys_in, clnt_hdl);
399 }
400 
401 static inline int qdf_ipa_teardown_sys_pipe(u32 clnt_hdl)
402 {
403 	return __qdf_ipa_teardown_sys_pipe(clnt_hdl);
404 }
405 
406 static inline int qdf_ipa_connect_wdi_pipe(qdf_ipa_wdi_in_params_t *in,
407 		qdf_ipa_wdi_out_params_t *out)
408 {
409 	return __qdf_ipa_connect_wdi_pipe(in, out);
410 }
411 
412 static inline int qdf_ipa_disconnect_wdi_pipe(u32 clnt_hdl)
413 {
414 	return __qdf_ipa_disconnect_wdi_pipe(clnt_hdl);
415 }
416 
417 static inline int qdf_ipa_enable_wdi_pipe(u32 clnt_hdl)
418 {
419 	return __qdf_ipa_enable_wdi_pipe(clnt_hdl);
420 }
421 
422 static inline int qdf_ipa_disable_wdi_pipe(u32 clnt_hdl)
423 {
424 	return __qdf_ipa_disable_wdi_pipe(clnt_hdl);
425 }
426 
427 static inline int qdf_ipa_resume_wdi_pipe(u32 clnt_hdl)
428 {
429 	return __qdf_ipa_resume_wdi_pipe(clnt_hdl);
430 }
431 
432 static inline int qdf_ipa_suspend_wdi_pipe(u32 clnt_hdl)
433 {
434 	return __qdf_ipa_suspend_wdi_pipe(clnt_hdl);
435 }
436 
437 static inline int qdf_ipa_uc_wdi_get_dbpa(
438 	qdf_ipa_wdi_db_params_t *out)
439 {
440 	return __qdf_ipa_uc_wdi_get_dbpa(out);
441 }
442 
443 static inline int qdf_ipa_uc_reg_rdyCB(
444 	qdf_ipa_wdi_uc_ready_params_t *param)
445 {
446 	return __qdf_ipa_uc_reg_rdyCB(param);
447 }
448 
449 static inline int qdf_ipa_uc_dereg_rdyCB(void)
450 {
451 	return __qdf_ipa_uc_dereg_rdyCB();
452 }
453 
454 
455 /*
456  * Resource manager
457  */
458 static inline int qdf_ipa_rm_create_resource(
459 		qdf_ipa_rm_create_params_t *create_params)
460 {
461 	return __qdf_ipa_rm_create_resource(create_params);
462 }
463 
464 static inline int qdf_ipa_rm_delete_resource(
465 		qdf_ipa_rm_resource_name_t resource_name)
466 {
467 	return __qdf_ipa_rm_delete_resource(resource_name);
468 }
469 
470 static inline int qdf_ipa_rm_register(qdf_ipa_rm_resource_name_t resource_name,
471 			qdf_ipa_rm_register_params_t *reg_params)
472 {
473 	return __qdf_ipa_rm_register(resource_name, reg_params);
474 }
475 
476 static inline int qdf_ipa_rm_set_perf_profile(
477 		qdf_ipa_rm_resource_name_t resource_name,
478 		qdf_ipa_rm_perf_profile_t *profile)
479 {
480 	return __qdf_ipa_rm_set_perf_profile(resource_name, profile);
481 }
482 
483 static inline int qdf_ipa_rm_deregister(qdf_ipa_rm_resource_name_t resource_name,
484 			qdf_ipa_rm_register_params_t *reg_params)
485 {
486 	return __qdf_ipa_rm_deregister(resource_name, reg_params);
487 }
488 
489 static inline int qdf_ipa_rm_add_dependency(
490 		qdf_ipa_rm_resource_name_t resource_name,
491 		qdf_ipa_rm_resource_name_t depends_on_name)
492 {
493 	return __qdf_ipa_rm_add_dependency(resource_name, depends_on_name);
494 }
495 
496 static inline int qdf_ipa_rm_add_dependency_sync(
497 		qdf_ipa_rm_resource_name_t resource_name,
498 		qdf_ipa_rm_resource_name_t depends_on_name)
499 {
500 	return __qdf_ipa_rm_add_dependency_sync(resource_name, depends_on_name);
501 }
502 
503 static inline int qdf_ipa_rm_delete_dependency(
504 		qdf_ipa_rm_resource_name_t resource_name,
505 		qdf_ipa_rm_resource_name_t depends_on_name)
506 {
507 	return __qdf_ipa_rm_delete_dependency(resource_name, depends_on_name);
508 }
509 
510 static inline int qdf_ipa_rm_request_resource(
511 		qdf_ipa_rm_resource_name_t resource_name)
512 {
513 	return __qdf_ipa_rm_request_resource(resource_name);
514 }
515 
516 static inline int qdf_ipa_rm_release_resource(
517 		qdf_ipa_rm_resource_name_t resource_name)
518 {
519 	return __qdf_ipa_rm_release_resource(resource_name);
520 }
521 
522 static inline int qdf_ipa_rm_notify_completion(qdf_ipa_rm_event_t event,
523 		qdf_ipa_rm_resource_name_t resource_name)
524 {
525 	return __qdf_ipa_rm_notify_completion(event, resource_name);
526 }
527 
528 static inline int qdf_ipa_rm_inactivity_timer_init(
529 		qdf_ipa_rm_resource_name_t resource_name,
530 			unsigned long msecs)
531 {
532 	return __qdf_ipa_rm_inactivity_timer_init(resource_name, msecs);
533 }
534 
535 static inline int qdf_ipa_rm_inactivity_timer_destroy(
536 		qdf_ipa_rm_resource_name_t resource_name)
537 {
538 	return __qdf_ipa_rm_inactivity_timer_destroy(resource_name);
539 }
540 
541 static inline int qdf_ipa_rm_inactivity_timer_request_resource(
542 				qdf_ipa_rm_resource_name_t resource_name)
543 {
544 	return __qdf_ipa_rm_inactivity_timer_request_resource(resource_name);
545 }
546 
547 static inline int qdf_ipa_rm_inactivity_timer_release_resource(
548 				qdf_ipa_rm_resource_name_t resource_name)
549 {
550 	return __qdf_ipa_rm_inactivity_timer_release_resource(resource_name);
551 }
552 
553 /*
554  * Miscellaneous
555  */
556 static inline void qdf_ipa_bam_reg_dump(void)
557 {
558 	return __qdf_ipa_bam_reg_dump();
559 }
560 
561 static inline int qdf_ipa_get_wdi_stats(qdf_ipa_hw_stats_wdi_info_data_t *stats)
562 {
563 	return __qdf_ipa_get_wdi_stats(stats);
564 }
565 
566 static inline int qdf_ipa_get_ep_mapping(qdf_ipa_client_type_t client)
567 {
568 	return __qdf_ipa_get_ep_mapping(client);
569 }
570 
571 static inline bool qdf_ipa_is_ready(void)
572 {
573 	return __qdf_ipa_is_ready();
574 }
575 
576 static inline void qdf_ipa_proxy_clk_vote(void)
577 {
578 	return __qdf_ipa_proxy_clk_vote();
579 }
580 
581 static inline void qdf_ipa_proxy_clk_unvote(void)
582 {
583 	return __qdf_ipa_proxy_clk_unvote();
584 }
585 
586 static inline bool qdf_ipa_is_client_handle_valid(u32 clnt_hdl)
587 {
588 	return __qdf_ipa_is_client_handle_valid(clnt_hdl);
589 }
590 
591 static inline qdf_ipa_client_type_t qdf_ipa_get_client_mapping(int pipe_idx)
592 {
593 	return __qdf_ipa_get_client_mapping(pipe_idx);
594 }
595 
596 static inline qdf_ipa_rm_resource_name_t qdf_ipa_get_rm_resource_from_ep(
597 	int pipe_idx)
598 {
599 	return __qdf_ipa_get_rm_resource_from_ep(pipe_idx);
600 }
601 
602 static inline bool qdf_ipa_get_modem_cfg_emb_pipe_flt(void)
603 {
604 	return __qdf_ipa_get_modem_cfg_emb_pipe_flt();
605 }
606 
607 static inline int qdf_ipa_create_wdi_mapping(u32 num_buffers,
608 		__qdf_ipa_wdi_buffer_info_t *info)
609 {
610 	return __qdf_ipa_create_wdi_mapping(num_buffers, info);
611 }
612 
613 static inline int qdf_ipa_release_wdi_mapping(u32 num_buffers,
614 		qdf_ipa_wdi_buffer_info_t *info)
615 {
616 	return __qdf_ipa_release_wdi_mapping(num_buffers, info);
617 }
618 
619 static inline int qdf_ipa_disable_apps_wan_cons_deaggr(uint32_t agg_size,
620 		uint32_t agg_count)
621 {
622 	return __qdf_ipa_disable_apps_wan_cons_deaggr(agg_size, agg_count);
623 }
624 
625 static inline const qdf_ipa_gsi_ep_config_t *qdf_ipa_get_gsi_ep_info(qdf_ipa_client_type_t client)
626 {
627 	return __qdf_ipa_get_gsi_ep_info(client);
628 }
629 
630 static inline int qdf_ipa_stop_gsi_channel(u32 clnt_hdl)
631 {
632 	return __qdf_ipa_stop_gsi_channel(clnt_hdl);
633 }
634 
635 static inline int qdf_ipa_register_ipa_ready_cb(
636 	void (*qdf_ipa_ready_cb)(void *user_data),
637 	void *user_data)
638 {
639 	return __qdf_ipa_register_ipa_ready_cb(qdf_ipa_ready_cb, user_data);
640 }
641 
642 #ifdef FEATURE_METERING
643 static inline int qdf_ipa_broadcast_wdi_quota_reach_ind(uint32_t index,
644 							uint64_t quota_bytes)
645 {
646 	return __qdf_ipa_broadcast_wdi_quota_reach_ind(index, quota_bytes);
647 }
648 #endif
649 
650 #ifdef ENABLE_SMMU_S1_TRANSLATION
651 /**
652  * qdf_get_ipa_smmu_enabled() - to get IPA SMMU enable status
653  *
654  * Return: true when IPA SMMU enabled, otherwise false
655  */
656 static inline bool qdf_get_ipa_smmu_enabled(void)
657 {
658 	return __qdf_get_ipa_smmu_enabled();
659 }
660 #endif
661 
662 #endif /* IPA_OFFLOAD */
663 #endif /* _QDF_IPA_H */
664