From 7711d2312ee4ede860d51c3efd4f1d1726292f6b Mon Sep 17 00:00:00 2001 From: "Gustavo A. R. Silva" Date: Fri, 19 May 2017 11:54:00 +0300 Subject: ath10k: remove unnecessary code The array fields in struct wmi_start_scan_arg that are checked here are fixed size arrays so they can never be NULL. Change-Id: I5c80a9758328df2eff1fa7c4bb433d0370f67143 Addresses-Coverity-ID: 1260031 Cc: Arend Van Spriel Cc: Kalle Valo Signed-off-by: Gustavo A. R. Silva Signed-off-by: Kalle Valo Git-repo: https://source.codeaurora.org/quic/la/kernel/msm-4.4 Git-commit: 8c1f20815231edf1ed2b7133ea07ea94ca31db05 Signed-off-by: Swetha Chikkaboraiah --- drivers/net/wireless/ath/ath10k/wmi.c | 9 --------- 1 file changed, 9 deletions(-) (limited to 'drivers/net/wireless/ath') diff --git a/drivers/net/wireless/ath/ath10k/wmi.c b/drivers/net/wireless/ath/ath10k/wmi.c index 045a27eef176..9709165c8871 100644 --- a/drivers/net/wireless/ath/ath10k/wmi.c +++ b/drivers/net/wireless/ath/ath10k/wmi.c @@ -6048,15 +6048,6 @@ static struct sk_buff *ath10k_wmi_10_4_op_gen_init(struct ath10k *ar) int ath10k_wmi_start_scan_verify(const struct wmi_start_scan_arg *arg) { - if (arg->ie_len) - return -EINVAL; - if (arg->n_channels && !arg->channels) - return -EINVAL; - if (arg->n_ssids && !arg->ssids) - return -EINVAL; - if (arg->n_bssids && !arg->bssids) - return -EINVAL; - if (arg->ie_len > WLAN_SCAN_PARAMS_MAX_IE_LEN) return -EINVAL; if (arg->n_channels > ARRAY_SIZE(arg->channels)) -- cgit v1.2.3