summaryrefslogtreecommitdiff
path: root/include/linux/timerqueue.h
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2019-04-04 11:56:51 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-08-04 09:34:39 +0200
commitc1e1288d2e61727c1a9b9f28d0cf61da592a76bc (patch)
tree1b8ecdb7a9a0bfdc537a97486fb798538bfc7caf /include/linux/timerqueue.h
parent50d47c54bbe126f079c91cfdd91697aec01204da (diff)
ath6kl: add some bounds checking
[ Upstream commit 5d6751eaff672ea77642e74e92e6c0ac7f9709ab ] The "ev->traffic_class" and "reply->ac" variables come from the network and they're used as an offset into the wmi->stream_exist_for_ac[] array. Those variables are u8 so they can be 0-255 but the stream_exist_for_ac[] array only has WMM_NUM_AC (4) elements. We need to add a couple bounds checks to prevent array overflows. I also modified one existing check from "if (traffic_class > 3) {" to "if (traffic_class >= WMM_NUM_AC) {" just to make them all consistent. Fixes: bdcd81707973 (" Add ath6kl cleaned up driver") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'include/linux/timerqueue.h')
0 files changed, 0 insertions, 0 deletions