/*
 * Portions of this file
 * Copyright(c) 2016 Intel Deutschland GmbH
-* Copyright (C) 2018 - 2019, 2021 Intel Corporation
+* Copyright (C) 2018 - 2019, 2021 - 2023 Intel Corporation
 */
 
 #ifndef __MAC80211_DRIVER_OPS
 #include "trace.h"
 
 #define check_sdata_in_driver(sdata)   ({                                      \
-       !WARN_ONCE(!(sdata->flags & IEEE80211_SDATA_IN_DRIVER),                 \
-                  "%s: Failed check-sdata-in-driver check, flags: 0x%x\n",     \
-                  sdata->dev ? sdata->dev->name : sdata->name, sdata->flags);  \
+       WARN_ONCE(!sdata->local->reconfig_failure &&                            \
+                 !(sdata->flags & IEEE80211_SDATA_IN_DRIVER),                  \
+                 "%s: Failed check-sdata-in-driver check, flags: 0x%x\n",      \
+                 sdata->dev ? sdata->dev->name : sdata->name, sdata->flags);   \
+       !!(sdata->flags & IEEE80211_SDATA_IN_DRIVER);                           \
 })
 
 static inline struct ieee80211_sub_if_data *
 
        /* device is during a HW reconfig */
        bool in_reconfig;
 
+       /* reconfiguration failed ... suppress some warnings etc. */
+       bool reconfig_failure;
+
        /* wowlan is enabled -- don't reconfig on resume */
        bool wowlan;
 
 
        }
 
        if (local->open_count == 0) {
+               /* here we can consider everything in good order (again) */
+               local->reconfig_failure = false;
+
                res = drv_start(local);
                if (res)
                        goto err_del_bss;
 
        local->resuming = false;
        local->suspended = false;
        local->in_reconfig = false;
+       local->reconfig_failure = true;
 
        ieee80211_flush_completed_scan(local, true);