mirror of
				https://git.kernel.org/pub/scm/network/wireless/iwd.git
				synced 2025-10-31 21:27:30 +01:00 
			
		
		
		
	netdev: check connected in channel switch event
In an ideal world userspace should never be getting a channel switch event unless connected to an AP, but alas this has been seen at least with ath10k hardware. This causes IWD to crash since the logic assumes netdev->handshake is set.
This commit is contained in:
		
							parent
							
								
									df2c5cf7fa
								
							
						
					
					
						commit
						755280a4cc
					
				| @ -5417,6 +5417,9 @@ static void netdev_channel_switch_event(struct l_genl_msg *msg, | ||||
| 	if (netdev->type != NL80211_IFTYPE_STATION) | ||||
| 		return; | ||||
| 
 | ||||
| 	if (L_WARN_ON(!netdev->connected)) | ||||
| 		return; | ||||
| 
 | ||||
| 	chandef = l_new(struct band_chandef, 1); | ||||
| 
 | ||||
| 	if (nl80211_parse_chandef(msg, chandef) < 0) { | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 James Prestwood
						James Prestwood