]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/blobdiff - drivers/net/wireless/iwlwifi/mvm/rx.c
Merge branches 'debug-choice', 'devel-stable' and 'misc' into for-linus
[mirror_ubuntu-artful-kernel.git] / drivers / net / wireless / iwlwifi / mvm / rx.c
index 4dfc21a3e83ed3a1ab127baf1a7864a2fdc4cc9d..e4930d5027d228ff4e411ec2e8c6289e1c4366d2 100644 (file)
@@ -363,3 +363,25 @@ int iwl_mvm_rx_rx_mpdu(struct iwl_mvm *mvm, struct iwl_rx_cmd_buffer *rxb,
                                        rxb, &rx_status);
        return 0;
 }
+
+/*
+ * iwl_mvm_rx_statistics - STATISTICS_NOTIFICATION handler
+ *
+ * TODO: This handler is implemented partially.
+ * It only gets the NIC's temperature.
+ */
+int iwl_mvm_rx_statistics(struct iwl_mvm *mvm,
+                         struct iwl_rx_cmd_buffer *rxb,
+                         struct iwl_device_cmd *cmd)
+{
+       struct iwl_rx_packet *pkt = rxb_addr(rxb);
+       struct iwl_notif_statistics *stats = (void *)&pkt->data;
+       struct mvm_statistics_general_common *common = &stats->general.common;
+
+       if (mvm->temperature != le32_to_cpu(common->temperature)) {
+               mvm->temperature = le32_to_cpu(common->temperature);
+               iwl_mvm_tt_handler(mvm);
+       }
+
+       return 0;
+}