summaryrefslogtreecommitdiff
path: root/drivers/staging/wfx/data_tx.h
diff options
context:
space:
mode:
authorJérôme Pouiller <jerome.pouiller@silabs.com>2019-12-17 16:14:30 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-12-18 15:54:54 +0100
commit700e39e2d17649587704afcde50e908ec863f27f (patch)
tree8e7556db7a31b892c9ce538ade9d7b0fe16b0ad1 /drivers/staging/wfx/data_tx.h
parentc594ff7c7cfade844a78484d366c5b4d4dfbf47a (diff)
staging: wfx: fix counter overflow
Some weird behaviors were observed when connection is really good and packets are small. It appears that sometime, number of packets in queues can exceed 255 and generate an overflow in field usage_count. Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com> Link: https://lore.kernel.org/r/20191217161318.31402-4-Jerome.Pouiller@silabs.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/wfx/data_tx.h')
-rw-r--r--drivers/staging/wfx/data_tx.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/wfx/data_tx.h b/drivers/staging/wfx/data_tx.h
index a0f9ae69baf5..f63e5d8cf929 100644
--- a/drivers/staging/wfx/data_tx.h
+++ b/drivers/staging/wfx/data_tx.h
@@ -39,8 +39,8 @@ struct wfx_link_entry {
struct tx_policy {
struct list_head link;
+ int usage_count;
u8 rates[12];
- u8 usage_count;
u8 uploaded;
};