[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <201706151846.22230@pali>
Date: Thu, 15 Jun 2017 18:46:21 +0200
From: Pali Rohár <pali.rohar@...il.com>
To: Mario.Limonciello@...l.com
Cc: luto@...capital.net, dvhart@...radead.org,
platform-driver-x86@...r.kernel.org,
andriy.shevchenko@...ux.intel.com, luto@...nel.org,
rjw@...ysocki.net, linux-kernel@...r.kernel.org,
linux-acpi@...r.kernel.org
Subject: Re: [PATCH 15/16] platform/x86: wmi-mof: New driver to expose embedded WMI MOF metadata
On Friday 09 June 2017 23:51:32 Pali Rohár wrote:
> On Friday 09 June 2017 17:46:12 Mario.Limonciello@...l.com wrote:
> > > -----Original Message-----
> > > From: Pali Rohár [mailto:pali.rohar@...il.com]
> > > Sent: Wednesday, June 7, 2017 3:50 PM
> > > To: Limonciello, Mario <Mario_Limonciello@...l.com>
> > > Cc: luto@...capital.net; dvhart@...radead.org; platform-driver-
> > > x86@...r.kernel.org; andriy.shevchenko@...ux.intel.com;
> > > luto@...nel.org; rjw@...ysocki.net; linux-kernel@...r.kernel.org;
> > > linux-acpi@...r.kernel.org Subject: Re: [PATCH 15/16]
> > > platform/x86: wmi-mof: New driver to expose embedded WMI MOF
> > > metadata
> > >
> > > On Wednesday 07 June 2017 22:23:08 Mario.Limonciello@...l.com
> > > wrote:
> > > > > -----Original Message-----
> > > > > From: Pali Rohár [mailto:pali.rohar@...il.com]
> > > > > Sent: Wednesday, June 7, 2017 12:39 PM
> > > > > To: Limonciello, Mario <Mario_Limonciello@...l.com>
> > > > > Cc: luto@...capital.net; dvhart@...radead.org;
> > > > > platform-driver- x86@...r.kernel.org;
> > > > > andriy.shevchenko@...ux.intel.com; luto@...nel.org;
> > > > > rjw@...ysocki.net;
> > > > > linux-kernel@...r.kernel.org; linux-acpi@...r.kernel.org
> > > > > Subject: Re: [PATCH 15/16]
> > > > > platform/x86: wmi-mof: New driver to expose embedded WMI MOF
> > > > > metadata
> > > > >
> > > > > On Tuesday 06 June 2017 15:56:21 Pali Rohár wrote:
> > > > > > On Tuesday 06 June 2017 13:46:16 Mario.Limonciello@...l.com
> > > > > >
> > > > > > wrote:
> > > > > > > 2) On my system when you expand the arguments for "void
> > > > > > > DoBFn" the source doesn't describe individual arguments
> > > > > > > like you do. Again this might not matter to MOF parsing
> > > > > > > tools but wanted to let you know in case it does.
> > > > > >
> > > > > > I know, this part is missing. Order of arguments are only
> > > > > > in ID qualifier and not sorted + in/out de-duplicated.
> > > > >
> > > > > Implemented! Now arguments are correctly placed based on ID
> > > > > qualifier.
> > > >
> > > > I think it's still off a little though.
> > > >
> > > > What I'm getting back now from bmf2mof is:
> > > > void DoBFn([in, Description("Fn buf"), out] BDat Data);
> > > >
> > > > Whereas source puts Description as the last argument:
> > > > void DoBFn([in, out, Description("Fn buf")] BDat Data);
> > >
> > > In BMOF from my Latitude E6440 there are specified two parameters
> > > with index 0. One with qualifiers ("in", Description("Fn buf"))
> > > and one with ("out", Description("Fn buf")). I think you have
> > > similar/same data in BMOF.
> > >
> > > In my bmf2mof I just combined those two parameters into one (when
> > > name, type and index matches) and concatenate also qualifiers
> > > with removing duplicates.
> > >
> > > Do not know what is correct way, but I think qualifiers are just
> > > unordered set. MS decompiler probably put "in" and "out"
> > > qualifiers before any other for better readability.
> >
> > Have you tried to run it through mofcomp.exe and then decompile
> > again with bmf2mof? As long as it's coming out the same you're
> > probably right.
>
> Yes, bmf2mof+mofcomp.exe+bmf2mof gives same output as just bmf2mof.
I changed order for printing qualifiers in bmf2mof. "in" and "out" are
now printed before all others. So you should see now same output.
> > > > > > > source:
> > > > > > > void DoBFn([in, out, Description("Fn buf")] BDat Data);
> > > > > > >
> > > > > > > bmf2mof:
> > > > > > > void doBFn([in, Description("Fn buf"), ID(0)] BDat
> > > > > > > Data,
> > > > > > > [out, Description("Fn buf"), ID(0)] BDat Data);
> > > > >
> > > > > --
> > > > > Pali Rohár
> > > > > pali.rohar@...il.com
> > >
> > > --
> > > Pali Rohár
> > > pali.rohar@...il.com
--
Pali Rohár
pali.rohar@...il.com
Download attachment "signature.asc " of type "application/pgp-signature" (199 bytes)
Powered by blists - more mailing lists