Return-path: Received: from mx1.redhat.com ([209.132.183.28]:54403 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751305AbcGNJ0r (ORCPT ); Thu, 14 Jul 2016 05:26:47 -0400 Date: Thu, 14 Jul 2016 11:24:09 +0200 From: Stanislaw Gruszka To: "Grumbach, Emmanuel" Cc: "prarit@redhat.com" , "linux-kernel@vger.kernel.org" , linuxwifi , "Coelho, Luciano" , "Berg, Johannes" , "kvalo@codeaurora.org" , "Ivgi, Chaya Rachel" , "netdev@vger.kernel.org" , "Sharon, Sara" , "linux-wireless@vger.kernel.org" Subject: Re: [PATCH RESEND] iwlwifi, Do not implement thermal zone unless ucode is loaded Message-ID: <20160714092408.GA27271@redhat.com> (sfid-20160714_112726_140431_04BEBBF8) References: <1468250301-10357-1-git-send-email-prarit@redhat.com> <5783E33E.7090205@redhat.com> <1468261650.20877.14.camel@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii In-Reply-To: <1468261650.20877.14.camel@intel.com> Sender: linux-wireless-owner@vger.kernel.org List-ID: On Mon, Jul 11, 2016 at 06:27:30PM +0000, Grumbach, Emmanuel wrote: > I guess that works, but it seems wrong to me. Usually, registration > should happen only upon INIT, and yes, at that time the firmware is not > ready to provide the information yet. > > > > As can be seen in the current code base, iwl_mvm_tzone_get_temp() > > will return > > -EIO 100% of the time when the firmware doesn't support reading the If I understad correctly this error happen 100% of the time, not only during init. Hence seems there is an issue here, i.e. cur_ucode is not marked correctly as IWL_UCODE_REGULAR or iwl_mvm_get_temp() fail 100% of the time (iwl_mvm_is_tt_in_fw() incorrecly return true on Prarit device ? ). BTW, you implement thermal_zone device, but do you also need hwmon device? Perhaps using theramal_zone_params no_hwmon option would be proper here? Stanislaw