iwlwifi: mvm: fix RFH config command with >=10 CPUs
authorJohannes Berg <johannes.berg@intel.com>
Tue, 11 Dec 2018 20:20:43 +0000 (21:20 +0100)
committerLuca Coelho <luciano.coelho@intel.com>
Mon, 4 Feb 2019 10:28:10 +0000 (12:28 +0200)
commitdbf592f3d14fb7d532cb7c820b1065cf33e02aaa
tree6be6b9bf0aed60329a8f9efd99c1cc8ba8f05b00
parentc96b5eec2105ccb6a956c8da6bb6deb670ebaf43
iwlwifi: mvm: fix RFH config command with >=10 CPUs

If we have >=10 (logical) CPUs, our command size exceeds the
internal buffer size and the command fails; fix that by using
IWL_HCMD_DFL_NOCOPY for the command that's allocated anyway.

While at it, also fix the leak of cmd, and use struct_size()
to calculate its size.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Fixes: 8edbfaa19835 ("iwlwifi: mvm: configure multi RX queue")
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
drivers/net/wireless/intel/iwlwifi/mvm/fw.c