Commit 2d813760 authored by David S. Miller's avatar David S. Miller
parents a4d25803 df6d0230
......@@ -2613,6 +2613,11 @@ int iwl_force_reset(struct iwl_priv *priv, int mode, bool external)
if (test_bit(STATUS_EXIT_PENDING, &priv->status))
return -EINVAL;
if (test_bit(STATUS_SCANNING, &priv->status)) {
IWL_DEBUG_INFO(priv, "scan in progress.\n");
return -EINVAL;
}
if (mode >= IWL_MAX_FORCE_RESET) {
IWL_DEBUG_INFO(priv, "invalid reset request.\n");
return -EINVAL;
......
......@@ -152,7 +152,7 @@ static int ioctl_private_iw_point(struct iw_point *iwp, unsigned int cmd,
} else if (!iwp->pointer)
return -EFAULT;
extra = kmalloc(extra_size, GFP_KERNEL);
extra = kzalloc(extra_size, GFP_KERNEL);
if (!extra)
return -ENOMEM;
......
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