Loading drivers/platform/msm/ipa/ipa_rm_peers_list.c +2 −0 Original line number Original line Diff line number Diff line // SPDX-License-Identifier: GPL-2.0-only // SPDX-License-Identifier: GPL-2.0-only /* /* * Copyright (c) 2013-2019, The Linux Foundation. All rights reserved. * Copyright (c) 2013-2019, The Linux Foundation. All rights reserved. * Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved */ */ #include <linux/slab.h> #include <linux/slab.h> Loading Loading @@ -68,6 +69,7 @@ int ipa_rm_peers_list_create(int max_peers, list_alloc_fail: list_alloc_fail: kfree(*peers_list); kfree(*peers_list); *peers_list = NULL; bail: bail: return result; return result; } } Loading drivers/platform/msm/ipa/ipa_v3/ipa_hw_stats.c +2 −2 Original line number Original line Diff line number Diff line Loading @@ -2311,7 +2311,7 @@ static ssize_t ipa_debugfs_enable_disable_drop_stats(struct file *file, is_pipe = true; is_pipe = true; } } if (dbg_buff[i] == seprator) { if (dbg_buff[i] == seprator) { if (pipe_num >= 0 && pipe_num < ipa3_ctx->ipa_num_pipes if (pipe_num < ipa3_ctx->ipa_num_pipes && ipa3_get_client_by_pipe(pipe_num) < && ipa3_get_client_by_pipe(pipe_num) < IPA_CLIENT_MAX) { IPA_CLIENT_MAX) { IPADBG("pipe number %u\n", pipe_num); IPADBG("pipe number %u\n", pipe_num); Loading @@ -2326,7 +2326,7 @@ static ssize_t ipa_debugfs_enable_disable_drop_stats(struct file *file, is_pipe = false; is_pipe = false; } } } } if (is_pipe && pipe_num >= 0 && pipe_num < ipa3_ctx->ipa_num_pipes && if (is_pipe && pipe_num < ipa3_ctx->ipa_num_pipes && ipa3_get_client_by_pipe(pipe_num) < IPA_CLIENT_MAX) { ipa3_get_client_by_pipe(pipe_num) < IPA_CLIENT_MAX) { IPADBG("pipe number %u\n", pipe_num); IPADBG("pipe number %u\n", pipe_num); if (enable_pipe) if (enable_pipe) Loading drivers/platform/msm/ipa/ipa_v3/ipa_intf.c +3 −3 Original line number Original line Diff line number Diff line Loading @@ -82,19 +82,19 @@ int ipa3_register_intf_ext(const char *name, const struct ipa_tx_intf *tx, return -EINVAL; return -EINVAL; } } if (tx && tx->num_props > IPA_NUM_PROPS_MAX) { if (tx && ((tx->num_props > IPA_NUM_PROPS_MAX) || (tx->num_props == 0))) { IPAERR_RL("invalid tx num_props=%d max=%d\n", tx->num_props, IPAERR_RL("invalid tx num_props=%d max=%d\n", tx->num_props, IPA_NUM_PROPS_MAX); IPA_NUM_PROPS_MAX); return -EINVAL; return -EINVAL; } } if (rx && rx->num_props > IPA_NUM_PROPS_MAX) { if (rx && ((rx->num_props > IPA_NUM_PROPS_MAX) || (rx->num_props == 0))) { IPAERR_RL("invalid rx num_props=%d max=%d\n", rx->num_props, IPAERR_RL("invalid rx num_props=%d max=%d\n", rx->num_props, IPA_NUM_PROPS_MAX); IPA_NUM_PROPS_MAX); return -EINVAL; return -EINVAL; } } if (ext && ext->num_props > IPA_NUM_PROPS_MAX) { if (ext && ((ext->num_props > IPA_NUM_PROPS_MAX) || (ext->num_props == 0))) { IPAERR_RL("invalid ext num_props=%d max=%d\n", ext->num_props, IPAERR_RL("invalid ext num_props=%d max=%d\n", ext->num_props, IPA_NUM_PROPS_MAX); IPA_NUM_PROPS_MAX); return -EINVAL; return -EINVAL; Loading drivers/platform/msm/ipa/ipa_v3/ipa_odl.c +6 −0 Original line number Original line Diff line number Diff line Loading @@ -473,6 +473,12 @@ void ipa3_odl_pipe_cleanup(bool is_ssr) IPAERR("adpl pipe not configured\n"); IPAERR("adpl pipe not configured\n"); return; return; } } if(!ipa3_odl_ctx->odl_state.odl_ep_setup) { IPAERR("adpl pipe setup not done\n"); return; } if (ipa3_odl_ctx->odl_state.odl_open) if (ipa3_odl_ctx->odl_state.odl_open) ipa_odl_opened = true; ipa_odl_opened = true; Loading drivers/platform/msm/ipa/ipa_v3/ipa_qmi_service.c +5 −7 Original line number Original line Diff line number Diff line Loading @@ -469,8 +469,8 @@ static int ipa3_qmi_send_req_wait(struct qmi_handle *client_handle, mutex_lock(&ipa3_qmi_lock); mutex_lock(&ipa3_qmi_lock); if (!client_handle) { if (client_handle != ipa_q6_clnt) { IPADBG("Q6 QMI clinet pointer already freed\n"); mutex_unlock(&ipa3_qmi_lock); mutex_unlock(&ipa3_qmi_lock); return -EINVAL; return -EINVAL; } } Loading Loading @@ -897,11 +897,7 @@ int ipa3_qmi_add_offload_request_send( return -EINVAL; return -EINVAL; } } /* check if the filter rules from IPACM is valid */ if (req->filter_spec_ex2_list_len == 0) { if (req->filter_spec_ex2_list_len < 0) { IPAWANERR("IPACM pass invalid num of rules\n"); return -EINVAL; } else if (req->filter_spec_ex2_list_len == 0) { IPAWANDBG("IPACM pass zero rules to Q6\n"); IPAWANDBG("IPACM pass zero rules to Q6\n"); } else { } else { IPAWANDBG("IPACM pass %u rules to Q6\n", IPAWANDBG("IPACM pass %u rules to Q6\n", Loading Loading @@ -1861,6 +1857,7 @@ void ipa3_qmi_service_exit(void) workqueues_stopped = true; workqueues_stopped = true; IPADBG("Entry\n"); /* qmi-service */ /* qmi-service */ if (ipa3_svc_handle != NULL) { if (ipa3_svc_handle != NULL) { qmi_handle_release(ipa3_svc_handle); qmi_handle_release(ipa3_svc_handle); Loading Loading @@ -1893,6 +1890,7 @@ void ipa3_qmi_service_exit(void) ipa3_qmi_indication_fin = false; ipa3_qmi_indication_fin = false; ipa3_modem_init_cmplt = false; ipa3_modem_init_cmplt = false; send_qmi_init_q6 = true; send_qmi_init_q6 = true; IPADBG("Exit\n"); } } void ipa3_qmi_stop_workqueues(void) void ipa3_qmi_stop_workqueues(void) Loading Loading
drivers/platform/msm/ipa/ipa_rm_peers_list.c +2 −0 Original line number Original line Diff line number Diff line // SPDX-License-Identifier: GPL-2.0-only // SPDX-License-Identifier: GPL-2.0-only /* /* * Copyright (c) 2013-2019, The Linux Foundation. All rights reserved. * Copyright (c) 2013-2019, The Linux Foundation. All rights reserved. * Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved */ */ #include <linux/slab.h> #include <linux/slab.h> Loading Loading @@ -68,6 +69,7 @@ int ipa_rm_peers_list_create(int max_peers, list_alloc_fail: list_alloc_fail: kfree(*peers_list); kfree(*peers_list); *peers_list = NULL; bail: bail: return result; return result; } } Loading
drivers/platform/msm/ipa/ipa_v3/ipa_hw_stats.c +2 −2 Original line number Original line Diff line number Diff line Loading @@ -2311,7 +2311,7 @@ static ssize_t ipa_debugfs_enable_disable_drop_stats(struct file *file, is_pipe = true; is_pipe = true; } } if (dbg_buff[i] == seprator) { if (dbg_buff[i] == seprator) { if (pipe_num >= 0 && pipe_num < ipa3_ctx->ipa_num_pipes if (pipe_num < ipa3_ctx->ipa_num_pipes && ipa3_get_client_by_pipe(pipe_num) < && ipa3_get_client_by_pipe(pipe_num) < IPA_CLIENT_MAX) { IPA_CLIENT_MAX) { IPADBG("pipe number %u\n", pipe_num); IPADBG("pipe number %u\n", pipe_num); Loading @@ -2326,7 +2326,7 @@ static ssize_t ipa_debugfs_enable_disable_drop_stats(struct file *file, is_pipe = false; is_pipe = false; } } } } if (is_pipe && pipe_num >= 0 && pipe_num < ipa3_ctx->ipa_num_pipes && if (is_pipe && pipe_num < ipa3_ctx->ipa_num_pipes && ipa3_get_client_by_pipe(pipe_num) < IPA_CLIENT_MAX) { ipa3_get_client_by_pipe(pipe_num) < IPA_CLIENT_MAX) { IPADBG("pipe number %u\n", pipe_num); IPADBG("pipe number %u\n", pipe_num); if (enable_pipe) if (enable_pipe) Loading
drivers/platform/msm/ipa/ipa_v3/ipa_intf.c +3 −3 Original line number Original line Diff line number Diff line Loading @@ -82,19 +82,19 @@ int ipa3_register_intf_ext(const char *name, const struct ipa_tx_intf *tx, return -EINVAL; return -EINVAL; } } if (tx && tx->num_props > IPA_NUM_PROPS_MAX) { if (tx && ((tx->num_props > IPA_NUM_PROPS_MAX) || (tx->num_props == 0))) { IPAERR_RL("invalid tx num_props=%d max=%d\n", tx->num_props, IPAERR_RL("invalid tx num_props=%d max=%d\n", tx->num_props, IPA_NUM_PROPS_MAX); IPA_NUM_PROPS_MAX); return -EINVAL; return -EINVAL; } } if (rx && rx->num_props > IPA_NUM_PROPS_MAX) { if (rx && ((rx->num_props > IPA_NUM_PROPS_MAX) || (rx->num_props == 0))) { IPAERR_RL("invalid rx num_props=%d max=%d\n", rx->num_props, IPAERR_RL("invalid rx num_props=%d max=%d\n", rx->num_props, IPA_NUM_PROPS_MAX); IPA_NUM_PROPS_MAX); return -EINVAL; return -EINVAL; } } if (ext && ext->num_props > IPA_NUM_PROPS_MAX) { if (ext && ((ext->num_props > IPA_NUM_PROPS_MAX) || (ext->num_props == 0))) { IPAERR_RL("invalid ext num_props=%d max=%d\n", ext->num_props, IPAERR_RL("invalid ext num_props=%d max=%d\n", ext->num_props, IPA_NUM_PROPS_MAX); IPA_NUM_PROPS_MAX); return -EINVAL; return -EINVAL; Loading
drivers/platform/msm/ipa/ipa_v3/ipa_odl.c +6 −0 Original line number Original line Diff line number Diff line Loading @@ -473,6 +473,12 @@ void ipa3_odl_pipe_cleanup(bool is_ssr) IPAERR("adpl pipe not configured\n"); IPAERR("adpl pipe not configured\n"); return; return; } } if(!ipa3_odl_ctx->odl_state.odl_ep_setup) { IPAERR("adpl pipe setup not done\n"); return; } if (ipa3_odl_ctx->odl_state.odl_open) if (ipa3_odl_ctx->odl_state.odl_open) ipa_odl_opened = true; ipa_odl_opened = true; Loading
drivers/platform/msm/ipa/ipa_v3/ipa_qmi_service.c +5 −7 Original line number Original line Diff line number Diff line Loading @@ -469,8 +469,8 @@ static int ipa3_qmi_send_req_wait(struct qmi_handle *client_handle, mutex_lock(&ipa3_qmi_lock); mutex_lock(&ipa3_qmi_lock); if (!client_handle) { if (client_handle != ipa_q6_clnt) { IPADBG("Q6 QMI clinet pointer already freed\n"); mutex_unlock(&ipa3_qmi_lock); mutex_unlock(&ipa3_qmi_lock); return -EINVAL; return -EINVAL; } } Loading Loading @@ -897,11 +897,7 @@ int ipa3_qmi_add_offload_request_send( return -EINVAL; return -EINVAL; } } /* check if the filter rules from IPACM is valid */ if (req->filter_spec_ex2_list_len == 0) { if (req->filter_spec_ex2_list_len < 0) { IPAWANERR("IPACM pass invalid num of rules\n"); return -EINVAL; } else if (req->filter_spec_ex2_list_len == 0) { IPAWANDBG("IPACM pass zero rules to Q6\n"); IPAWANDBG("IPACM pass zero rules to Q6\n"); } else { } else { IPAWANDBG("IPACM pass %u rules to Q6\n", IPAWANDBG("IPACM pass %u rules to Q6\n", Loading Loading @@ -1861,6 +1857,7 @@ void ipa3_qmi_service_exit(void) workqueues_stopped = true; workqueues_stopped = true; IPADBG("Entry\n"); /* qmi-service */ /* qmi-service */ if (ipa3_svc_handle != NULL) { if (ipa3_svc_handle != NULL) { qmi_handle_release(ipa3_svc_handle); qmi_handle_release(ipa3_svc_handle); Loading Loading @@ -1893,6 +1890,7 @@ void ipa3_qmi_service_exit(void) ipa3_qmi_indication_fin = false; ipa3_qmi_indication_fin = false; ipa3_modem_init_cmplt = false; ipa3_modem_init_cmplt = false; send_qmi_init_q6 = true; send_qmi_init_q6 = true; IPADBG("Exit\n"); } } void ipa3_qmi_stop_workqueues(void) void ipa3_qmi_stop_workqueues(void) Loading