qcacmn: Call blocking functions in right context

Call blocking functions free_g_qdf_dp_trace_tbl_buffer and
allocate_log_msg_buffer under non-atomic context.

Change-Id: I534c95b19cb08472db4a4a0f8285769841b00326
CRs-Fixed: 2273581
This commit is contained in:
Rachit Kankane
2018-07-05 18:10:36 +05:30
committed by nshrivas
parent 1a9c6d1d4c
commit dfd97f38f6
2 changed files with 5 additions and 5 deletions

View File

@@ -898,9 +898,9 @@ void qdf_dp_trace_deinit(void)
spin_lock_bh(&l_dp_trace_lock); spin_lock_bh(&l_dp_trace_lock);
g_qdf_dp_trace_data.enable = false; g_qdf_dp_trace_data.enable = false;
g_qdf_dp_trace_data.no_of_record = 0; g_qdf_dp_trace_data.no_of_record = 0;
spin_unlock_bh(&l_dp_trace_lock);
free_g_qdf_dp_trace_tbl_buffer(); free_g_qdf_dp_trace_tbl_buffer();
spin_unlock_bh(&l_dp_trace_lock);
} }
/** /**
* qdf_dp_trace_set_value() - Configure the value to control DP trace * qdf_dp_trace_set_value() - Configure the value to control DP trace

View File

@@ -864,16 +864,16 @@ int wlan_logging_sock_init_svc(void)
gwlan_logging.num_buf = MAX_LOGMSG_COUNT; gwlan_logging.num_buf = MAX_LOGMSG_COUNT;
gwlan_logging.buffer_length = MAX_LOGMSG_LENGTH; gwlan_logging.buffer_length = MAX_LOGMSG_LENGTH;
spin_lock_irqsave(&gwlan_logging.spin_lock, irq_flag);
INIT_LIST_HEAD(&gwlan_logging.free_list);
INIT_LIST_HEAD(&gwlan_logging.filled_list);
if (allocate_log_msg_buffer() != QDF_STATUS_SUCCESS) { if (allocate_log_msg_buffer() != QDF_STATUS_SUCCESS) {
pr_err("%s: Could not allocate memory for log_msg\n", pr_err("%s: Could not allocate memory for log_msg\n",
__func__); __func__);
return -ENOMEM; return -ENOMEM;
} }
spin_lock_irqsave(&gwlan_logging.spin_lock, irq_flag);
INIT_LIST_HEAD(&gwlan_logging.free_list);
INIT_LIST_HEAD(&gwlan_logging.filled_list);
for (i = 0; i < gwlan_logging.num_buf; i++) { for (i = 0; i < gwlan_logging.num_buf; i++) {
list_add(&gplog_msg[i].node, &gwlan_logging.free_list); list_add(&gplog_msg[i].node, &gwlan_logging.free_list);
gplog_msg[i].index = i; gplog_msg[i].index = i;