iwlwifi: dbg: mark a variable __maybe_unused

If CONFIG_IWLWIFI_DEBUGFS is not set, the variable is assigned
but not checked, resulting in a compiler warning. Suppress it,
we need the variable for the debugfs-enabled case.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/iwlwifi.20200425130140.485f886f5a6c.I8a91c560c26cced33b15d8419caebb53a9abcc2d@changeid
This commit is contained in:
Johannes Berg 2020-04-25 13:04:51 +03:00 committed by Luca Coelho
parent 92f78d4b15
commit 281277b206
1 changed files with 1 additions and 1 deletions

View File

@ -2760,7 +2760,7 @@ void iwl_fw_dbg_stop_restart_recording(struct iwl_fw_runtime *fwrt,
struct iwl_fw_dbg_params *params,
bool stop)
{
int ret = 0;
int ret __maybe_unused = 0;
if (test_bit(STATUS_FW_ERROR, &fwrt->trans->status))
return;