lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sat, 29 Nov 2014 10:15:52 -0800
From:	Guenter Roeck <linux@...ck-us.net>
To:	Pali Rohár <pali.rohar@...il.com>
CC:	Arnd Bergmann <arnd@...db.de>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Steven Honeyman <stevenhoneyman@...il.com>,
	linux-kernel@...r.kernel.org,
	Gabriele Mazzotta <gabriele.mzt@...il.com>
Subject: Re: [PATCH] i8k: Add support for temperature sensor labels

On 11/29/2014 08:30 AM, Pali Rohár wrote:
> On Saturday 29 November 2014 17:24:08 Guenter Roeck wrote:
>> On 11/29/2014 08:04 AM, Pali Rohár wrote:
>>> +static bool __init i8k_check_temp(int sensor)
>>> +{
>>> +	int err;
>>> +
>>> +	/*
>>> +	 * Check if temperature sensor type is valid.
>>> +	 *
>>> +	 * If it is valid then sensor should work. But some
>>> sensors are not +	 * available at any time. E.g GPU sensor
>>> on Optimus/PowerExpress/Enduro +	 * card does not work (or
>>> return bogus value) when card is turned off. +	 * So this
>>> function should not fail in this case. +	 */
>>> +	err = i8k_get_temp_type(sensor);
>>> +	if (err >= 0)
>>> +		return true;
>>> +
>>
>> Are you sure this function is provided for all systems ?
>> I am a bit concerned that we may wrongly disable sensors this
>> way, especially on older systems.
>>
>
> I do not know if that function is provided on all systems. But
> this code does not disable sensors. If function fail, then we
> fallback to temperature read down. Return true means that we
> enable sensor.
>

You are right. Guess I didn't have enough coffee this morning.

Thanks,
Guenter

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists