Skip to content

Commit 3ef2daa

Browse files
committed
Updated to v4.5.25.66 driver
1 parent 4605c58 commit 3ef2daa

92 files changed

Lines changed: 857 additions & 614 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

CORE/CLD_TXRX/HTT/htt_t2h.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/*
22
* Copyright (c) 2011-2018 The Linux Foundation. All rights reserved.
3+
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
34
*
45
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
56
*
@@ -1230,7 +1231,7 @@ int8_t
12301231
htt_rx_ind_noise_floor_chain(htt_pdev_handle pdev, adf_nbuf_t rx_ind_msg,
12311232
int8_t chain)
12321233
{
1233-
int8_t noise_floor;
1234+
int8_t noise_floor = HTT_NOISE_FLOOR_INVALID;
12341235
u_int32_t *msg_word;
12351236

12361237
/* only chain0/1 used with 11p DSRC */

CORE/CLD_TXRX/TLSHIM/tl_shim.c

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/*
22
* Copyright (c) 2013-2020 The Linux Foundation. All rights reserved.
3+
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
34
*
45
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
56
*
@@ -989,9 +990,10 @@ static void tl_shim_flush_rx_frames(void *vos_ctx,
989990
clear_bit(TLSHIM_FLUSH_CACHE_IN_PROGRESS, &sta_info->flags);
990991
}
991992

992-
static void tlshim_data_rx_cb(struct txrx_tl_shim_ctx *tl_shim,
993-
adf_nbuf_t buf_list, u_int16_t staid)
993+
static void tlshim_data_rx_cb(void *context, void *rxpkt, u_int16_t staid)
994994
{
995+
struct txrx_tl_shim_ctx *tl_shim = (struct txrx_tl_shim_ctx *)context;
996+
adf_nbuf_t buf_list = (adf_nbuf_t)rxpkt;
995997
void *vos_ctx = vos_get_global_context(VOS_MODULE_ID_TL, tl_shim);
996998
struct tlshim_sta_info *sta_info;
997999
adf_nbuf_t buf, next_buf;
@@ -1153,8 +1155,7 @@ static void tlshim_data_rx_handler(void *context, u_int16_t staid,
11531155
TLSHIM_LOGW("No available Rx message buffer");
11541156
goto drop_rx_buf;
11551157
}
1156-
pkt->callback = (vos_tlshim_cb)
1157-
tlshim_data_rx_cb;
1158+
pkt->callback = tlshim_data_rx_cb;
11581159
pkt->context = (void *) tl_shim;
11591160
pkt->Rxpkt = (void *) rx_buf_list;
11601161
pkt->staId = staid;

CORE/CLD_TXRX/TXRX/ol_tx.c

Lines changed: 12 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
2-
* Copyright (c) 2011-2014, 2016-2018, 2021 The Linux Foundation.
3-
* All rights reserved.
2+
* Copyright (c) 2011-2014, 2016-2021 The Linux Foundation. All rights reserved.
3+
* Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
44
*
55
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
66
*
@@ -49,7 +49,7 @@
4949
#include <ol_tx_classify.h> /* ol_tx_classify, ol_tx_classify_mgmt */
5050
#include <ol_tx_queue.h> /* ol_tx_enqueue */
5151
#include <ol_tx_sched.h> /* ol_tx_sched */
52-
52+
#include <asm/div64.h>
5353
/* internal header files relevant only for specific systems (Pronto) */
5454
#include <ol_txrx_encap.h> /* OL_TX_ENCAP, etc */
5555
#include "vos_lock.h"
@@ -1992,14 +1992,18 @@ ol_tx_vdev_set_bundle_require(uint8_t vdev_id, unsigned long tx_bytes,
19921992
{
19931993
struct ol_txrx_vdev_t* vdev = ol_txrx_get_vdev_from_vdev_id(vdev_id);
19941994
bool old_bundle_required;
1995+
uint64_t high_th_temp;
1996+
uint64_t low_th_temp;
19951997

19961998
if ((!vdev) || (low_th > high_th))
19971999
return;
19982000

19992001
old_bundle_required = vdev->bundling_reqired;
2000-
if (tx_bytes > ((high_th * time_in_ms * 3) >> 1))
2002+
high_th_temp = high_th * time_in_ms * 1500;
2003+
low_th_temp = low_th * time_in_ms * 1500;
2004+
if (tx_bytes > vos_do_div(high_th_temp,1000))
20012005
vdev->bundling_reqired = true;
2002-
else if (tx_bytes < ((low_th * time_in_ms * 3) >> 1))
2006+
else if (tx_bytes < vos_do_div(low_th_temp,1000))
20032007
vdev->bundling_reqired = false;
20042008

20052009
if (old_bundle_required != vdev->bundling_reqired)
@@ -2020,7 +2024,7 @@ ol_tx_hl_queue_flush_all(struct ol_txrx_vdev_t* vdev)
20202024
{
20212025
adf_os_spin_lock_bh(&vdev->bundle_queue.mutex);
20222026
if (vdev->bundle_queue.txq.depth != 0) {
2023-
adf_os_timer_cancel(&vdev->bundle_queue.timer);
2027+
vos_timer_stop(&vdev->bundle_queue.timer);
20242028
vdev->pdev->total_bundle_queue_length -=
20252029
vdev->bundle_queue.txq.depth;
20262030
adf_nbuf_tx_free(vdev->bundle_queue.txq.head, 1/*error*/);
@@ -2044,7 +2048,7 @@ ol_tx_hl_vdev_queue_append(struct ol_txrx_vdev_t* vdev, adf_nbuf_t msdu_list)
20442048
adf_os_spin_lock_bh(&vdev->bundle_queue.mutex);
20452049

20462050
if (!vdev->bundle_queue.txq.head) {
2047-
adf_os_timer_start(
2051+
vos_timer_start(
20482052
&vdev->bundle_queue.timer,
20492053
ol_cfg_get_bundle_timer_value(vdev->pdev->ctrl_pdev));
20502054
vdev->bundle_queue.txq.head = msdu_list;
@@ -2084,7 +2088,7 @@ ol_tx_hl_vdev_queue_send_all(struct ol_txrx_vdev_t* vdev, bool call_sched)
20842088
adf_os_spin_lock_bh(&vdev->bundle_queue.mutex);
20852089

20862090
if (vdev->bundle_queue.txq.depth != 0) {
2087-
adf_os_timer_cancel(&vdev->bundle_queue.timer);
2091+
vos_timer_stop(&vdev->bundle_queue.timer);
20882092
vdev->pdev->total_bundle_queue_length -=
20892093
vdev->bundle_queue.txq.depth;
20902094
msdu_list = ol_tx_hl_base(vdev, ol_tx_spec_std,
@@ -2126,18 +2130,6 @@ ol_tx_hl_pdev_queue_send_all(struct ol_txrx_pdev_t* pdev)
21262130
*
21272131
* Return: none
21282132
*/
2129-
#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 15, 0)
2130-
void
2131-
ol_tx_hl_vdev_bundle_timer(struct timer_list *t)
2132-
{
2133-
adf_nbuf_t msdu_list;
2134-
struct ol_txrx_vdev_t *vdev = from_timer(vdev, t, bundle_queue.timer);
2135-
2136-
msdu_list = ol_tx_hl_vdev_queue_send_all(vdev, true);
2137-
if (msdu_list)
2138-
adf_nbuf_tx_free(msdu_list, 1/*error*/);
2139-
}
2140-
#else
21412133
void
21422134
ol_tx_hl_vdev_bundle_timer(void *vdev)
21432135
{
@@ -2147,7 +2139,6 @@ ol_tx_hl_vdev_bundle_timer(void *vdev)
21472139
if (msdu_list)
21482140
adf_nbuf_tx_free(msdu_list, 1/*error*/);
21492141
}
2150-
#endif
21512142

21522143
/**
21532144
* ol_tx_hl_queue() - queueing logic to bundle in HL

CORE/CLD_TXRX/TXRX/ol_tx.h

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/*
22
* Copyright (c) 2011-2014,2016-2017,2019 The Linux Foundation. All rights reserved.
3+
* Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
34
*
45
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
56
*
@@ -125,33 +126,20 @@ void ol_tx_hl_del_ack_queue_flush_all(struct ol_txrx_vdev_t *vdev)
125126
#endif
126127

127128
#ifdef QCA_SUPPORT_TXRX_HL_BUNDLE
128-
#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 15, 0)
129-
void
130-
ol_tx_hl_vdev_bundle_timer(struct timer_list *t);
131-
#else
132129
void
133130
ol_tx_hl_vdev_bundle_timer(void *vdev);
134-
#endif
135131

136132
void
137133
ol_tx_hl_queue_flush_all(struct ol_txrx_vdev_t* vdev);
138134

139135
adf_nbuf_t
140136
ol_tx_hl_queue(struct ol_txrx_vdev_t* vdev, adf_nbuf_t msdu_list);
141137

142-
#else
143-
144-
#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 15, 0)
145-
static inline void ol_tx_hl_vdev_bundle_timer(struct timer_list *t)
146-
{
147-
return;
148-
}
149138
#else
150139
static inline void ol_tx_hl_vdev_bundle_timer(void *vdev)
151140
{
152141
return;
153142
}
154-
#endif
155143

156144
static inline void
157145
ol_tx_hl_queue_flush_all(struct ol_txrx_vdev_t* vdev)

CORE/CLD_TXRX/TXRX/ol_tx_sched.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1107,14 +1107,12 @@ void ol_tx_sched_wrr_param_update(struct ol_txrx_pdev_t *pdev,
11071107
struct ol_tx_sched_wrr_adv_t *scheduler)
11081108
{
11091109
int i;
1110-
#ifdef WLAN_DEBUG
11111110
char *tx_sched_wrr_name[4] = {
11121111
"BE",
11131112
"BK",
11141113
"VI",
11151114
"VO"
11161115
};
1117-
#endif
11181116

11191117
if (NULL == scheduler)
11201118
return;

CORE/CLD_TXRX/TXRX/ol_txrx.c

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/*
22
* Copyright (c) 2011-2019, 2021 The Linux Foundation. All rights reserved.
3+
* Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
34
*
45
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
56
*
@@ -1276,11 +1277,8 @@ ol_txrx_vdev_attach(
12761277
adf_os_spinlock_init(&vdev->bundle_queue.mutex);
12771278
vdev->bundle_queue.txq.head = vdev->ll_pause.txq.tail = NULL;
12781279
vdev->bundle_queue.txq.depth = 0;
1279-
adf_os_timer_init(
1280-
pdev->osdev,
1281-
&vdev->bundle_queue.timer,
1282-
ol_tx_hl_vdev_bundle_timer,
1283-
vdev, ADF_DEFERRABLE_TIMER);
1280+
vos_timer_init(&vdev->bundle_queue.timer, VOS_TIMER_TYPE_SW,
1281+
ol_tx_hl_vdev_bundle_timer, vdev);
12841282

12851283
ol_txrx_vdev_init_tcp_del_ack(vdev);
12861284

@@ -1399,7 +1397,7 @@ ol_txrx_vdev_detach(
13991397
}
14001398
}
14011399
#endif /* defined(CONFIG_HL_SUPPORT) */
1402-
1400+
vos_timer_destroy(&vdev->bundle_queue.timer);
14031401
adf_os_spin_lock_bh(&vdev->ll_pause.mutex);
14041402
adf_os_timer_cancel(&vdev->ll_pause.timer);
14051403
vdev->ll_pause.is_q_timer_on = FALSE;

CORE/CLD_TXRX/TXRX/ol_txrx_types.h

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/*
22
* Copyright (c) 2013-2020 The Linux Foundation. All rights reserved.
3+
* Copyright (c) 2022-2023 Qualcomm Innovation Center, Inc. All rights reserved.
34
*
45
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
56
*
@@ -96,15 +97,6 @@ struct ol_txrx_pdev_t;
9697
struct ol_txrx_vdev_t;
9798
struct ol_txrx_peer_t;
9899

99-
struct ol_pdev_t;
100-
typedef struct ol_pdev_t* ol_pdev_handle;
101-
102-
struct ol_vdev_t;
103-
typedef struct ol_vdev_t* ol_vdev_handle;
104-
105-
struct ol_peer_t;
106-
typedef struct ol_peer_t* ol_peer_handle;
107-
108100
/* rx filter related */
109101
#define MAX_PRIVACY_FILTERS 4 /* max privacy filters */
110102

@@ -1095,7 +1087,7 @@ struct ol_txrx_vdev_t {
10951087
int depth;
10961088
} txq;
10971089
adf_os_spinlock_t mutex;
1098-
adf_os_timer_t timer;
1090+
vos_timer_t timer;
10991091
} bundle_queue;
11001092

11011093
#ifdef QCA_SUPPORT_TXRX_DRIVER_TCP_DEL_ACK

CORE/CLD_TXRX/TXRX/txrx.h

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/*
22
* Copyright (c) 2013-2015 The Linux Foundation. All rights reserved.
3+
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
34
*
45
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
56
*
@@ -113,18 +114,6 @@ VOS_STATUS wlan_register_mgmt_client(void *pdev_txrx,
113114
VOS_STATUS (*rx_mgmt)(void *g_vosctx,
114115
void *buf));
115116

116-
typedef void (*ol_txrx_vdev_delete_cb)(void *context);
117-
118-
/**
119-
* @typedef ol_txrx_tx_fp
120-
* @brief top-level transmit function
121-
*/
122-
typedef adf_nbuf_t
123-
(*ol_txrx_tx_fp)(struct ol_txrx_vdev_t *vdev, adf_nbuf_t msdu_list);
124-
125-
typedef void
126-
(*ol_txrx_mgmt_tx_cb)(void *ctxt, adf_nbuf_t tx_mgmt_frm, int had_error);
127-
128117
/* If RSSI realm is changed, send notification to Clients, SME, HDD */
129118
typedef VOS_STATUS (*wlan_txrx_rssi_cross_thresh) (void *adapter, u8 rssi,
130119
void *usr_ctx, v_S7_t avg_rssi);

CORE/EPPING/src/epping_txrx.c

Lines changed: 25 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/*
22
* Copyright (c) 2014-2019 The Linux Foundation. All rights reserved.
3+
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
34
*
45
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
56
*
@@ -143,7 +144,7 @@ static void epping_ndev_uninit (struct net_device *dev)
143144
return;
144145
}
145146

146-
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5,5,0))
147+
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 6, 0))
147148
void epping_tx_queue_timeout(struct net_device *dev, unsigned int txqueue)
148149
#else
149150
void epping_tx_queue_timeout(struct net_device *dev)
@@ -174,7 +175,7 @@ void epping_tx_queue_timeout(struct net_device *dev)
174175

175176
}
176177

177-
int epping_hard_start_xmit(struct sk_buff *skb, struct net_device *dev)
178+
netdev_tx_t epping_hard_start_xmit(struct sk_buff *skb, struct net_device *dev)
178179
{
179180
epping_adapter_t *pAdapter;
180181
int ret = 0;
@@ -204,7 +205,8 @@ struct net_device_stats* epping_get_stats(struct net_device *dev)
204205
return &pAdapter->stats;
205206
}
206207

207-
int epping_ndev_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd)
208+
static int
209+
__epping_ndev_ioctl(struct net_device *dev, void __user *data, int cmd)
208210
{
209211
epping_adapter_t *pAdapter;
210212
int ret = 0;
@@ -223,7 +225,7 @@ int epping_ndev_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd)
223225
goto end;
224226
}
225227

226-
if ((!ifr) || (!ifr->ifr_data)) {
228+
if (!data) {
227229
ret = -EINVAL;
228230
goto end;
229231
}
@@ -246,6 +248,21 @@ int epping_ndev_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd)
246248
return ret;
247249
}
248250

251+
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 15, 0))
252+
static int
253+
epping_dev_private_ioctl(struct net_device *dev, struct ifreq *ifr,
254+
void __user *data, int cmd)
255+
{
256+
return __epping_ndev_ioctl(dev, data, cmd);
257+
}
258+
#else
259+
static int
260+
epping_ndev_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd)
261+
{
262+
return __epping_ndev_ioctl(dev, ifr->ifr_data, cmd);
263+
}
264+
#endif
265+
249266
static int epping_set_mac_address(struct net_device *dev, void *addr)
250267
{
251268
epping_adapter_t *pAdapter = netdev_priv(dev);
@@ -367,7 +384,11 @@ static struct net_device_ops epping_drv_ops = {
367384
.ndo_start_xmit = epping_hard_start_xmit,
368385
.ndo_tx_timeout = epping_tx_queue_timeout,
369386
.ndo_get_stats = epping_get_stats,
387+
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 15, 0))
388+
.ndo_siocdevprivate = epping_dev_private_ioctl,
389+
#else
370390
.ndo_do_ioctl = epping_ndev_ioctl,
391+
#endif
371392
.ndo_set_mac_address = epping_set_mac_address,
372393
.ndo_select_queue = NULL,
373394
};

CORE/HDD/inc/wlan_hdd_cfg80211.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
22
* Copyright (c) 2012-2019 The Linux Foundation. All rights reserved.
3-
* Copyright (c) 2021 Qualcomm Innovation Center, Inc. All rights reserved.
3+
* Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved.
44
*
55
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
66
*
@@ -3006,7 +3006,7 @@ int wlan_hdd_cfg80211_send_tdls_discover_req(struct wiphy *wiphy,
30063006
extern void wlan_hdd_cfg80211_update_replayCounterCallback(void *callbackContext,
30073007
tpSirGtkOffloadGetInfoRspParams pGtkOffloadGetInfoRsp);
30083008
#endif
3009-
void* wlan_hdd_change_country_code_cb(void *pAdapter);
3009+
void wlan_hdd_change_country_code_cb(void *pAdapter);
30103010
void hdd_select_cbmode(hdd_adapter_t *pAdapter, v_U8_t operationChannel,
30113011
uint16_t *ch_width);
30123012
void hdd_select_mon_cbmode(hdd_adapter_t *adapter, v_U8_t operation_channel,

0 commit comments

Comments
 (0)