Re: Will there ever be EMC6w201 support?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 11 May 2011 14:43:35 +0200, Luca Tettamanti wrote:
> lahf is present in the assembly block inside the driver in i8k_smm; lahf
> moves the lowest byte of eflags into ah.
> Wikipedia[1] tells me that:
> 
>   Early AMD64 and Intel 64 CPUs lacked LAHF and SAHF instructions. AMD
>   introduced the instructions with their Athlon 64, Opteron and Turion 64
>   revision D processors in March 2005 while Intel introduced
>   the instructions with the Pentium 4 G1 stepping in December 2005.
> 
> Jeff's CPU does indeed lack lahf (see cpuinfo), so the driver should not
> unconditionally use the intruction.
> The driver should check X86_FEATURE_LAHF_LM or use use a different
> method to read EFLAFS (pushf?).

Thanks for the investigation, BTW... Brilliant!

> drivers/char/toshiba.c (tosh_smm) also suffers from the same issue.

That one currently depends on X86_32, which I seem to understand is
unaffected by the bug. But if this driver is ever extended to work on
64-bit machines, then yes, care will be needed.

-- 
Jean Delvare

_______________________________________________
lm-sensors mailing list
lm-sensors@xxxxxxxxxxxxxx
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors


[Index of Archives]     [Linux Kernel]     [Linux Hardware Monitoring]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux