[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20210730091649.GA13442@u366d62d47e3651.ant.amazon.com>
Date: Fri, 30 Jul 2021 11:35:57 +0200
From: Siddharth Chandrasekaran <sidcha@...zon.de>
To: Wei Liu <wei.liu@...nel.org>
CC: Vitaly Kuznetsov <vkuznets@...hat.com>,
Siddharth Chandrasekaran <sidcha.dev@...il.com>,
Liran Alon <liran@...zon.com>,
Ioannis Aslanidis <iaslan@...zon.de>,
<linux-hyperv@...r.kernel.org>, <linux-arch@...r.kernel.org>,
<linux-kernel@...r.kernel.org>,
"K. Y. Srinivasan" <kys@...rosoft.com>,
Haiyang Zhang <haiyangz@...rosoft.com>,
Stephen Hemminger <sthemmin@...rosoft.com>,
Dexuan Cui <decui@...rosoft.com>, Arnd Bergmann <arnd@...db.de>
Subject: Re: [PATCH] asm-generic/hyperv: Fix struct hv_message_header ordering
On Thu, Jul 29, 2021 at 04:56:38PM +0000, Wei Liu wrote:
> On Thu, Jul 29, 2021 at 04:26:54PM +0200, Siddharth Chandrasekaran wrote:
> > On Thu, Jul 29, 2021 at 02:07:05PM +0000, Wei Liu wrote:
> > > On Thu, Jul 29, 2021 at 03:52:46PM +0200, Vitaly Kuznetsov wrote:
> > > > Siddharth Chandrasekaran <sidcha@...zon.de> writes:
> > > >
> > > > > According to Hyper-V TLFS Version 6.0b, struct hv_message_header members
> > > > > should be defined in the order:
> > > > >
> > > > > message_type, reserved, message_flags, payload_size
> > > > >
> > > > > but we have it defined in the order:
> > > > >
> > > > > message_type, payload_size, message_flags, reserved
> > > > >
> > > > > that is, the payload_size and reserved members swapped.
> > > >
> > > > Indeed,
> > > >
> > > > typedef struct
> > > > {
> > > > HV_MESSAGE_TYPE MessageType;
> > > > UINT16 Reserved;
> > > > HV_MESSAGE_FLAGS MessageFlags;
> > > > UINT8 PayloadSize;
> > > > union
> > > > {
> > > > UINT64 OriginationId;
> > > > HV_PARTITION_ID Sender;
> > > > HV_PORT_ID Port;
> > > > };
> > > > } HV_MESSAGE_HEADER;
> > >
> > > Well. I think TLFS is wrong. Let me ask around.
> >
> > TBH, I hadn't considered that possibility :). I assumed it was a
> > regression on our side. But I spent some time tracing the history of that
> > struct all the way back to when it was in staging (in 2009) and now I'm
> > inclined to believe a later version of TLFS is at fault here.
> >
> > Based on what we decide in this thread, I will open an issue on the TLFS
> > GitHub repository.
> >
>
> I have confirmation TLFS is wrong and shall be fixed. Feel free to open
> an issue on GitHub too.
Thanks for the confirmation, I created an issue [1] to track this.
~ Sid.
[1]: https://github.com/MicrosoftDocs/Virtualization-Documentation/issues/1624
Amazon Development Center Germany GmbH
Krausenstr. 38
10117 Berlin
Geschaeftsfuehrung: Christian Schlaeger, Jonathan Weiss
Eingetragen am Amtsgericht Charlottenburg unter HRB 149173 B
Sitz: Berlin
Ust-ID: DE 289 237 879
Powered by blists - more mailing lists