iwlwifi: mvm: fix debugfs restart if fw_restart is disabled

If fw_restart is disabled, using the fw_restart debugfs
file will enable fw_restart and then send the failing
command, but this still frequently fails restart because
it resets fw_restart afterwards and is thus racy.

Fix this by tracking fw_restart separately and allowing
"always restart", "never restart" and "restart N times".

Signed-off-by: Eran Harary <eran.harary@intel.com>
Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
3 files changed