Skip to content

Commit

Permalink
platform/x86: dell-smbios: Introduce dispatcher for SMM calls
Browse files Browse the repository at this point in the history
This splits up the dell-smbios driver into two drivers:
* dell-smbios
* dell-smbios-smm

dell-smbios can operate with multiple different dispatcher drivers to
perform SMBIOS operations.

Also modify the interface that dell-laptop and dell-wmi use align to this
model more closely.  Rather than a single global buffer being allocated
for all drivers, each driver will allocate and be responsible for it's own
buffer. The pointer will be passed to the calling function and each
dispatcher driver will then internally copy it to the proper location to
perform it's call.

Add defines for calls used by these methods in the dell-smbios.h header
for tracking purposes.

Signed-off-by: Mario Limonciello <mario.limonciello@dell.com>
Reviewed-by: Edward O'Callaghan <quasisec@google.com>
Signed-off-by: Darren Hart (VMware) <dvhart@infradead.org>
  • Loading branch information
Mario Limonciello authored and Darren Hart (VMware) committed Nov 3, 2017
1 parent 33b9ca1 commit 549b493
Show file tree
Hide file tree
Showing 8 changed files with 398 additions and 248 deletions.
6 changes: 6 additions & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -3985,6 +3985,12 @@ L: platform-driver-x86@vger.kernel.org
S: Maintained
F: drivers/platform/x86/dell-smbios.*

DELL SMBIOS SMM DRIVER
M: Mario Limonciello <mario.limonciello@dell.com>
L: platform-driver-x86@vger.kernel.org
S: Maintained
F: drivers/platform/x86/dell-smbios-smm.c

DELL LAPTOP DRIVER
M: Matthew Garrett <mjg59@srcf.ucam.org>
M: Pali Rohár <pali.rohar@gmail.com>
Expand Down
15 changes: 11 additions & 4 deletions drivers/platform/x86/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -93,12 +93,19 @@ config ASUS_LAPTOP

config DELL_SMBIOS
tristate
select DCDBAS

config DELL_SMBIOS_SMM
tristate "Dell SMBIOS calling interface (SMM implementation)"
depends on DCDBAS
default DCDBAS
select DELL_SMBIOS
---help---
This module provides common functions for kernel modules using
Dell SMBIOS.
This provides an implementation for the Dell SMBIOS calling interface
communicated over SMI/SMM.

If you have a Dell laptop, say Y or M here.
If you have a Dell computer from <=2017 you should say Y or M here.
If you aren't sure and this module doesn't work for your computer
it just won't load.

config DELL_LAPTOP
tristate "Dell Laptop Extras"
Expand Down
1 change: 1 addition & 0 deletions drivers/platform/x86/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ obj-$(CONFIG_MSI_LAPTOP) += msi-laptop.o
obj-$(CONFIG_ACPI_CMPC) += classmate-laptop.o
obj-$(CONFIG_COMPAL_LAPTOP) += compal-laptop.o
obj-$(CONFIG_DELL_SMBIOS) += dell-smbios.o
obj-$(CONFIG_DELL_SMBIOS_SMM) += dell-smbios-smm.o
obj-$(CONFIG_DELL_LAPTOP) += dell-laptop.o
obj-$(CONFIG_DELL_WMI) += dell-wmi.o
obj-$(CONFIG_DELL_WMI_DESCRIPTOR) += dell-wmi-descriptor.o
Expand Down
Loading

0 comments on commit 549b493

Please sign in to comment.