|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v1.1 for-4.11 3/3] vpci/msi: fix size of the vectors fields
>>> On 26.03.18 at 13:28, <roger.pau@xxxxxxxxxx> wrote:
> The current size (5bits) is not enough to store the maximum number of
> vectors (32), bump it by one bit.
>
> Note that the size of the struct is still the same.
Coverity ID: 1430810
> --- a/xen/include/xen/vpci.h
> +++ b/xen/include/xen/vpci.h
> @@ -100,7 +100,7 @@ struct vpci {
> /* Data. */
> uint16_t data;
> /* Maximum number of vectors supported by the device. */
> - uint8_t max_vectors : 5;
> + uint8_t max_vectors : 6;
> /* Enabled? */
> bool enabled : 1;
> /* Supports per-vector masking? */
To aid simplicity of generated code, I had specifically asked for the
current 5-1-1-1-5 arrangement of bit field members. Now that the
5s need bumping to 6, we'll want 6-1-1-6-1, so please move
"enabled" down (also resulting in all feature flags coming before
all state ones). With that
Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx>
Jan
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |