Commit eed4721f authored by Colin Ian King's avatar Colin Ian King Committed by Kalle Valo

ath10k: remove redundant check of len with buf_len

The check of len > buf_len is redundant as len is initialized
to 0 and buf_len to 4096, so this comparison is always false.
Remove it.
Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Signed-off-by: default avatarKalle Valo <kvalo@qca.qualcomm.com>
parent 0a7d88e4
...@@ -249,9 +249,6 @@ static ssize_t ath10k_read_wmi_services(struct file *file, ...@@ -249,9 +249,6 @@ static ssize_t ath10k_read_wmi_services(struct file *file,
mutex_lock(&ar->conf_mutex); mutex_lock(&ar->conf_mutex);
if (len > buf_len)
len = buf_len;
spin_lock_bh(&ar->data_lock); spin_lock_bh(&ar->data_lock);
for (i = 0; i < WMI_SERVICE_MAX; i++) { for (i = 0; i < WMI_SERVICE_MAX; i++) {
enabled = test_bit(i, ar->wmi.svc_map); enabled = test_bit(i, ar->wmi.svc_map);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment