Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3a83f992 authored by Rafael J. Wysocki's avatar Rafael J. Wysocki
Browse files

ACPI: Eliminate the DEVICE_ACPI_HANDLE() macro



Since DEVICE_ACPI_HANDLE() is now literally identical to
ACPI_HANDLE(), replace it with the latter everywhere and drop its
definition from include/acpi.h.

Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 7b199811
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -544,7 +544,7 @@ static int acpi_dev_pm_get_state(struct device *dev, struct acpi_device *adev,
 */
int acpi_pm_device_sleep_state(struct device *dev, int *d_min_p, int d_max_in)
{
	acpi_handle handle = DEVICE_ACPI_HANDLE(dev);
	acpi_handle handle = ACPI_HANDLE(dev);
	struct acpi_device *adev;
	int ret, d_min, d_max;

@@ -652,7 +652,7 @@ int acpi_pm_device_run_wake(struct device *phys_dev, bool enable)
	if (!device_run_wake(phys_dev))
		return -EINVAL;

	handle = DEVICE_ACPI_HANDLE(phys_dev);
	handle = ACPI_HANDLE(phys_dev);
	if (!handle || acpi_bus_get_device(handle, &adev)) {
		dev_dbg(phys_dev, "ACPI handle without context in %s!\n",
			__func__);
@@ -696,7 +696,7 @@ int acpi_pm_device_sleep_wake(struct device *dev, bool enable)
	if (!device_can_wakeup(dev))
		return -EINVAL;

	handle = DEVICE_ACPI_HANDLE(dev);
	handle = ACPI_HANDLE(dev);
	if (!handle || acpi_bus_get_device(handle, &adev)) {
		dev_dbg(dev, "ACPI handle without context in %s!\n", __func__);
		return -ENODEV;
@@ -718,7 +718,7 @@ int acpi_pm_device_sleep_wake(struct device *dev, bool enable)
 */
struct acpi_device *acpi_dev_pm_get_node(struct device *dev)
{
	acpi_handle handle = DEVICE_ACPI_HANDLE(dev);
	acpi_handle handle = ACPI_HANDLE(dev);
	struct acpi_device *adev;

	return handle && !acpi_bus_get_device(handle, &adev) ? adev : NULL;
+1 −1
Original line number Diff line number Diff line
@@ -196,7 +196,7 @@ static bool intel_dsm_pci_probe(struct pci_dev *pdev)
	acpi_handle dhandle;
	int ret;

	dhandle = DEVICE_ACPI_HANDLE(&pdev->dev);
	dhandle = ACPI_HANDLE(&pdev->dev);
	if (!dhandle)
		return false;

+1 −1
Original line number Diff line number Diff line
@@ -289,7 +289,7 @@ static void intel_didl_outputs(struct drm_device *dev)
	u32 temp;
	int i = 0;

	handle = DEVICE_ACPI_HANDLE(&dev->pdev->dev);
	handle = ACPI_HANDLE(&dev->pdev->dev);
	if (!handle || acpi_bus_get_device(handle, &acpi_dev))
		return;

+1 −1
Original line number Diff line number Diff line
@@ -116,7 +116,7 @@ mxm_shadow_dsm(struct nouveau_mxm *mxm, u8 version)
	acpi_handle handle;
	int ret;

	handle = DEVICE_ACPI_HANDLE(&device->pdev->dev);
	handle = ACPI_HANDLE(&device->pdev->dev);
	if (!handle)
		return false;

+3 −3
Original line number Diff line number Diff line
@@ -256,7 +256,7 @@ static int nouveau_dsm_pci_probe(struct pci_dev *pdev)
	acpi_handle dhandle;
	int retval = 0;

	dhandle = DEVICE_ACPI_HANDLE(&pdev->dev);
	dhandle = ACPI_HANDLE(&pdev->dev);
	if (!dhandle)
		return false;

@@ -404,7 +404,7 @@ bool nouveau_acpi_rom_supported(struct pci_dev *pdev)
	if (!nouveau_dsm_priv.dsm_detected && !nouveau_dsm_priv.optimus_detected)
		return false;

	dhandle = DEVICE_ACPI_HANDLE(&pdev->dev);
	dhandle = ACPI_HANDLE(&pdev->dev);
	if (!dhandle)
		return false;

@@ -438,7 +438,7 @@ nouveau_acpi_edid(struct drm_device *dev, struct drm_connector *connector)
		return NULL;
	}

	handle = DEVICE_ACPI_HANDLE(&dev->pdev->dev);
	handle = ACPI_HANDLE(&dev->pdev->dev);
	if (!handle)
		return NULL;

Loading