Commit 31b23982 authored by Nicolas Iooss's avatar Nicolas Iooss Committed by Kalle Valo

ath10k: use the right length of "background"

The word "background" contains 10 characters so the third argument of
strncmp() need to be 10 in order to match this prefix correctly.
Signed-off-by: default avatarNicolas Iooss <nicolas.iooss_linux@m4x.org>
Fixes: 855aed12 ("ath10k: add spectral scan feature")
Signed-off-by: default avatarKalle Valo <kvalo@qca.qualcomm.com>
parent f004e532
......@@ -338,7 +338,7 @@ static ssize_t write_file_spec_scan_ctl(struct file *file,
} else {
res = -EINVAL;
}
} else if (strncmp("background", buf, 9) == 0) {
} else if (strncmp("background", buf, 10) == 0) {
res = ath10k_spectral_scan_config(ar, SPECTRAL_BACKGROUND);
} else if (strncmp("manual", buf, 6) == 0) {
res = ath10k_spectral_scan_config(ar, SPECTRAL_MANUAL);
......
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