[PATCH v11 09/15] platform/x86: dell-smbios: Introduce dispatcher for SMM calls

2017-10-20 Thread Mario Limonciello
by these methods in the dell-smbios.h header for tracking purposes. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- MAINTAINERS| 6 + drivers/platform/x86/Kconfig | 15

[PATCH v11 09/15] platform/x86: dell-smbios: Introduce dispatcher for SMM calls

2017-10-20 Thread Mario Limonciello
by these methods in the dell-smbios.h header for tracking purposes. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- MAINTAINERS| 6 + drivers/platform/x86/Kconfig | 15 +- drivers/platform/x86/Makefile | 1 + drivers/platform

[PATCH v11 01/15] platform/x86: wmi: Add new method wmidev_evaluate_method

2017-10-20 Thread Mario Limonciello
Drivers properly using the wmibus can pass their wmi_device pointer rather than the GUID back to the WMI bus to evaluate the proper methods. Any "new" drivers added that use the WMI bus should use this rather than the old wmi_evaluate_method that would take the GUID. Signed-off

[PATCH v11 01/15] platform/x86: wmi: Add new method wmidev_evaluate_method

2017-10-20 Thread Mario Limonciello
Drivers properly using the wmibus can pass their wmi_device pointer rather than the GUID back to the WMI bus to evaluate the proper methods. Any "new" drivers added that use the WMI bus should use this rather than the old wmi_evaluate_method that would take the GUID. Signed-off

[PATCH v11 02/15] platform/x86: dell-wmi: increase severity of some failures

2017-10-20 Thread Mario Limonciello
of the data should not be relied upon. For the remaining data set vectors, continue to notate a warning in undefined results, but as those are fields that the descriptor intended to refer to other applications, don't fail if they're new values. Signed-off-by: Mario Limonciello <mario.limon

[PATCH v11 02/15] platform/x86: dell-wmi: increase severity of some failures

2017-10-20 Thread Mario Limonciello
of the data should not be relied upon. For the remaining data set vectors, continue to notate a warning in undefined results, but as those are fields that the descriptor intended to refer to other applications, don't fail if they're new values. Signed-off-by: Mario Limonciello Reviewed-by: Edward

[PATCH v11 15/15] tools/wmi: add a sample for dell smbios communication over WMI

2017-10-20 Thread Mario Limonciello
This application uses the character device /dev/wmi/dell-smbios to perform SMBIOS communications from userspace. It offers demonstrations of a few simple tasks: - Running a class/select command - Querying a token value - Activating a token Signed-off-by: Mario Limonciello <mario.limon

[PATCH v11 15/15] tools/wmi: add a sample for dell smbios communication over WMI

2017-10-20 Thread Mario Limonciello
This application uses the character device /dev/wmi/dell-smbios to perform SMBIOS communications from userspace. It offers demonstrations of a few simple tasks: - Running a class/select command - Querying a token value - Activating a token Signed-off-by: Mario Limonciello Reviewed-by: Edward

[PATCH v11 04/15] platform/x86: dell-wmi: don't check length returned

2017-10-20 Thread Mario Limonciello
This is intended to be variable and provided by the platform. Some platforms this year will be adopting a 32k WMI buffer, so don't complain when encountering those platforms or any other future changes. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Cal

[PATCH v11 04/15] platform/x86: dell-wmi: don't check length returned

2017-10-20 Thread Mario Limonciello
This is intended to be variable and provided by the platform. Some platforms this year will be adopting a 32k WMI buffer, so don't complain when encountering those platforms or any other future changes. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan Reviewed-by: Pali Rohár

[PATCH v11 05/15] platform/x86: dell-wmi-descriptor: split WMI descriptor into it's own driver

2017-10-20 Thread Mario Limonciello
. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- MAINTAINERS| 5 + drivers/platform/x86/Kconfig | 5 + drivers/platform/x86/Makefile | 1 + drivers/platf

[PATCH v11 05/15] platform/x86: dell-wmi-descriptor: split WMI descriptor into it's own driver

2017-10-20 Thread Mario Limonciello
. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- MAINTAINERS| 5 + drivers/platform/x86/Kconfig | 5 + drivers/platform/x86/Makefile | 1 + drivers/platform/x86/dell-wmi-descriptor.c | 170

[PATCH v10 06/15] platform/x86: wmi: Don't allow drivers to get each other's GUIDs

2017-10-19 Thread Mario Limonciello
-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> Reviewed-by: Pali Rohár <pali.ro...@gmail.com> --- drivers/platform/x86/wmi.c | 17 - include/linux/wmi.h| 4 2 files changed, 21 deleti

[PATCH v10 06/15] platform/x86: wmi: Don't allow drivers to get each other's GUIDs

2017-10-19 Thread Mario Limonciello
-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan Reviewed-by: Pali Rohár --- drivers/platform/x86/wmi.c | 17 - include/linux/wmi.h| 4 2 files changed, 21 deletions(-) diff --git a/drivers/platform/x86/wmi.c b/drivers/platform/x86/wmi.c index 4d73a87c2ddf

[PATCH v10 01/15] platform/x86: wmi: Add new method wmidev_evaluate_method

2017-10-19 Thread Mario Limonciello
Drivers properly using the wmibus can pass their wmi_device pointer rather than the GUID back to the WMI bus to evaluate the proper methods. Any "new" drivers added that use the WMI bus should use this rather than the old wmi_evaluate_method that would take the GUID. Signed-off

[PATCH v10 01/15] platform/x86: wmi: Add new method wmidev_evaluate_method

2017-10-19 Thread Mario Limonciello
Drivers properly using the wmibus can pass their wmi_device pointer rather than the GUID back to the WMI bus to evaluate the proper methods. Any "new" drivers added that use the WMI bus should use this rather than the old wmi_evaluate_method that would take the GUID. Signed-off

[PATCH v10 00/15] Introduce support for Dell SMBIOS over WMI

2017-10-19 Thread Mario Limonciello
with multiple different ioctl methods. * Default WMI interface to 32k (This would normally be queried via MOF, but that's not possible yet) * Create separate buffers for WMI and SMI. If WMI is available, free the SMI buffer. * Reorder patches so all fixups come first in the series. Mario Li

[PATCH v10 00/15] Introduce support for Dell SMBIOS over WMI

2017-10-19 Thread Mario Limonciello
with multiple different ioctl methods. * Default WMI interface to 32k (This would normally be queried via MOF, but that's not possible yet) * Create separate buffers for WMI and SMI. If WMI is available, free the SMI buffer. * Reorder patches so all fixups come first in the series. Mario Li

[PATCH v10 05/15] platform/x86: dell-wmi-descriptor: split WMI descriptor into it's own driver

2017-10-19 Thread Mario Limonciello
. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- MAINTAINERS| 5 + drivers/platform/x86/Kconfig | 5 + drivers/platform/x86/Makefile | 1 + drivers/platf

[PATCH v10 05/15] platform/x86: dell-wmi-descriptor: split WMI descriptor into it's own driver

2017-10-19 Thread Mario Limonciello
. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- MAINTAINERS| 5 + drivers/platform/x86/Kconfig | 5 + drivers/platform/x86/Makefile | 1 + drivers/platform/x86/dell-wmi-descriptor.c | 168

[PATCH v10 07/15] platform/x86: dell-smbios: only run if proper oem string is detected

2017-10-19 Thread Mario Limonciello
The proper way to indicate that a system is a 'supported' Dell System is by the presence of this string in OEM strings. Allowing the driver to load on non-Dell systems will have undefined results. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Cal

[PATCH v10 07/15] platform/x86: dell-smbios: only run if proper oem string is detected

2017-10-19 Thread Mario Limonciello
The proper way to indicate that a system is a 'supported' Dell System is by the presence of this string in OEM strings. Allowing the driver to load on non-Dell systems will have undefined results. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- drivers/platform/x86/dell

[PATCH v10 09/15] platform/x86: dell-smbios: Introduce dispatcher for SMM calls

2017-10-19 Thread Mario Limonciello
by these methods in the dell-smbios.h header for tracking purposes. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- MAINTAINERS| 6 + drivers/platform/x86/Kconfig | 15

[PATCH v10 09/15] platform/x86: dell-smbios: Introduce dispatcher for SMM calls

2017-10-19 Thread Mario Limonciello
by these methods in the dell-smbios.h header for tracking purposes. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- MAINTAINERS| 6 + drivers/platform/x86/Kconfig | 15 +- drivers/platform/x86/Makefile | 1 + drivers/platform

[PATCH v10 12/15] platform/x86: dell-smbios: Add filtering support

2017-10-19 Thread Mario Limonciello
the request. - If the process provides CAP_SYS_RAWIO the whitelist will be overridden. When an item is not in the blacklist, or whitelist and the process is run with insufficient capabilities the call will be rejected. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by:

[PATCH v10 12/15] platform/x86: dell-smbios: Add filtering support

2017-10-19 Thread Mario Limonciello
the request. - If the process provides CAP_SYS_RAWIO the whitelist will be overridden. When an item is not in the blacklist, or whitelist and the process is run with insufficient capabilities the call will be rejected. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- drivers

[PATCH v10 08/15] platform/x86: dell-smbios: Add a sysfs interface for SMBIOS tokens

2017-10-19 Thread Mario Limonciello
was missing for this driver. Add myself and Pali to maintainers list for it. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- .../ABI/testing/sysfs-platform-dell-smbios | 21 ++

[PATCH v10 08/15] platform/x86: dell-smbios: Add a sysfs interface for SMBIOS tokens

2017-10-19 Thread Mario Limonciello
was missing for this driver. Add myself and Pali to maintainers list for it. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- .../ABI/testing/sysfs-platform-dell-smbios | 21 ++ MAINTAINERS| 7 + drivers/platform/x86/dell-smbios.c

[PATCH v10 15/15] tools/wmi: add a sample for dell smbios communication over WMI

2017-10-19 Thread Mario Limonciello
This application uses the character device /dev/wmi/dell-smbios to perform SMBIOS communications from userspace. It offers demonstrations of a few simple tasks: - Running a class/select command - Querying a token value - Activating a token Signed-off-by: Mario Limonciello <mario.limon

[PATCH v10 15/15] tools/wmi: add a sample for dell smbios communication over WMI

2017-10-19 Thread Mario Limonciello
This application uses the character device /dev/wmi/dell-smbios to perform SMBIOS communications from userspace. It offers demonstrations of a few simple tasks: - Running a class/select command - Querying a token value - Activating a token Signed-off-by: Mario Limonciello Reviewed-by: Edward

[PATCH v10 10/15] platform/x86: dell-smbios-wmi: Add new WMI dispatcher driver

2017-10-19 Thread Mario Limonciello
this to operate over WMI-ACPI will use an ACPI OperationRegion for a buffer of data storage when SMM calls are performed. This is a safer approach to use in kernel drivers as the SMM will only have access to that OperationRegion. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Re

[PATCH v10 10/15] platform/x86: dell-smbios-wmi: Add new WMI dispatcher driver

2017-10-19 Thread Mario Limonciello
this to operate over WMI-ACPI will use an ACPI OperationRegion for a buffer of data storage when SMM calls are performed. This is a safer approach to use in kernel drivers as the SMM will only have access to that OperationRegion. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan

[PATCH v10 14/15] platform/x86: dell-smbios-wmi: introduce userspace interface

2017-10-19 Thread Mario Limonciello
filtering functionality will be used to prevent access to certain tokens and calls. All whitelisted commands and tokens are now shared out to userspace so applications don't need to define them in their own headers. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by:

[PATCH v10 14/15] platform/x86: dell-smbios-wmi: introduce userspace interface

2017-10-19 Thread Mario Limonciello
filtering functionality will be used to prevent access to certain tokens and calls. All whitelisted commands and tokens are now shared out to userspace so applications don't need to define them in their own headers. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan

[PATCH v10 02/15] platform/x86: dell-wmi: increase severity of some failures

2017-10-19 Thread Mario Limonciello
of the data should not be relied upon. For the remaining data set vectors, continue to notate a warning in undefined results, but as those are fields that the descriptor intended to refer to other applications, don't fail if they're new values. Signed-off-by: Mario Limonciello <mario.limon

[PATCH v10 02/15] platform/x86: dell-wmi: increase severity of some failures

2017-10-19 Thread Mario Limonciello
of the data should not be relied upon. For the remaining data set vectors, continue to notate a warning in undefined results, but as those are fields that the descriptor intended to refer to other applications, don't fail if they're new values. Signed-off-by: Mario Limonciello Reviewed-by: Edward

[PATCH v10 11/15] platform/x86: dell-smbios-smm: test for WSMT

2017-10-19 Thread Mario Limonciello
-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- drivers/platform/x86/dell-smbios-smm.c | 33 + drivers/platform/x86/dell-smbios.h | 2 ++ 2 files changed, 35 insertions(+) diff --g

[PATCH v10 11/15] platform/x86: dell-smbios-smm: test for WSMT

2017-10-19 Thread Mario Limonciello
-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- drivers/platform/x86/dell-smbios-smm.c | 33 + drivers/platform/x86/dell-smbios.h | 2 ++ 2 files changed, 35 insertions(+) diff --git a/drivers/platform/x86/dell-smbios-smm.c b/drivers/platform

[PATCH v10 13/15] platform/x86: wmi: create userspace interface for drivers

2017-10-19 Thread Mario Limonciello
. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> --- MAINTAINERS| 1 + drivers/platform/x86/wmi.c | 206 - include/linux/wmi.h| 6 ++ include/uapi/linux/wmi.h | 26 ++ 4 files changed, 237 insertions

[PATCH v10 13/15] platform/x86: wmi: create userspace interface for drivers

2017-10-19 Thread Mario Limonciello
. Signed-off-by: Mario Limonciello --- MAINTAINERS| 1 + drivers/platform/x86/wmi.c | 206 - include/linux/wmi.h| 6 ++ include/uapi/linux/wmi.h | 26 ++ 4 files changed, 237 insertions(+), 2 deletions(-) create mode

[PATCH v10 03/15] platform/x86: dell-wmi: clean up wmi descriptor check

2017-10-19 Thread Mario Limonciello
Some cases the wrong type was used for errors and checks can be done more cleanly. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> Suggested-by: Andy Shevchenko <andy.shevche...@gmail.com> --- drivers/platf

[PATCH v10 03/15] platform/x86: dell-wmi: clean up wmi descriptor check

2017-10-19 Thread Mario Limonciello
Some cases the wrong type was used for errors and checks can be done more cleanly. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan Suggested-by: Andy Shevchenko --- drivers/platform/x86/dell-wmi.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git

[PATCH v10 04/15] platform/x86: dell-wmi: don't check length returned

2017-10-19 Thread Mario Limonciello
This is intended to be variable and provided by the platform. Some platforms this year will be adopting a 32k WMI buffer, so don't complain when encountering those platforms or any other future changes. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Cal

[PATCH v10 04/15] platform/x86: dell-wmi: don't check length returned

2017-10-19 Thread Mario Limonciello
This is intended to be variable and provided by the platform. Some platforms this year will be adopting a 32k WMI buffer, so don't complain when encountering those platforms or any other future changes. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- drivers/platform/x86

[PATCH v9 04/17] platform/x86: dell-wmi: allow 32k return size in the descriptor

2017-10-17 Thread Mario Limonciello
Some platforms this year will be adopting 32k WMI buffer, so don't complain when encountering those. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- drivers/platform/x86/dell-wmi.c | 4 ++-- 1 file changed,

[PATCH v9 04/17] platform/x86: dell-wmi: allow 32k return size in the descriptor

2017-10-17 Thread Mario Limonciello
Some platforms this year will be adopting 32k WMI buffer, so don't complain when encountering those. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- drivers/platform/x86/dell-wmi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/platform/x86

[PATCH v9 03/17] platform/x86: dell-wmi: clean up wmi descriptor check

2017-10-17 Thread Mario Limonciello
Some cases the wrong type was used for errors and checks can be done more cleanly. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> Suggested-by: Andy Shevchenko <andy.shevche...@gmail.com> --- drivers/platf

[PATCH v9 03/17] platform/x86: dell-wmi: clean up wmi descriptor check

2017-10-17 Thread Mario Limonciello
Some cases the wrong type was used for errors and checks can be done more cleanly. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan Suggested-by: Andy Shevchenko --- drivers/platform/x86/dell-wmi.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git

[PATCH v9 02/17] platform/x86: dell-wmi: increase severity of some failures

2017-10-17 Thread Mario Limonciello
of the data should not be relied upon. For the remaining data set vectors, continue to notate a warning in undefined results, but as those are fields that the descriptor intended to refer to other applications, don't fail if they're new values. Signed-off-by: Mario Limonciello <mario.limon

[PATCH v9 02/17] platform/x86: dell-wmi: increase severity of some failures

2017-10-17 Thread Mario Limonciello
of the data should not be relied upon. For the remaining data set vectors, continue to notate a warning in undefined results, but as those are fields that the descriptor intended to refer to other applications, don't fail if they're new values. Signed-off-by: Mario Limonciello Reviewed-by: Edward

[PATCH v9 01/17] platform/x86: wmi: Add new method wmidev_evaluate_method

2017-10-17 Thread Mario Limonciello
Drivers properly using the wmibus can pass their wmi_device pointer rather than the GUID back to the WMI bus to evaluate the proper methods. Any "new" drivers added that use the WMI bus should use this rather than the old wmi_evaluate_method that would take the GUID. Signed-off

[PATCH v9 07/17] platform/x86: dell-smbios: only run if proper oem string is detected

2017-10-17 Thread Mario Limonciello
The proper way to indicate that a system is a 'supported' Dell System is by the presence of this string in OEM strings. Allowing the driver to load on non-Dell systems will have undefined results. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Cal

[PATCH v9 01/17] platform/x86: wmi: Add new method wmidev_evaluate_method

2017-10-17 Thread Mario Limonciello
Drivers properly using the wmibus can pass their wmi_device pointer rather than the GUID back to the WMI bus to evaluate the proper methods. Any "new" drivers added that use the WMI bus should use this rather than the old wmi_evaluate_method that would take the GUID. Signed-off

[PATCH v9 07/17] platform/x86: dell-smbios: only run if proper oem string is detected

2017-10-17 Thread Mario Limonciello
The proper way to indicate that a system is a 'supported' Dell System is by the presence of this string in OEM strings. Allowing the driver to load on non-Dell systems will have undefined results. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- drivers/platform/x86/dell

[PATCH v9 06/17] platform/x86: wmi: Don't allow drivers to get each other's GUIDs

2017-10-17 Thread Mario Limonciello
-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- drivers/platform/x86/wmi.c | 17 - include/linux/wmi.h| 4 2 files changed, 21 deletions(-) diff --git a/drivers/platform/x86/wmi.c b/drivers/

[PATCH v9 06/17] platform/x86: wmi: Don't allow drivers to get each other's GUIDs

2017-10-17 Thread Mario Limonciello
-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- drivers/platform/x86/wmi.c | 17 - include/linux/wmi.h| 4 2 files changed, 21 deletions(-) diff --git a/drivers/platform/x86/wmi.c b/drivers/platform/x86/wmi.c index 4d73a87c2ddf..bcb41c1c7f52 100644

[PATCH v9 05/17] platform/x86: dell-wmi-descriptor: split WMI descriptor into it's own driver

2017-10-17 Thread Mario Limonciello
. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- MAINTAINERS| 5 + drivers/platform/x86/Kconfig | 5 + drivers/platform/x86/Makefile | 1 + drivers/platf

[PATCH v9 05/17] platform/x86: dell-wmi-descriptor: split WMI descriptor into it's own driver

2017-10-17 Thread Mario Limonciello
. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- MAINTAINERS| 5 + drivers/platform/x86/Kconfig | 5 + drivers/platform/x86/Makefile | 1 + drivers/platform/x86/dell-wmi-descriptor.c | 162

[PATCH v9 11/17] platform/x86: dell-smbios-smm: test for WSMT

2017-10-17 Thread Mario Limonciello
-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- drivers/platform/x86/dell-smbios-smm.c | 33 + drivers/platform/x86/dell-smbios.h | 2 ++ 2 files changed, 35 insertions(+) diff --g

[PATCH v9 11/17] platform/x86: dell-smbios-smm: test for WSMT

2017-10-17 Thread Mario Limonciello
-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- drivers/platform/x86/dell-smbios-smm.c | 33 + drivers/platform/x86/dell-smbios.h | 2 ++ 2 files changed, 35 insertions(+) diff --git a/drivers/platform/x86/dell-smbios-smm.c b/drivers/platform

[PATCH v9 09/17] platform/x86: dell-smbios: Introduce dispatcher for SMM calls

2017-10-17 Thread Mario Limonciello
by these methods in the dell-smbios.h header for tracking purposes. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- MAINTAINERS| 6 + drivers/platform/x86/Kconfig | 15

[PATCH v9 09/17] platform/x86: dell-smbios: Introduce dispatcher for SMM calls

2017-10-17 Thread Mario Limonciello
by these methods in the dell-smbios.h header for tracking purposes. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- MAINTAINERS| 6 + drivers/platform/x86/Kconfig | 15 +- drivers/platform/x86/Makefile | 1 + drivers/platform

[PATCH v9 00/17] Introduce support for Dell SMBIOS over WMI

2017-10-17 Thread Mario Limonciello
ent ioctl methods. * Default WMI interface to 32k (This would normally be queried via MOF, but that's not possible yet) * Create separate buffers for WMI and SMI. If WMI is available, free the SMI buffer. * Reorder patches so all fixups come first in the series. Mario Limonciello (17):

[PATCH v9 00/17] Introduce support for Dell SMBIOS over WMI

2017-10-17 Thread Mario Limonciello
ent ioctl methods. * Default WMI interface to 32k (This would normally be queried via MOF, but that's not possible yet) * Create separate buffers for WMI and SMI. If WMI is available, free the SMI buffer. * Reorder patches so all fixups come first in the series. Mario Limonciello (17):

[PATCH v9 10/17] platform/x86: dell-smbios-wmi: Add new WMI dispatcher driver

2017-10-17 Thread Mario Limonciello
this to operate over WMI-ACPI will use an ACPI OperationRegion for a buffer of data storage when SMM calls are performed. This is a safer approach to use in kernel drivers as the SMM will only have access to that OperationRegion. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Re

[PATCH v9 13/17] platform/x86: wmi: Add sysfs attribute for required_buffer_size

2017-10-17 Thread Mario Limonciello
Method type WMI objects need to be able to describe the size of the interface that they will expect to use. Export this information to sysfs and allow vendor drivers to set it. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@g

[PATCH v9 10/17] platform/x86: dell-smbios-wmi: Add new WMI dispatcher driver

2017-10-17 Thread Mario Limonciello
this to operate over WMI-ACPI will use an ACPI OperationRegion for a buffer of data storage when SMM calls are performed. This is a safer approach to use in kernel drivers as the SMM will only have access to that OperationRegion. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan

[PATCH v9 13/17] platform/x86: wmi: Add sysfs attribute for required_buffer_size

2017-10-17 Thread Mario Limonciello
Method type WMI objects need to be able to describe the size of the interface that they will expect to use. Export this information to sysfs and allow vendor drivers to set it. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- drivers/platform/x86/wmi.c | 31

[PATCH v9 08/17] platform/x86: dell-smbios: Add a sysfs interface for SMBIOS tokens

2017-10-17 Thread Mario Limonciello
was missing for this driver. Add myself and Pali to maintainers list for it. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- .../ABI/testing/sysfs-platform-dell-smbios | 21 ++

[PATCH v9 08/17] platform/x86: dell-smbios: Add a sysfs interface for SMBIOS tokens

2017-10-17 Thread Mario Limonciello
was missing for this driver. Add myself and Pali to maintainers list for it. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- .../ABI/testing/sysfs-platform-dell-smbios | 21 ++ MAINTAINERS| 7 + drivers/platform/x86/dell-smbios.c

[PATCH v9 15/17] platform/x86: dell-smbios-wmi: introduce userspace interface

2017-10-17 Thread Mario Limonciello
ctionality to prevent access to certain tokens and calls. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- Documentation/ABI/testing/dell-smbios-wmi | 41 drivers/platform/x86/del

[PATCH v9 15/17] platform/x86: dell-smbios-wmi: introduce userspace interface

2017-10-17 Thread Mario Limonciello
ctionality to prevent access to certain tokens and calls. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- Documentation/ABI/testing/dell-smbios-wmi | 41 drivers/platform/x86/dell-smbios-wmi.c| 81 ++- drivers/platform/x86/del

[PATCH v9 14/17] platform/x86: wmi: create userspace interface for drivers

2017-10-17 Thread Mario Limonciello
driver will clean up the character device. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> --- MAINTAINERS| 1 + drivers/platform/x86/wmi.c | 120 + include

[PATCH v9 14/17] platform/x86: wmi: create userspace interface for drivers

2017-10-17 Thread Mario Limonciello
driver will clean up the character device. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- MAINTAINERS| 1 + drivers/platform/x86/wmi.c | 120 + include/linux/wmi.h| 6 +++ include/uapi/linux/wmi.h | 26

[PATCH v9 16/17] platform/x86: shuffle headers to export for userspace

2017-10-17 Thread Mario Limonciello
All whitelisted commands and tokens should be shared out to userspace so applications don't need to define them in their own headers. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> --- drivers/platform/x86/dell-smbios.h | 19 --- include/uapi/linux

[PATCH v9 17/17] tools/wmi: add a sample for dell smbios communication over WMI

2017-10-17 Thread Mario Limonciello
This application uses the character device /dev/wmi/dell-smbios to perform SMBIOS communications from userspace. It offers demonstrations of a few simple tasks: - Running a class/select command - Querying a token value - Activating a token Signed-off-by: Mario Limonciello <mario.limon

[PATCH v9 16/17] platform/x86: shuffle headers to export for userspace

2017-10-17 Thread Mario Limonciello
All whitelisted commands and tokens should be shared out to userspace so applications don't need to define them in their own headers. Signed-off-by: Mario Limonciello --- drivers/platform/x86/dell-smbios.h | 19 --- include/uapi/linux/wmi.h | 21

[PATCH v9 17/17] tools/wmi: add a sample for dell smbios communication over WMI

2017-10-17 Thread Mario Limonciello
This application uses the character device /dev/wmi/dell-smbios to perform SMBIOS communications from userspace. It offers demonstrations of a few simple tasks: - Running a class/select command - Querying a token value - Activating a token Signed-off-by: Mario Limonciello --- MAINTAINERS

[PATCH v9 12/17] platform/x86: dell-smbios: Add filtering support

2017-10-17 Thread Mario Limonciello
the request. - If the process provides CAP_SYS_RAWIO the whitelist will be overridden. When an item is not in the blacklist, or whitelist and the process is run with insufficient capabilities the call will be rejected. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by:

[PATCH v9 12/17] platform/x86: dell-smbios: Add filtering support

2017-10-17 Thread Mario Limonciello
the request. - If the process provides CAP_SYS_RAWIO the whitelist will be overridden. When an item is not in the blacklist, or whitelist and the process is run with insufficient capabilities the call will be rejected. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan --- drivers

[PATCH v8 01/15] platform/x86: wmi: Add new method wmidev_evaluate_method

2017-10-13 Thread Mario Limonciello
Drivers properly using the wmibus can pass their wmi_device pointer rather than the GUID back to the WMI bus to evaluate the proper methods. Any "new" drivers added that use the WMI bus should use this rather than the old wmi_evaluate_method that would take the GUID. Signed-off

[PATCH v8 01/15] platform/x86: wmi: Add new method wmidev_evaluate_method

2017-10-13 Thread Mario Limonciello
Drivers properly using the wmibus can pass their wmi_device pointer rather than the GUID back to the WMI bus to evaluate the proper methods. Any "new" drivers added that use the WMI bus should use this rather than the old wmi_evaluate_method that would take the GUID. Signed-off

[PATCH v8 04/15] platform/x86: dell-wmi: allow 32k return size in the descriptor

2017-10-13 Thread Mario Limonciello
Some platforms this year will be adopting 32k WMI buffer, so don't complain when encountering those. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> --- drivers/platform/x86/dell-wmi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/platform/x8

[PATCH v8 06/15] platform/x86: wmi: Don't allow drivers to get each other's GUIDs

2017-10-13 Thread Mario Limonciello
-off-by: Mario Limonciello <mario.limoncie...@dell.com> --- drivers/platform/x86/wmi.c | 17 - include/linux/wmi.h| 4 2 files changed, 21 deletions(-) diff --git a/drivers/platform/x86/wmi.c b/drivers/platform/x86/wmi.c index 4d73a87c2ddf..bcb41c1c7f52

[PATCH v8 04/15] platform/x86: dell-wmi: allow 32k return size in the descriptor

2017-10-13 Thread Mario Limonciello
Some platforms this year will be adopting 32k WMI buffer, so don't complain when encountering those. Signed-off-by: Mario Limonciello --- drivers/platform/x86/dell-wmi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/platform/x86/dell-wmi.c b/drivers/platform

[PATCH v8 06/15] platform/x86: wmi: Don't allow drivers to get each other's GUIDs

2017-10-13 Thread Mario Limonciello
-off-by: Mario Limonciello --- drivers/platform/x86/wmi.c | 17 - include/linux/wmi.h| 4 2 files changed, 21 deletions(-) diff --git a/drivers/platform/x86/wmi.c b/drivers/platform/x86/wmi.c index 4d73a87c2ddf..bcb41c1c7f52 100644 --- a/drivers/platform/x86/wmi.c +++ b

[PATCH v8 05/15] platform/x86: dell-wmi-descriptor: split WMI descriptor into it's own driver

2017-10-13 Thread Mario Limonciello
. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> --- MAINTAINERS| 5 + drivers/platform/x86/Kconfig | 5 + drivers/platform/x86/Makefile | 1 + drivers/platform/x86/dell-wmi-descriptor.c

[PATCH v8 05/15] platform/x86: dell-wmi-descriptor: split WMI descriptor into it's own driver

2017-10-13 Thread Mario Limonciello
. Signed-off-by: Mario Limonciello --- MAINTAINERS| 5 + drivers/platform/x86/Kconfig | 5 + drivers/platform/x86/Makefile | 1 + drivers/platform/x86/dell-wmi-descriptor.c | 162 + drivers/platform/x86/dell

[PATCH v8 15/15] platform/x86: dell-smbios-wmi: introduce userspace interface

2017-10-13 Thread Mario Limonciello
ctionality to prevent access to certain tokens and calls. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> --- Documentation/ABI/testing/dell-smbios-wmi | 41 drivers/platform/x86/dell-smbios-wmi.c| 81 ++- drivers/platform/x86/dell-smbi

[PATCH v8 15/15] platform/x86: dell-smbios-wmi: introduce userspace interface

2017-10-13 Thread Mario Limonciello
ctionality to prevent access to certain tokens and calls. Signed-off-by: Mario Limonciello --- Documentation/ABI/testing/dell-smbios-wmi | 41 drivers/platform/x86/dell-smbios-wmi.c| 81 ++- drivers/platform/x86/dell-smbios.h| 11 + include/

[PATCH v8 11/15] platform/x86: dell-smbios-smm: test for WSMT

2017-10-13 Thread Mario Limonciello
-off-by: Mario Limonciello <mario.limoncie...@dell.com> --- drivers/platform/x86/dell-smbios-smm.c | 33 + drivers/platform/x86/dell-smbios.h | 2 ++ 2 files changed, 35 insertions(+) diff --git a/drivers/platform/x86/dell-smbios-smm.c b/drivers/platfo

[PATCH v8 09/15] platform/x86: dell-smbios: Introduce dispatcher for SMM calls

2017-10-13 Thread Mario Limonciello
by these methods in the dell-smbios.h header for tracking purposes. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> --- MAINTAINERS| 6 + drivers/platform/x86/Kconfig | 15 +- drivers/platform/x86/Makefile | 1 + drivers/platfo

[PATCH v8 07/15] platform/x86: dell-smbios: only run if proper oem string is detected

2017-10-13 Thread Mario Limonciello
The proper way to indicate that a system is a 'supported' Dell System is by the presence of this string in OEM strings. Allowing the driver to load on non-Dell systems will have undefined results. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> --- drivers/platform/x8

[PATCH v8 11/15] platform/x86: dell-smbios-smm: test for WSMT

2017-10-13 Thread Mario Limonciello
-off-by: Mario Limonciello --- drivers/platform/x86/dell-smbios-smm.c | 33 + drivers/platform/x86/dell-smbios.h | 2 ++ 2 files changed, 35 insertions(+) diff --git a/drivers/platform/x86/dell-smbios-smm.c b/drivers/platform/x86/dell-smbios-smm.c index

[PATCH v8 09/15] platform/x86: dell-smbios: Introduce dispatcher for SMM calls

2017-10-13 Thread Mario Limonciello
by these methods in the dell-smbios.h header for tracking purposes. Signed-off-by: Mario Limonciello --- MAINTAINERS| 6 + drivers/platform/x86/Kconfig | 15 +- drivers/platform/x86/Makefile | 1 + drivers/platform/x86/dell-laptop.c | 283

[PATCH v8 07/15] platform/x86: dell-smbios: only run if proper oem string is detected

2017-10-13 Thread Mario Limonciello
The proper way to indicate that a system is a 'supported' Dell System is by the presence of this string in OEM strings. Allowing the driver to load on non-Dell systems will have undefined results. Signed-off-by: Mario Limonciello --- drivers/platform/x86/dell-smbios.c | 7 +++ 1 file

[PATCH v8 08/15] platform/x86: dell-smbios: Add a sysfs interface for SMBIOS tokens

2017-10-13 Thread Mario Limonciello
was missing for this driver. Add myself and Pali to maintainers list for it. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> --- .../ABI/testing/sysfs-platform-dell-smbios | 21 ++ MAINTAINERS| 7 + drivers/platform/x86/dell-sm

[PATCH v8 08/15] platform/x86: dell-smbios: Add a sysfs interface for SMBIOS tokens

2017-10-13 Thread Mario Limonciello
was missing for this driver. Add myself and Pali to maintainers list for it. Signed-off-by: Mario Limonciello --- .../ABI/testing/sysfs-platform-dell-smbios | 21 ++ MAINTAINERS| 7 + drivers/platform/x86/dell-smbios.c | 211

[PATCH v8 03/15] platform/x86: dell-wmi: clean up wmi descriptor check

2017-10-13 Thread Mario Limonciello
Some cases the wrong type was used for errors and checks can be done more cleanly. Signed-off-by: Mario Limonciello <mario.limoncie...@dell.com> Reviewed-by: Edward O'Callaghan <quasi...@google.com> Suggested-by: Andy Shevchenko <andy.shevche...@gmail.com> --- drivers/platf

[PATCH v8 03/15] platform/x86: dell-wmi: clean up wmi descriptor check

2017-10-13 Thread Mario Limonciello
Some cases the wrong type was used for errors and checks can be done more cleanly. Signed-off-by: Mario Limonciello Reviewed-by: Edward O'Callaghan Suggested-by: Andy Shevchenko --- drivers/platform/x86/dell-wmi.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git

<    1   2   3   4   5   6   7   8   >