2009-03-13 08:50:13

by Dragoslav Zaric

[permalink] [raw]
Subject: Linux* Processor Microcode Data File

---------------------------------------------
I found this on web site http://kerneltrap.org

Tigran Aivazian, author of the IA32 microcode driver and Microcode
Update Utility for Linux explained:

"The answer to your question is that some Intel CPUs (just like any
other hardware or software) contain bugs
and, fortunately, their architecture is flexible enough to provide a
way to fix those bugs by means of loading the
microcode update on the fly, i.e. while the OS is running with no need
to reboot (in fact, rebooting or otherwise
resetting the CPU causes the update to be lost and requires to run the
update again)."
---------------------------------------------

So when you reboot system, you reset CPU to original state, and after
that you must apply microcode, and this
is what is actually doing right now, you put microcode in folder
/etc/firmware and after boot microcode is loaded.

So I think for CPU hotplug it is also natural that microcode is loaded
after plugging, because you can not use
microcode from boot process. Maybe kernel should have database of
tested microcodes, so when you plug CPU
appropriate microcode is loaded.



--
Thanks

Dragoslav Zaric
[Programmer ; M.Sc. in Astrophysics]


2009-03-13 14:56:22

by Gene Heskett

[permalink] [raw]
Subject: Re: Linux* Processor Microcode Data File

On Friday 13 March 2009, Dragoslav Zaric wrote:
>---------------------------------------------
>I found this on web site http://kerneltrap.org
>
>Tigran Aivazian, author of the IA32 microcode driver and Microcode
>Update Utility for Linux explained:
>
>"The answer to your question is that some Intel CPUs (just like any
>other hardware or software) contain bugs
>and, fortunately, their architecture is flexible enough to provide a
>way to fix those bugs by means of loading the
>microcode update on the fly, i.e. while the OS is running with no need
>to reboot (in fact, rebooting or otherwise
>resetting the CPU causes the update to be lost and requires to run the
>update again)."

And what runs this update? I saw it apply once in the dmesg output, about 3
full powerdown reboots ago, never since, and the code is still there in
/lib/firmware

AMD quad core 9550 here, stepping 03.

Thanks.
>---------------------------------------------
>
>So when you reboot system, you reset CPU to original state, and after
>that you must apply microcode, and this
>is what is actually doing right now, you put microcode in folder
>/etc/firmware and after boot microcode is loaded.
>
>So I think for CPU hotplug it is also natural that microcode is loaded
>after plugging, because you can not use
>microcode from boot process. Maybe kernel should have database of
>tested microcodes, so when you plug CPU
>appropriate microcode is loaded.


--
Cheers, Gene
"There are four boxes to be used in defense of liberty:
soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
The only thing that experience teaches us is that experience teaches us
nothing.
-- Andre Maurois (Emile Herzog)