6d2c360b | 22-Aug-2023 |
Avraham Stern <avraham.stern@intel.com> |
wifi: iwlmei: don't send nic info with invalid mac address
In case the SAP connection is established before the interface is added, the mac address is still not set. Don't send the nic info SAP mess
wifi: iwlmei: don't send nic info with invalid mac address
In case the SAP connection is established before the interface is added, the mac address is still not set. Don't send the nic info SAP message in this case since it will result in sending an invalid mac address. The nic info message will be sent with a valid mac address when the interface is added.
Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20230822103048.a49436bed387.I0ca88d72456e6e9f939bbc2e0c52ffb173fbc97e@changeid Signed-off-by: Johannes Berg <johannes.berg@intel.com>
show more ...
|
a7d9ac48 | 22-Aug-2023 |
Avraham Stern <avraham.stern@intel.com> |
wifi: iwlmei: send driver down SAP message only if wiamt is enabled
When wiamt is disabled the driver up SAP message is not sent, so there is no need to send the driver down message as well.
Signed
wifi: iwlmei: send driver down SAP message only if wiamt is enabled
When wiamt is disabled the driver up SAP message is not sent, so there is no need to send the driver down message as well.
Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20230822103048.100f41b84656.I583d3e18ea65793f53aa710af13e47f8af82b53d@changeid Signed-off-by: Johannes Berg <johannes.berg@intel.com>
show more ...
|
3243aee1 | 22-Aug-2023 |
Avraham Stern <avraham.stern@intel.com> |
wifi: iwlmei: send HOST_GOES_DOWN message even if wiamt is disabled
The HOST_GOES_DOWN message should be sent even if wiamt is disabled. Otherwise wiamt may still use the shared memory (e.g. if enab
wifi: iwlmei: send HOST_GOES_DOWN message even if wiamt is disabled
The HOST_GOES_DOWN message should be sent even if wiamt is disabled. Otherwise wiamt may still use the shared memory (e.g. if enabled later) while it's no longer valid.
Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20230822103048.2baad50eb1c3.If7b7c1dc2d6bfc6bacf7f6c72972f19714d9d973@changeid Signed-off-by: Johannes Berg <johannes.berg@intel.com>
show more ...
|
22b68fc6 | 18-Apr-2023 |
Avraham Stern <avraham.stern@intel.com> |
wifi: iwlwifi: mvm: fix RFKILL report when driver is going down
When CSME takes ownership, the driver sets RFKILL on, and this triggers driver unload and sending the confirmation SAP message. Howeve
wifi: iwlwifi: mvm: fix RFKILL report when driver is going down
When CSME takes ownership, the driver sets RFKILL on, and this triggers driver unload and sending the confirmation SAP message. However, when IWL_MVM_MEI_REPORT_RFKILL is set, RFKILL was not reported and as a result, the driver did not confirm the ownership transition. Fix it.
Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20230418122405.29ac3cd3df73.I96b32bc274bfe1e3871e54d3fa29c7ac4f40446f@changeid Signed-off-by: Johannes Berg <johannes.berg@intel.com>
show more ...
|
b0b9b805 | 02-Nov-2022 |
Avraham Stern <avraham.stern@intel.com> |
wifi: iwlwifi: mei: wait for the mac to stop on suspend
When iwlmei driver is removed, it removes all the interfaces since CSME will take over the NIC while there is no SAP connection. When the iwlm
wifi: iwlwifi: mei: wait for the mac to stop on suspend
When iwlmei driver is removed, it removes all the interfaces since CSME will take over the NIC while there is no SAP connection. When the iwlmei driver is removed due to the host being suspended, this results in the interface being down after resume since the interface was removed on suspend so mac80211 will not try to bring it up on resume. Since on suspend the mac is stopped anyway by mac80211, there is no need to remove the interface in this case. Wait for the mac to stop instead. Once the mac is stopped, the driver will not access the NIC anymore so it is safe for CSME to take over.
Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20221102165239.371102f04586.I813a964607b3e92ea275a0cf56df57227c11ae88@changeid
show more ...
|
c4bb943e | 02-Nov-2022 |
Avraham Stern <avraham.stern@intel.com> |
wifi: iwlwifi: iwlmei: report disconnection as temporary
Disconnections are reported to CSME as long link down. As a result, CSME will take ownership right away so the host doesn't have a chance to
wifi: iwlwifi: iwlmei: report disconnection as temporary
Disconnections are reported to CSME as long link down. As a result, CSME will take ownership right away so the host doesn't have a chance to reconnect, although in many cases it could quickly reconnect and preserve host connectivity. Report disconnections as temporary so CSME will give the host some grace time to reconnect.
Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20221102165239.401665457652.Ie5de9eacc5a51cf0965a08c202caf3fbc3a91ec4@changeid
show more ...
|
6564f3b8 | 02-Nov-2022 |
Avraham Stern <avraham.stern@intel.com> |
wifi: iwlwifi: mei: use wait_event_timeout() return value
wait_event_timeout() return value indicates whether the condition evaluated to true or not, so no need to re-take the lock and check the got
wifi: iwlwifi: mei: use wait_event_timeout() return value
wait_event_timeout() return value indicates whether the condition evaluated to true or not, so no need to re-take the lock and check the got_ownership flag.
Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20221102165239.33159054626f.Ief9e2dc42f96f8044c197d32172003a5ead0f8d3@changeid
show more ...
|
d3df49dd | 30-Oct-2022 |
Johannes Berg <johannes.berg@intel.com> |
wifi: iwlwifi: mei: fix potential NULL-ptr deref after clone
If cloning the SKB fails, don't try to use it, but rather return as if we should pass it.
Coverity CID: 1503456
Fixes: 2da4366f9e2c ("i
wifi: iwlwifi: mei: fix potential NULL-ptr deref after clone
If cloning the SKB fails, don't try to use it, but rather return as if we should pass it.
Coverity CID: 1503456
Fixes: 2da4366f9e2c ("iwlwifi: mei: add the driver to allow cooperation with CSME") Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20221030191011.0ce03ba99601.I87960b7cb0a3d16b9fd8d9144027e7e2587f5a58@changeid
show more ...
|
d288067e | 30-Oct-2022 |
Avraham Stern <avraham.stern@intel.com> |
wifi: iwlwifi: mei: avoid blocking sap messages handling due to rtnl lock
The AMT_STATE sap message handler tries to take the rtnl lock. This means that in case the rtnl lock is already taken, sap m
wifi: iwlwifi: mei: avoid blocking sap messages handling due to rtnl lock
The AMT_STATE sap message handler tries to take the rtnl lock. This means that in case the rtnl lock is already taken, sap messages will not be processed. When an interface is brought up, the host requests ownership from csme. However, since the rtnl lock is already held, if there is a pending amt state message, the host will not be able to read the ownership confirm message because the amt state message handler is pending. As a result, the host fails to get ownership although csme granted it. Fix it by moving the part that needs the rtnl lock into a dedicated worker, so handling sap messages can continue.
Fixes: 2da4366f9e2c ("iwlwifi: mei: add the driver to allow cooperation with CSME") Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20221030191011.8599f2b4e9dd.I518f79e9099bf815c5f8d90235b4ce3250f59970@changeid
show more ...
|
95170a46 | 30-Oct-2022 |
Emmanuel Grumbach <emmanuel.grumbach@intel.com> |
wifi: iwlwifi: mei: don't send SAP commands if AMT is disabled
We should not send any SAP command to CSME if AMT is disabled.
Reported-by: Toke Høiland-Jørgensen <toke@toke.dk> Fixes: 2da4366f9e2c
wifi: iwlwifi: mei: don't send SAP commands if AMT is disabled
We should not send any SAP command to CSME if AMT is disabled.
Reported-by: Toke Høiland-Jørgensen <toke@toke.dk> Fixes: 2da4366f9e2c ("iwlwifi: mei: add the driver to allow cooperation with CSME") Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20221030191011.ea222d41c781.Ifc90ddc3e35187683ff7f59371d792b61c8854c8@changeid
show more ...
|
5aa7ce31 | 30-Oct-2022 |
Avraham Stern <avraham.stern@intel.com> |
wifi: iwlwifi: mei: make sure ownership confirmed message is sent
It is possible that CSME will try to take ownership while the driver is stopping. In this case, if the CSME takes ownership message
wifi: iwlwifi: mei: make sure ownership confirmed message is sent
It is possible that CSME will try to take ownership while the driver is stopping. In this case, if the CSME takes ownership message arrives after the driver started unregistering, the iwl_mei_cache->ops is already invalid, so the host will not answer with the ownership confirmed message. Similarly, if the take ownership message arrived after the mac was stopped or when iwl_mvm_up() failed, setting rfkill will not trigger sending the confirm message. As a result, CSME will not take ownership, which will result in a disconnection.
Fix it by sending the ownership confirmed message immediately in such cases.
Fixes: 2da4366f9e2c ("iwlwifi: mei: add the driver to allow cooperation with CSME") Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20221030191011.b2a4c009e3e6.I7f931b7ee8b168e8ac88b11f23bff98b7ed3cb19@changeid
show more ...
|
78488a64 | 17-May-2022 |
Johannes Berg <johannes.berg@intel.com> |
iwlwifi: mei: fix potential NULL-ptr deref
If SKB allocation fails, continue rather than using the NULL pointer.
Coverity CID: 1497650
Cc: stable@vger.kernel.org Fixes: 2da4366f9e2c ("iwlwifi: mei
iwlwifi: mei: fix potential NULL-ptr deref
If SKB allocation fails, continue rather than using the NULL pointer.
Coverity CID: 1497650
Cc: stable@vger.kernel.org Fixes: 2da4366f9e2c ("iwlwifi: mei: add the driver to allow cooperation with CSME") Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://lore.kernel.org/r/20220517120045.90c1b1fd534e.Ibb42463e74d0ec7d36ec81df22e171ae1f6268b0@changeid Signed-off-by: Johannes Berg <johannes.berg@intel.com>
show more ...
|