diff options
author | Jérôme Pouiller <jerome.pouiller@silabs.com> | 2020-01-15 13:55:35 +0000 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-01-16 20:59:53 +0100 |
commit | 2f5fd8b07745838e590b61d5b136be8b9f94cc4c (patch) | |
tree | 64522d1e07d340d1eb08fc824f8b2d18525bed05 /drivers/staging/wfx/queue.h | |
parent | 5244357961a422100b73a9da423532578579324a (diff) |
staging: wfx: simplify wfx_tx_queue_get_num_queued()
wfx_tx_queue_get_num_queued() can take advantage of BIT() instead of
maintaining one variable for a counter and another for a mask.
In add, wfx_tx_queue_get_num_queued() has no real reason to return a
size_t instead of an int.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Link: https://lore.kernel.org/r/20200115135338.14374-64-Jerome.Pouiller@silabs.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/wfx/queue.h')
-rw-r--r-- | drivers/staging/wfx/queue.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/wfx/queue.h b/drivers/staging/wfx/queue.h index 096ae86135cc..90bb060d1204 100644 --- a/drivers/staging/wfx/queue.h +++ b/drivers/staging/wfx/queue.h @@ -51,7 +51,7 @@ struct hif_msg *wfx_tx_queues_get_after_dtim(struct wfx_vif *wvif); void wfx_tx_queue_put(struct wfx_dev *wdev, struct wfx_queue *queue, struct sk_buff *skb); -size_t wfx_tx_queue_get_num_queued(struct wfx_queue *queue, u32 link_id_map); +int wfx_tx_queue_get_num_queued(struct wfx_queue *queue, u32 link_id_map); struct sk_buff *wfx_pending_get(struct wfx_dev *wdev, u32 packet_id); int wfx_pending_remove(struct wfx_dev *wdev, struct sk_buff *skb); |