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

Re: [PATCH] x86/vhpet: Fix type size in timer_int_route_valid



On 31.07.2020 14:35, Julien Grall wrote:
> Hi Jan,
> 
> On 31/07/2020 10:53, Jan Beulich wrote:
>> On 31.07.2020 10:38, Eslam Elnikety wrote:
>>> On 28.07.20 19:51, Jan Beulich wrote:
>>>> On 28.07.2020 11:26, Andrew Cooper wrote:
>>>>> --- a/xen/include/asm-x86/hvm/vpt.h
>>>>> +++ b/xen/include/asm-x86/hvm/vpt.h
>>>>> @@ -73,7 +73,13 @@ struct hpet_registers {
>>>>>        uint64_t isr;               /* interrupt status reg */
>>>>>        uint64_t mc64;              /* main counter */
>>>>>        struct {                    /* timers */
>>>>> -        uint64_t config;        /* configuration/cap */
>>>>> +        union {
>>>>> +            uint64_t config;    /* configuration/cap */
>>>>> +            struct {
>>>>> +                uint32_t _;
>>>>> +                uint32_t route;
>>>>> +            };
>>>>> +        };
>>>>
>>>> So long as there are no static initializers for this construct
>>>> that would then suffer the old-gcc problem, this is of course a
>>>> fine arrangement to make.
>>>
>>> I have to admit that I have no clue what the "old-gcc" problem is. I am
>>> curious, and I would appreciate pointers to figure out if/how to
>>> resolve. Is that an old, existing problem? Or a problem that was present
>>> in older versions of gcc?
>>
>> Well, as already said - the problem is with old gcc not dealing
>> well with initializers of structs/unions with unnamed fields.
> 
> You seem to know quite well the problem. So would you mind to give us 
> more details on which GCC version is believed to be broken?

I don't recall for sure, but iirc anything before 4.4.

Jan



 


Rackspace

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