public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Darren Hart <dvhart@infradead.org>
To: Mario.Limonciello@dell.com
Cc: greg@kroah.com, pali.rohar@gmail.com, andy.shevchenko@gmail.com,
	linux-kernel@vger.kernel.org,
	platform-driver-x86@vger.kernel.org, luto@kernel.org,
	quasisec@google.com, rjw@rjwysocki.net, mjg59@google.com,
	hch@lst.de
Subject: Re: [PATCH v4 12/14] platform/x86: wmi: create character devices when requested by drivers
Date: Thu, 5 Oct 2017 13:51:33 -0700	[thread overview]
Message-ID: <20171005205133.GA12321@fury> (raw)
In-Reply-To: <750018cd00674782a55f2b50e8aef689@ausx13mpc120.AMER.DELL.COM>

On Thu, Oct 05, 2017 at 07:03:24PM +0000, Mario.Limonciello@dell.com wrote:
> > 
> > And how _exactly_ is this interface exposed in Windows?  Is it ad-hoc
> > with custom kernel drivers written by each vendor?  Or does the OS
> > provide a "sane" interface for it?
> 
> On Windows it's a driver-less solution.  Vendors don't do anything other
> than provide the MOF (which describes how the data passed to ASL looks).
> 
> When Windows boots up, _WDG is parsed, the binary MOF is loaded into
> the WMI repository.  The MOF describes how named objects map to GUIDs
> which map to ASL.
> 
> >From Powershell or from any application that uses WMI as admin you can 
> look up the root namespace and see all objects.  You can pass calls back
> and forth.  There's all sorts of examples of it here:
> https://msdn.microsoft.com/en-us/library/windows/hardware/dn614028(v=vs.85).aspx
> 

A couple snippets from this link which I believe I've shared previously
that clarify the design intent of the WMI mechanism:

"
ACPI-to-WMI Mapper Goals for Windows Instrumentation:

...

* Allow OEMs to include OEM-specific data blocks, user-mode-callable
  ACPI control methods, and events without requiring any changes to the
  ACPI-to-WMI mapper.

* Allow general-purpose data consumer applications--those written
  without any special knowledge of the data blocks exposed by a
  particular machine--to be able to access and understand the data
  blocks, user-mode-callable ACPI control methods, and events being
  mapped--including those that are OEM specific.

...

The following are not goals for the ACPI-to-WMI mapper:

* To have specific knowledge about any data block that passes through
  the mapper.

* To provide interfaces specifically for SMBIOS data and functions. The
  mapper is an open architecture that is not restricted to SMBIOS data
  and functionality.
"

This model is not consistent with Linux design principles, and Mario's
changes attempt to allow for more kernel oversight by:

* Requiring a driver to be written to bind to any GUID which will expose
  WMI methods to userspace. The goal here is to provide an effective
  whitelist, and to promote vendor participation (they need to send the
  patch, have it reviewed, respond to challenges on the security
  implications, etc.)

* In the future, provide for the MOF parsing within the kernel so Linux
  will have more ability to audit messaging.

-- 
Darren Hart
VMware Open Source Technology Center

  parent reply	other threads:[~2017-10-05 20:51 UTC|newest]

Thread overview: 72+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-04 22:48 [PATCH v4 00/14] Introduce support for Dell SMBIOS over WMI Mario Limonciello
2017-10-04 22:48 ` [PATCH v4 01/14] platform/x86: wmi: Add new method wmidev_evaluate_method Mario Limonciello
2017-10-04 22:48 ` [PATCH v4 02/14] platform/x86: dell-wmi: clean up wmi descriptor check Mario Limonciello
2017-10-04 22:48 ` [PATCH v4 03/14] platform/x86: dell-wmi: allow 32k return size in the descriptor Mario Limonciello
2017-10-04 22:48 ` [PATCH v4 04/14] platform/x86: dell-wmi: increase severity of some failures Mario Limonciello
2017-10-05  5:20   ` Andy Shevchenko
2017-10-05 15:02     ` Mario.Limonciello
2017-10-05 18:22       ` Andy Shevchenko
2017-10-04 22:48 ` [PATCH v4 05/14] platform/x86: dell-wmi-descriptor: split WMI descriptor into it's own driver Mario Limonciello
2017-10-05  1:09   ` Darren Hart
2017-10-05  5:29     ` Andy Shevchenko
2017-10-05  7:11       ` Darren Hart
2017-10-05  8:47         ` Andy Shevchenko
2017-10-05 13:59           ` Mario.Limonciello
2017-10-05 14:14             ` Darren Hart
2017-10-05 14:47               ` Mario.Limonciello
2017-10-05 17:22                 ` Darren Hart
2017-10-05 17:32                   ` Mario.Limonciello
2017-10-05  5:34   ` Andy Shevchenko
2017-10-05 17:04     ` Mario.Limonciello
2017-10-04 22:48 ` [PATCH v4 06/14] platform/x86: wmi: Don't allow drivers to get each other's GUIDs Mario Limonciello
2017-10-04 22:48 ` [PATCH v4 07/14] platform/x86: dell-smbios: only run if proper oem string is detected Mario Limonciello
2017-10-04 22:48 ` [PATCH v4 08/14] platform/x86: dell-smbios: Add a sysfs interface for SMBIOS tokens Mario Limonciello
2017-10-05  8:49   ` Andy Shevchenko
2017-10-05 13:58     ` Mario.Limonciello
2017-10-05 14:22       ` Andy Shevchenko
2017-10-04 22:48 ` [PATCH v4 09/14] platform/x86: dell-smbios: Introduce dispatcher for SMM calls Mario Limonciello
2017-10-05  1:57   ` Darren Hart
2017-10-05 15:04     ` Mario.Limonciello
2017-10-04 22:48 ` [PATCH v4 10/14] platform/x86: dell-smbios-smm: test for WSMT Mario Limonciello
2017-10-05  1:59   ` Darren Hart
2017-10-04 22:48 ` [PATCH v4 11/14] platform/x86: dell-smbios-wmi: Add new WMI dispatcher driver Mario Limonciello
2017-10-05  2:14   ` Darren Hart
2017-10-05 15:12     ` Mario.Limonciello
2017-10-05 17:57       ` Darren Hart
2017-10-05 19:47         ` Mario.Limonciello
2017-10-06 16:44           ` Darren Hart
2017-10-06 16:47             ` Mario.Limonciello
2017-10-04 22:48 ` [PATCH v4 12/14] platform/x86: wmi: create character devices when requested by drivers Mario Limonciello
2017-10-05  2:33   ` Darren Hart
2017-10-05  7:16   ` Greg KH
2017-10-05 14:35     ` Mario.Limonciello
2017-10-05 15:42       ` Greg KH
2017-10-05 15:51         ` Pali Rohár
2017-10-05 16:26           ` Greg KH
2017-10-05 17:39             ` Darren Hart
2017-10-05 18:47               ` Greg KH
2017-10-05 19:03                 ` Mario.Limonciello
2017-10-05 19:09                   ` Greg KH
2017-10-05 19:32                     ` Pali Rohár
2017-10-05 19:39                       ` Mario.Limonciello
2017-10-05 19:34                     ` Mario.Limonciello
2017-10-05 20:58                     ` Darren Hart
2017-10-05 20:51                   ` Darren Hart [this message]
2017-10-04 22:48 ` [PATCH v4 13/14] platform/x86: dell-smbios-wmi: introduce userspace interface Mario Limonciello
2017-10-05  7:23   ` Greg KH
2017-10-05 16:28     ` Mario.Limonciello
2017-10-05 16:34       ` Pali Rohár
2017-10-05 16:40       ` Greg KH
2017-10-05  7:33   ` Greg KH
2017-10-05 16:37     ` Mario.Limonciello
2017-10-05 13:59   ` Alan Cox
2017-10-05 14:22     ` Mario.Limonciello
2017-10-05 15:44       ` Greg KH
2017-10-05 15:56         ` Pali Rohár
2017-10-05 16:28           ` Greg KH
2017-10-05 16:48             ` Mario.Limonciello
2017-10-10 19:40               ` Alan Cox
2017-10-10 19:51                 ` Mario.Limonciello
2017-10-04 22:48 ` [PATCH v4 14/14] platform/x86: Kconfig: Set default for dell-smbios to ACPI_WMI Mario Limonciello
2017-10-05  0:09 ` [PATCH v4 00/14] Introduce support for Dell SMBIOS over WMI Darren Hart
2017-10-05  9:00   ` Andy Shevchenko

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=20171005205133.GA12321@fury \
    --to=dvhart@infradead.org \
    --cc=Mario.Limonciello@dell.com \
    --cc=andy.shevchenko@gmail.com \
    --cc=greg@kroah.com \
    --cc=hch@lst.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luto@kernel.org \
    --cc=mjg59@google.com \
    --cc=pali.rohar@gmail.com \
    --cc=platform-driver-x86@vger.kernel.org \
    --cc=quasisec@google.com \
    --cc=rjw@rjwysocki.net \
    /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