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

Re: [Xen-devel] [PATCH 04/10] xen/arm: vgic-v3: Don't check the size when we ignore the write/read as zero



On Mon, 2015-01-19 at 16:29 +0000, Julien Grall wrote:
> In general, it's not necessary/important to check the size.

Only if the docs say this register can be accessed by a partial
read/write, or if it is implementation defined what the result would be
(and RAZ/WI is within the set of allowable actions).

Do you have a reference for the behaviour of GICR accesses which aren't
of the register's natural size?

>  It's better
> to log it to let know the guest that its access will have no effect.
> 
> Note: On debug build it may happen to see some of these messages during
> domain boot.

We should only print if the guest has done something wrong, and reading
a RAZ register (or one which we have implemented that way) is not
inherently wrong.

IOW read_as_zero* should be silent, and a different code path used for
"guest did something wrong".

IOW I think the current distinction between bad_width and read_as_zero*
is correct currently, although perhaps the goto's which target them need
adjusting in some cases.

Perhaps you want to add a read_as_zero_32 which has the check, making
read_as_zero accept either 32- or 64-bit accesses, and goto the correct
label for each register?

Ian.


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.