qcacld-3.0: Rename cdf_sched_work to cdf_schedule_work
The api is clearer without the abreviation. The api is cleaner without an unused cdf_handle. Also remove unnecessary cdf_schedule_work api. cdf_create_work is also cleaner without cdf_handle. Change-Id: Id8c32596a92184d6768e2bc3210c308b44da2a57 CRs-Fixed: 935297
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2014 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2014, 2016 The Linux Foundation. All rights reserved.
|
||||
*
|
||||
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
|
||||
*
|
||||
@@ -96,7 +96,6 @@ static inline void cdf_destroy_bh(cdf_handle_t hdl, cdf_bh_t *bh)
|
||||
/**
|
||||
* cdf_create_work() - create a work/task queue, This runs in non-interrupt
|
||||
* context, so can be preempted by H/W & S/W intr
|
||||
* @hdl: OS handle
|
||||
* @work: Work instance
|
||||
* @func: Deferred function to run at bottom half non-interrupt
|
||||
* context
|
||||
@@ -105,34 +104,20 @@ static inline void cdf_destroy_bh(cdf_handle_t hdl, cdf_bh_t *bh)
|
||||
* Return: None
|
||||
*/
|
||||
static inline void
|
||||
cdf_create_work(cdf_handle_t hdl, cdf_work_t *work,
|
||||
cdf_create_work(cdf_work_t *work,
|
||||
cdf_defer_fn_t func, void *arg)
|
||||
{
|
||||
__cdf_init_work(hdl, work, func, arg);
|
||||
__cdf_init_work(work, func, arg);
|
||||
}
|
||||
|
||||
/**
|
||||
* cdf_sched_work() - schedule a deferred task on non-interrupt context
|
||||
* @hdl: OS handle
|
||||
* @work: Work instance
|
||||
*
|
||||
* Return: None
|
||||
*/
|
||||
static inline void cdf_sched_work(cdf_handle_t hdl, cdf_work_t *work)
|
||||
static inline void cdf_schedule_work(cdf_work_t *work)
|
||||
{
|
||||
__cdf_sched_work(hdl, work);
|
||||
__cdf_schedule_work(work);
|
||||
}
|
||||
|
||||
/**
|
||||
* cdf_destroy_work() - destroy the deferred task (synchronous)
|
||||
* @hdl: OS handle
|
||||
* @work: Work instance
|
||||
*
|
||||
* Return: None
|
||||
*/
|
||||
static inline void cdf_destroy_work(cdf_handle_t hdl, cdf_work_t *work)
|
||||
{
|
||||
__cdf_disable_work(hdl, work);
|
||||
}
|
||||
|
||||
#endif /*__CDF_DEFER_H*/
|
||||
|
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2014-2015 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2014-2016 The Linux Foundation. All rights reserved.
|
||||
*
|
||||
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
|
||||
*
|
||||
@@ -52,8 +52,7 @@ typedef struct {
|
||||
extern void __cdf_defer_func(struct work_struct *work);
|
||||
|
||||
static inline CDF_STATUS
|
||||
__cdf_init_work(cdf_handle_t hdl,
|
||||
__cdf_work_t *work, cdf_defer_fn_t func, void *arg)
|
||||
__cdf_init_work(__cdf_work_t *work, cdf_defer_fn_t func, void *arg)
|
||||
{
|
||||
/*Initilize func and argument in work struct */
|
||||
work->fn = func;
|
||||
@@ -66,18 +65,12 @@ __cdf_init_work(cdf_handle_t hdl,
|
||||
return CDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
static inline CDF_STATUS __cdf_sched_work(cdf_handle_t hdl, __cdf_work_t *work)
|
||||
static inline CDF_STATUS __cdf_schedule_work(__cdf_work_t *work)
|
||||
{
|
||||
schedule_work(&work->work);
|
||||
return CDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
static inline CDF_STATUS
|
||||
__cdf_disable_work(cdf_handle_t hdl, __cdf_work_t *work)
|
||||
{
|
||||
return CDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
static inline CDF_STATUS __cdf_init_bh(cdf_handle_t hdl,
|
||||
struct tasklet_struct *bh,
|
||||
cdf_defer_fn_t func, void *arg)
|
||||
|
@@ -6595,7 +6595,6 @@ void cds_force_sap_on_scc(eCsrRoamResult roam_result)
|
||||
#endif /* FEATURE_WLAN_FORCE_SAP_SCC */
|
||||
|
||||
#ifdef FEATURE_WLAN_MCC_TO_SCC_SWITCH
|
||||
|
||||
/**
|
||||
* cds_check_sta_ap_concurrent_ch_intf() - Restart SAP in STA-AP case
|
||||
* @data: Pointer to STA adapter
|
||||
@@ -6677,10 +6676,10 @@ void cds_check_concurrent_intf_and_restart_sap(hdd_station_ctx_t *hdd_sta_ctx,
|
||||
operationChannel)
|
||||
#endif
|
||||
) {
|
||||
cdf_create_work(0, &hdd_ctx->sta_ap_intf_check_work,
|
||||
cdf_create_work(&hdd_ctx->sta_ap_intf_check_work,
|
||||
cds_check_sta_ap_concurrent_ch_intf,
|
||||
(void *)adapter);
|
||||
cdf_sched_work(0, &hdd_ctx->sta_ap_intf_check_work);
|
||||
cdf_schedule_work(&hdd_ctx->sta_ap_intf_check_work);
|
||||
cds_info("Checking for Concurrent Change interference");
|
||||
}
|
||||
}
|
||||
|
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2013-2015 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2013-2016 The Linux Foundation. All rights reserved.
|
||||
*
|
||||
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
|
||||
*
|
||||
@@ -888,11 +888,10 @@ wma_data_tx_ack_comp_hdlr(void *wma_context, cdf_nbuf_t netbuf, int32_t status)
|
||||
ack_work->sub_type = 0;
|
||||
ack_work->status = status;
|
||||
|
||||
cdf_create_work(0, &ack_work->ack_cmp_work,
|
||||
cdf_create_work(&ack_work->ack_cmp_work,
|
||||
wma_data_tx_ack_work_handler,
|
||||
ack_work);
|
||||
/* Schedule the Work */
|
||||
cdf_sched_work(0, &ack_work->ack_cmp_work);
|
||||
cdf_schedule_work(&ack_work->ack_cmp_work);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1564,12 +1563,11 @@ wma_mgmt_tx_ack_comp_hdlr(void *wma_context, cdf_nbuf_t netbuf, int32_t status)
|
||||
ack_work->sub_type = pFc->subType;
|
||||
ack_work->status = status;
|
||||
|
||||
cdf_create_work(0, &ack_work->ack_cmp_work,
|
||||
cdf_create_work(&ack_work->ack_cmp_work,
|
||||
wma_mgmt_tx_ack_work_handler,
|
||||
ack_work);
|
||||
|
||||
/* Schedule the Work */
|
||||
cdf_sched_work(0, &ack_work->ack_cmp_work);
|
||||
cdf_schedule_work(&ack_work->ack_cmp_work);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user