scan.c (cf5c5763eb531ff5120111ad300126e926fb5a56) scan.c (ac2a3feefad549814f5e7cca30be07a255c8494a)
1// SPDX-License-Identifier: GPL-2.0-only
2/*
3 * scan.c - support for transforming the ACPI namespace into individual objects
4 */
5
6#define pr_fmt(fmt) "ACPI: " fmt
7
8#include <linux/module.h>

--- 574 unchanged lines hidden (view full) ---

583 (void **)&adev, callback);
584 if (ACPI_FAILURE(status) || !adev) {
585 acpi_handle_debug(handle, "No context!\n");
586 return NULL;
587 }
588 return adev;
589}
590
1// SPDX-License-Identifier: GPL-2.0-only
2/*
3 * scan.c - support for transforming the ACPI namespace into individual objects
4 */
5
6#define pr_fmt(fmt) "ACPI: " fmt
7
8#include <linux/module.h>

--- 574 unchanged lines hidden (view full) ---

583 (void **)&adev, callback);
584 if (ACPI_FAILURE(status) || !adev) {
585 acpi_handle_debug(handle, "No context!\n");
586 return NULL;
587 }
588 return adev;
589}
590
591int acpi_bus_get_device(acpi_handle handle, struct acpi_device **device)
592{
593 if (!device)
594 return -EINVAL;
595
596 *device = handle_to_device(handle, NULL);
597 if (!*device)
598 return -ENODEV;
599
600 return 0;
601}
602EXPORT_SYMBOL(acpi_bus_get_device);
603
604/**
605 * acpi_fetch_acpi_dev - Retrieve ACPI device object.
606 * @handle: ACPI handle associated with the requested ACPI device object.
607 *
608 * Return a pointer to the ACPI device object associated with @handle, if
609 * present, or NULL otherwise.
610 */
611struct acpi_device *acpi_fetch_acpi_dev(acpi_handle handle)

--- 2094 unchanged lines hidden ---
591/**
592 * acpi_fetch_acpi_dev - Retrieve ACPI device object.
593 * @handle: ACPI handle associated with the requested ACPI device object.
594 *
595 * Return a pointer to the ACPI device object associated with @handle, if
596 * present, or NULL otherwise.
597 */
598struct acpi_device *acpi_fetch_acpi_dev(acpi_handle handle)

--- 2094 unchanged lines hidden ---