Skip to content

Commit

Permalink
vfio: platform: Do not pass return buffer to ACPI _RST method
Browse files Browse the repository at this point in the history
[ Upstream commit e67e070 ]

The ACPI _RST method has no return value, there's no need to pass a return
buffer to acpi_evaluate_object().

Fixes: d30daa3 ("vfio: platform: call _RST method when using ACPI")
Signed-off-by: Rafael Mendonca <[email protected]>
Reviewed-by: Eric Auger <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Alex Williamson <[email protected]>
Signed-off-by: Sasha Levin <[email protected]>
  • Loading branch information
rafaelmsoares authored and gregkh committed Dec 31, 2022
1 parent abaedb6 commit f0865e4
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/vfio/platform/vfio_platform_common.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,11 @@ static int vfio_platform_acpi_call_reset(struct vfio_platform_device *vdev,
const char **extra_dbg)
{
#ifdef CONFIG_ACPI
struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL };
struct device *dev = vdev->device;
acpi_handle handle = ACPI_HANDLE(dev);
acpi_status acpi_ret;

acpi_ret = acpi_evaluate_object(handle, "_RST", NULL, &buffer);
acpi_ret = acpi_evaluate_object(handle, "_RST", NULL, NULL);
if (ACPI_FAILURE(acpi_ret)) {
if (extra_dbg)
*extra_dbg = acpi_format_exception(acpi_ret);
Expand Down

0 comments on commit f0865e4

Please sign in to comment.