On Jan 4, 2008 2:26 PM, Andi Kleen <andi@firstfloor.org> wrote:
OK, I did it the latter way. Your thermal_vector is my
smp_thermal_interrupt, which I have converted from a function to a
pointer to the CPU-specific function.
I _think_ it's fixed now. I'll let him rerun it at his end for verification.
But if PCI locks are spinlocks, then how can one access config space
in an interrupt handler, as it might be locked by the foreground? (No
locks would be required at all, if everyone just saved 0xCF8 and
0xCFC, but I digress.) And it's one thing to be "likely" already in a
thread, and another to be sure. If you can address these issues, I'll
change or remove the comment. I just want to prevent a
reasonable-looking but bad coding change from happening in the future.
Agreed. I had it at the top of the function, but now I've worked it
into both places.
Ideally, every ID in the k8_northbridges[] whitelist would have
functional thermal throttling. If more IDs than 0x1103 turn out to
have this feature broken, then we may need to add a blacklist as well.
But I expect that most future IDs will function correctly, hence my
reliance on the whitelist. In my view, anyone who adds an ID to a
whitelist (or just a list, for that matter) is obligated to perform a
static analysis (i.e. grep for "k8_northbridges") of the implications
of such act; therefore, I'm not too concerned about Griffin.
I've attached an updated patch. In the unlikely event that you want
to check this in, let me know so I can give it a final test.
--
Russell Leidich