From: Jan Beulich <jbeulich@suse.com>
To: Julien Grall <julien@xen.org>
Cc: "Wei Liu" <wl@xen.org>,
"Andrew Cooper" <andrew.cooper3@citrix.com>,
"Eslam Elnikety" <elnikety@amazon.com>,
"Paul Durrant" <pdurrant@amazon.co.uk>,
xen-devel@lists.xenproject.org,
"Roger Pau Monné" <roger.pau@citrix.com>
Subject: Re: [PATCH] x86/vhpet: Fix type size in timer_int_route_valid
Date: Fri, 31 Jul 2020 14:38:58 +0200 [thread overview]
Message-ID: <cb42664a-fd35-f2bd-bab0-60dfda34fd81@suse.com> (raw)
In-Reply-To: <534c831a-4635-45b0-2580-4bd5812f49e8@xen.org>
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
prev parent reply other threads:[~2020-07-31 12:39 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-28 8:33 [PATCH] x86/vhpet: Fix type size in timer_int_route_valid Eslam Elnikety
2020-07-28 8:58 ` Roger Pau Monné
2020-07-28 9:14 ` Eslam Elnikety
2020-07-28 9:26 ` Andrew Cooper
2020-07-28 11:09 ` Eslam Elnikety
2020-07-28 13:46 ` Andrew Cooper
2020-07-28 13:55 ` Eslam Elnikety
2020-07-28 17:51 ` Jan Beulich
2020-07-31 8:38 ` Eslam Elnikety
2020-07-31 9:53 ` Jan Beulich
2020-07-31 12:35 ` Julien Grall
2020-07-31 12:38 ` Jan Beulich [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cb42664a-fd35-f2bd-bab0-60dfda34fd81@suse.com \
--to=jbeulich@suse.com \
--cc=andrew.cooper3@citrix.com \
--cc=elnikety@amazon.com \
--cc=julien@xen.org \
--cc=pdurrant@amazon.co.uk \
--cc=roger.pau@citrix.com \
--cc=wl@xen.org \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).