// SPDX-License-Identifier: GPL-2.0-only /* * acpi_lpat.c - LPAT table processing functions * * Copyright (C) 2015 Intel Corporation. All rights reserved. */ #include <linux/export.h> #include <linux/acpi.h> #include <acpi/acpi_lpat.h> /** * acpi_lpat_raw_to_temp(): Return temperature from raw value through * LPAT conversion table * * @lpat_table: the temperature_raw mapping table structure * @raw: the raw value, used as a key to get the temperature from the * above mapping table * * A positive converted temperature value will be returned on success, * a negative errno will be returned in error cases. */ int acpi_lpat_raw_to_temp(struct acpi_lpat_conversion_table *lpat_table, int raw) { … } EXPORT_SYMBOL_GPL(…); /** * acpi_lpat_temp_to_raw(): Return raw value from temperature through * LPAT conversion table * * @lpat_table: the temperature_raw mapping table * @temp: the temperature, used as a key to get the raw value from the * above mapping table * * The raw value will be returned on success, * a negative errno will be returned in error cases. */ int acpi_lpat_temp_to_raw(struct acpi_lpat_conversion_table *lpat_table, int temp) { … } EXPORT_SYMBOL_GPL(…); /** * acpi_lpat_get_conversion_table(): Parse ACPI LPAT table if present. * * @handle: Handle to acpi device * * Parse LPAT table to a struct of type acpi_lpat_table. On success * it returns a pointer to newly allocated table. This table must * be freed by the caller when finished processing, using a call to * acpi_lpat_free_conversion_table. */ struct acpi_lpat_conversion_table *acpi_lpat_get_conversion_table(acpi_handle handle) { … } EXPORT_SYMBOL_GPL(…); /** * acpi_lpat_free_conversion_table(): Free LPAT table. * * @lpat_table: the temperature_raw mapping table structure * * Frees the LPAT table previously allocated by a call to * acpi_lpat_get_conversion_table. */ void acpi_lpat_free_conversion_table(struct acpi_lpat_conversion_table *lpat_table) { … } EXPORT_SYMBOL_GPL(…);