From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752456AbbC1WA4 (ORCPT ); Sat, 28 Mar 2015 18:00:56 -0400 Received: from mail-wi0-f173.google.com ([209.85.212.173]:35553 "EHLO mail-wi0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751703AbbC1WAv (ORCPT ); Sat, 28 Mar 2015 18:00:51 -0400 From: Pali =?utf-8?q?Roh=C3=A1r?= To: Steven Honeyman Subject: Re: [PATCH 2/2] hwmon: Allow to compile dell-smm-hwmon driver without /proc/i8k Date: Sat, 28 Mar 2015 23:00:48 +0100 User-Agent: KMail/1.13.7 (Linux/3.13.0-48-generic; KDE/4.14.2; x86_64; ; ) Cc: Paul Bolle , Guenter Roeck , Arnd Bergmann , "Greg Kroah-Hartman" , Jean Delvare , Valdis Kletnieks , Jochen Eisinger , Gabriele Mazzotta , linux-kernel@vger.kernel.org, lm-sensors@lm-sensors.org References: <1427538255-10860-1-git-send-email-pali.rohar@gmail.com> <1427540660.2334.14.camel@x220> In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart18554150.3UFgmxOnW2"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <201503282300.48749@pali> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --nextPart18554150.3UFgmxOnW2 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable On Saturday 28 March 2015 13:54:51 Steven Honeyman wrote: > On 28 March 2015 at 11:04, Paul Bolle =20 wrote: > > On Sat, 2015-03-28 at 11:24 +0100, Pali Roh=C3=A1r wrote: > >> --- a/drivers/hwmon/Kconfig > >> +++ b/drivers/hwmon/Kconfig > >> @@ -1703,6 +1703,17 @@ config SENSORS_ULTRA45 > >>=20 > >> This driver provides support for the Ultra45 > >> workstation environmental sensors. > >>=20 > >> +config SENSORS_DELL_SMM > >> + tristate "Dell laptop SMM BIOS hwmon driver" > >> + depends ON X86 > >=20 > > How did this past your testing? > >=20 > >> + ---help--- > >> + This hwmon driver adds support for reporting > >> temperature of different + sensors and controls the > >> fans on Dell laptops via System Management + Mode > >> provided by Dell BIOS. > >> + > >> + When option I8K is also enabled this driver > >> provides legacy /proc/i8k + userspace interface for > >> i8kutils package. > >> + >=20 > It's working OK for me (after fixing the mistake pointed out > above). >=20 > [Latitude e6540] > ----- > coretemp-isa-0000 > Adapter: ISA adapter > Physical id 0: +53.0=C2=B0C (high =3D +84.0=C2=B0C, crit =3D +100.0=C2= =B0C) > Core 0: +51.0=C2=B0C (high =3D +84.0=C2=B0C, crit =3D +100.0=C2= =B0C) > Core 1: +53.0=C2=B0C (high =3D +84.0=C2=B0C, crit =3D +100.0=C2= =B0C) >=20 > i8k-virtual-0 > Adapter: Virtual device > Processor Fan: 3171 RPM > CPU: +52.0=C2=B0C > Ambient: +46.0=C2=B0C > SODIMM: +40.0=C2=B0C > ----- >=20 > Ambient and SODIMM look swapped - but it's probably just > another Dell error. I really need to look at getting coreboot > on this thing. >=20 Both patches do not change any code. So there should not be any=20 type swapped with or without my patch. Cpu type is requested via SMM in same way as it is doing old DOS=20 executable. So there can be maybe problem in DELL SMM handler too=20 or maybe just I did not understand correctly assembler dump of=20 DOS executable... > On 28 March 2015 at 10:24, Pali Roh=C3=A1r > wrote: ... >=20 > > config I8K > >=20 > > - tristate "Dell laptop support" > > - select HWMON > > + bool "Dell i8k legacy laptop support" > > + select SENSORS_DELL_SMM >=20 > ... >=20 > > +config SENSORS_DELL_SMM > > + tristate "Dell laptop SMM BIOS hwmon driver" >=20 > The only change I'd suggest is not to change the tristate to > bool for I8K. Forcing that to bool means that > SENSORS_DELL_SMM can't be compiled as a module if the user > wishes to keep i8k hanging around "just in case". It'll > probably annoy distro kernel packagers too. >=20 >=20 > Thanks, > Steven My idea was: SENSORS_DELL_SMM enable/disable compilation of kernel driver=20 (ether statically link into kernel image or as external module) CONFIG_I8K just enable /proc/i8k code in SENSORS_DELL_SMM -- no=20 additional driver, just boolean switch which has effect only iff=20 SENSORS_DELL_SMM is Y or M =2D-=20 Pali Roh=C3=A1r pali.rohar@gmail.com --nextPart18554150.3UFgmxOnW2 Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) iEYEABECAAYFAlUXJJAACgkQi/DJPQPkQ1JcLQCgoanOm08BpqD2cSSbDzk/EVoH 1bcAoIicstuwHGvI41ZDD0dfsaJY4hGy =jeim -----END PGP SIGNATURE----- --nextPart18554150.3UFgmxOnW2--