[WCNCR00164195] p2p: Fix P2P scan crash while WFD stopping

[Description]
Fix P2P scan crash while WFD stopping

[Steps]
1. WFD connected
2. WFD disconnect & P2P scan at the same time
3. Linux crash in API mtk_p2p_cfg80211_scan()

[Rootcause]
The resource "prScanRequest" may be set NULL in WFD stopping process.
Access this again in mtk_p2p_cfg80211_scan() would crash.

[Solution]
Copy "request" from cfg80211 caller instead of "prScanRequest"
 in driver object.

Change-Id: I46c664ac23453f1cbb69c7cd9be7185c2c9aaa1e
Signed-off-by: Deren Wu <deren.wu@mediatek.com>
CR-Id: WCNCR00164195
Feature: p2p
(cherry picked from commit 358ae69033414f3915b517ae49c8d381860cc0dd)
1 file changed