Re: [PATCH] x86: add missing verify_cpu to 32bit wakeup

From: H. Peter Anvin
Date: Fri Jul 01 2011 - 19:14:25 EST


On 07/01/2011 03:36 PM, Kees Cook wrote:
>>
>> For S3, we should save/restore MISC_ENABLE instead... in fact, we
>> already save it, we just restore it too late.
>
> Given that MISC_ENABLE may not be available for a given CPU, it seems that
> it's basically the same detection code as in verify_cpu() already. Since
> this bit is the only part that is needed that early, I think the patch is
> good the way it is (especially since it balances the 64bit path which
> already calls this logic). I don't think doing the full early MISC_ENABLE
> save/restore this early is worth it. Thoughts?
>

We already save it, including if it exists, so we should just restore it
early, and then we don't have to do it again.

-hpa

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