Re: [PATCH] wifi: cfg80211: Lock wiphy in cfg80211_get_station

2024-05-21 Thread Antonio Quartulli
Hi, On 21/05/2024 14:15, Remi Pommarel wrote: On Tue, May 21, 2024 at 09:43:56AM +0200, Antonio Quartulli wrote: Hi, On 18/05/2024 17:50, Remi Pommarel wrote: Wiphy should be locked before calling rdev_get_station() (see lockdep assert in ieee80211_get_station()). Adding the lock is fine as

Re: [PATCH] wifi: cfg80211: Lock wiphy in cfg80211_get_station

2024-05-21 Thread Remi Pommarel
On Tue, May 21, 2024 at 09:43:56AM +0200, Antonio Quartulli wrote: > Hi, > > On 18/05/2024 17:50, Remi Pommarel wrote: > > Wiphy should be locked before calling rdev_get_station() (see lockdep > > assert in ieee80211_get_station()). > > Adding the lock is fine as nowadays it is taken in pre_doit

Re: [PATCH] wifi: cfg80211: Lock wiphy in cfg80211_get_station

2024-05-21 Thread Antonio Quartulli
Hi, On 18/05/2024 17:50, Remi Pommarel wrote: Wiphy should be locked before calling rdev_get_station() (see lockdep assert in ieee80211_get_station()). Adding the lock is fine as nowadays it is taken in pre_doit and released in post_doit (with some exceptions). Therefore when invoking .get_s

Re: [PATCH] wifi: cfg80211: Lock wiphy in cfg80211_get_station

2024-05-21 Thread Johannes Berg
On Sat, 2024-05-18 at 17:50 +0200, Remi Pommarel wrote: > Wiphy should be locked before calling rdev_get_station() (see lockdep > assert in ieee80211_get_station()). > > This fixes the following kernel NULL dereference: How do you get a NULL pointer dereference from a locking issue? Was something

Re: [PATCH] wifi: cfg80211: Lock wiphy in cfg80211_get_station

2024-05-21 Thread Nicolas Escande
On Sat May 18, 2024 at 5:50 PM CEST, Remi Pommarel wrote: > Wiphy should be locked before calling rdev_get_station() (see lockdep > assert in ieee80211_get_station()). > > This fixes the following kernel NULL dereference: > > Unable to handle kernel NULL pointer dereference at virtual address > 0