Re: [PATCH] Fix msr register allocation

From: Glauber de Oliveira Costa
Date: Mon Jul 30 2007 - 12:37:39 EST


On Mon, 2007-07-30 at 17:37 +0200, BjÃrn Steinbrink wrote:
> On 2007.07.30 12:25:54 -0300, Glauber de Oliveira Costa wrote:
> > Since the value in ret will go through a return statement,
> ^^^
> You mean "err" I guess?
Yeah, you're right.

> Note that the EAX output constraint is re-used in the input section for
> (u32)val, i.e. the lower half of the value to be written. And "wrmsr"
> needs that in EAX, so you cannot change the output constraint without
> touching the input constraint.
Right again. Will send a new patch that also changes the input constraint.

> Also, I do not see how the compiler could do any better than having the
> return value already in EAX, but that doesn't really mean anything ;-)

Yet, we should only force the compiler to a particular choice when we
have to, IMHO. So, unless anyone gives another reason not to, I will
send another patch with your warnings fixed.



-
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/