acpi_lpat.h 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. /*
  2. * acpi_lpat.h - LPAT table processing functions
  3. *
  4. * Copyright (C) 2015 Intel Corporation. All rights reserved.
  5. *
  6. * This program is free software; you can redistribute it and/or
  7. * modify it under the terms of the GNU General Public License version
  8. * 2 as published by the Free Software Foundation.
  9. *
  10. * This program is distributed in the hope that it will be useful,
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. * GNU General Public License for more details.
  14. */
  15. #ifndef ACPI_LPAT_H
  16. #define ACPI_LPAT_H
  17. struct acpi_lpat {
  18. int temp;
  19. int raw;
  20. };
  21. struct acpi_lpat_conversion_table {
  22. struct acpi_lpat *lpat;
  23. int lpat_count;
  24. };
  25. #ifdef CONFIG_ACPI
  26. int acpi_lpat_raw_to_temp(struct acpi_lpat_conversion_table *lpat_table,
  27. int raw);
  28. int acpi_lpat_temp_to_raw(struct acpi_lpat_conversion_table *lpat_table,
  29. int temp);
  30. struct acpi_lpat_conversion_table *acpi_lpat_get_conversion_table(acpi_handle
  31. handle);
  32. void acpi_lpat_free_conversion_table(struct acpi_lpat_conversion_table
  33. *lpat_table);
  34. #else
  35. static int acpi_lpat_raw_to_temp(struct acpi_lpat_conversion_table *lpat_table,
  36. int raw)
  37. {
  38. return 0;
  39. }
  40. static int acpi_lpat_temp_to_raw(struct acpi_lpat_conversion_table *lpat_table,
  41. int temp)
  42. {
  43. return 0;
  44. }
  45. static struct acpi_lpat_conversion_table *acpi_lpat_get_conversion_table(
  46. acpi_handle handle)
  47. {
  48. return NULL;
  49. }
  50. static void acpi_lpat_free_conversion_table(struct acpi_lpat_conversion_table
  51. *lpat_table)
  52. {
  53. }
  54. #endif
  55. #endif