iwlwifi: introduce trans_ops->stop_hw

This handler stops the HW and puts it in low power state.
It will allow to clean up the flows in the upper layers.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
diff --git a/drivers/net/wireless/iwlwifi/iwl-trans.h b/drivers/net/wireless/iwlwifi/iwl-trans.h
index 55b5dc3..d0b6146 100644
--- a/drivers/net/wireless/iwlwifi/iwl-trans.h
+++ b/drivers/net/wireless/iwlwifi/iwl-trans.h
@@ -134,6 +134,8 @@
 /**
  * struct iwl_trans_ops - transport specific operations
  * @start_hw: starts the HW- from that point on, the HW can send interrupts
+ * @stop_hw: stops the HW- from that point on, the HW will be in low power but
+ *	will still issue interrupt if the HW RF kill is triggered.
  * @start_device: allocates and inits all the resources for the transport
  *                layer.
  * @fw_alive: called when the fw sends alive notification
@@ -163,6 +165,7 @@
 struct iwl_trans_ops {
 
 	int (*start_hw)(struct iwl_trans *iwl_trans);
+	void (*stop_hw)(struct iwl_trans *iwl_trans);
 	int (*start_device)(struct iwl_trans *trans);
 	void (*fw_alive)(struct iwl_trans *trans);
 	void (*stop_device)(struct iwl_trans *trans);
@@ -271,6 +274,11 @@
 	return trans->ops->start_hw(trans);
 }
 
+static inline void iwl_trans_stop_hw(struct iwl_trans *trans)
+{
+	trans->ops->stop_hw(trans);
+}
+
 static inline void iwl_trans_fw_alive(struct iwl_trans *trans)
 {
 	trans->ops->fw_alive(trans);