On Thu, 2018-04-19 at 09:00 +0300, Luca Coelho wrote: > On Thu, 2018-04-19 at 08:42 +0300, Luca Coelho wrote: > > On Wed, 2018-04-18 at 11:31 +0300, Emmanuel Grumbach wrote: > > > On Wed, Apr 18, 2018 at 5:47 AM, Scott Register <sreg@xxxxxxx> > > > wrote: > > > > > > > > Hello, > > > > > > > > After upgrading to 4.18rc1 iwlwifi is printing a FW error. > > > > There > > > > was a > > > > previous thread with a similar > > > > issue but they seemed to resolve it with a ucode update. I > > > > think > > > > I'm > > > > running a newer FW and > > > > am still having an issue. 4.13 works--I haven't gone any higher > > > > so > > > > far. > > > > > > Please download the firmware from > > > https://git.kernel.org/cgit/linux/kernel/git/iwlwifi/linux-firmwa > > > re > > > .g > > > it/plain/iwlwifi-8265-36.ucode > > > This should fix your problem. > > > > Yeah, it should work with FW 36. But if there really is something > > in > > 4.18 that breaks support on 31, we should either fix it or make > > sure > > we > > don't even try to load this old firmware. > > Hmmm, you (and I) obviously meant 4.17-rc1. ;) Okay, so the reason was very simple. We are calculating the size of the old version of the scan API incorrectly. This should solve it: diff --git a/drivers/net/wireless/intel/iwlwifi/fw/api/scan.h b/drivers/net/wireless/intel/iwlwifi/fw/api/scan.h index 7af3a0f51b77..21695db51c8a 100644 --- a/drivers/net/wireless/intel/iwlwifi/fw/api/scan.h +++ b/drivers/net/wireless/intel/iwlwifi/fw/api/scan.h @@ -753,9 +753,7 @@ struct iwl_scan_req_umac { 4 * sizeof(u8)) #define IWL_SCAN_REQ_UMAC_SIZE_V6 (sizeof(struct iwl_scan_req_umac) - \ 2 * sizeof(u8) - sizeof(__le16)) -#define IWL_SCAN_REQ_UMAC_SIZE_V1 (sizeof(struct iwl_scan_req_umac) - \ - 2 * sizeof(__le32) - 2 * sizeof(u8) - \ - sizeof(__le16)) +#define IWL_SCAN_REQ_UMAC_SIZE_V1 36 Can you try it? In the beginning, making the size calculation based on the latest version made some sense, but it became so complex that it made it very prone to errors. So it's probably just better to hardcode the sizes since they never change anyway... -- Cheers, Luca.