ahuuids.c revision 271440
1169689Skan/******************************************************************************
2169689Skan *
3169689Skan * Module Name: ahuuids - Table of known ACPI-related UUIDs
4169689Skan *
5169689Skan *****************************************************************************/
6169689Skan
7169689Skan/*
8169689Skan * Copyright (C) 2000 - 2014, Intel Corp.
9169689Skan * All rights reserved.
10169689Skan *
11169689Skan * Redistribution and use in source and binary forms, with or without
12169689Skan * modification, are permitted provided that the following conditions
13169689Skan * are met:
14169689Skan * 1. Redistributions of source code must retain the above copyright
15169689Skan *    notice, this list of conditions, and the following disclaimer,
16169689Skan *    without modification.
17169689Skan * 2. Redistributions in binary form must reproduce at minimum a disclaimer
18169689Skan *    substantially similar to the "NO WARRANTY" disclaimer below
19169689Skan *    ("Disclaimer") and any redistribution must be conditioned upon
20169689Skan *    including a substantially similar Disclaimer requirement for further
21169689Skan *    binary redistribution.
22169689Skan * 3. Neither the names of the above-listed copyright holders nor the names
23169689Skan *    of any contributors may be used to endorse or promote products derived
24169689Skan *    from this software without specific prior written permission.
25169689Skan *
26169689Skan * Alternatively, this software may be distributed under the terms of the
27169689Skan * GNU General Public License ("GPL") version 2 as published by the Free
28169689Skan * Software Foundation.
29169689Skan *
30169689Skan * NO WARRANTY
31169689Skan * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
32169689Skan * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
33169689Skan * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
34169689Skan * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
35169689Skan * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
36169689Skan * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
37169689Skan * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
38169689Skan * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
39169689Skan * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
40169689Skan * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
41169689Skan * POSSIBILITY OF SUCH DAMAGES.
42169689Skan */
43169689Skan
44169689Skan#include "acpi.h"
45169689Skan#include "accommon.h"
46169689Skan
47169689Skan#define _COMPONENT          ACPI_UTILITIES
48169689Skan        ACPI_MODULE_NAME    ("ahuuids")
49169689Skan
50169689Skan/*
51169689Skan * Table of "known" (ACPI-related) UUIDs
52169689Skan */
53169689Skanconst AH_UUID  AcpiUuids[] =
54169689Skan{
55169689Skan    {"PCI Host Bridge Device",
56169689Skan        "33db4d5b-1ff7-401c-9657-7441c03dd766"},
57169689Skan
58169689Skan    {"Platform-wide Capabilities",
59169689Skan        "0811b06e-4a27-44f9-8d60-3cbbc22e7b48"},
60169689Skan
61169689Skan    {"Dynamic Enumeration",
62169689Skan        "d8c1a3a6-be9b-4c9b-91bf-c3cb81fc5daf"},
63169689Skan
64169689Skan    {"GPIO Controller",
65169689Skan        "4f248f40-d5e2-499f-834c-27758ea1cd3f"},
66169689Skan
67169689Skan    {"Battery Thermal Limit",
68169689Skan        "4c2067e3-887d-475c-9720-4af1d3ed602e"},
69169689Skan
70169689Skan    {"Thermal Extensions",
71169689Skan        "14d399cd-7a27-4b18-8fb4-7cb7b9f4e500"},
72169689Skan
73169689Skan    {"USB Controller",
74169689Skan        "ce2ee385-00e6-48cb-9f05-2edb927c4899"},
75169689Skan
76169689Skan    {"HID I2C Device",
77169689Skan        "3cdff6f7-4267-4555-ad05-b30a3d8938de"},
78169689Skan
79169689Skan    {"Power Button Device",
80169689Skan        "dfbcf3c5-e7a5-44e6-9c1f-29c76f6e059c"},
81169689Skan
82169689Skan    {"Device Labeling Interface",
83169689Skan        "e5c937d0-3553-4d7a-9117-ea4d19c3434d"},
84169689Skan
85169689Skan    {"SATA Controller",
86169689Skan        "e4db149b-fcfe-425b-a6d8-92357d78fc7f"},
87169689Skan
88169689Skan    {"Physical Presence Interface",
89169689Skan        "3dddfaa6-361b-4eb4-a424-8d10089d1653"},
90169689Skan
91169689Skan    {"Device Properties for _DSD",
92169689Skan        "daffd814-6eba-4d8c-8a91-bc9bbf4aa301"},
93169689Skan
94169689Skan    {NULL, NULL}
95169689Skan};
96169689Skan
97169689Skan
98169689Skan/*******************************************************************************
99169689Skan *
100169689Skan * FUNCTION:    AcpiAhMatchUuid
101169689Skan *
102169689Skan * PARAMETERS:  Data                - Data buffer containing a UUID
103169689Skan *
104169689Skan * RETURN:      ASCII description string for the UUID if it is found.
105169689Skan *
106169689Skan * DESCRIPTION: Returns a description string for "known" UUIDs, which are
107169689Skan *              are UUIDs that are related to ACPI in some way.
108169689Skan *
109169689Skan ******************************************************************************/
110169689Skan
111169689Skanconst char *
112169689SkanAcpiAhMatchUuid (
113169689Skan    UINT8                   *Data)
114169689Skan{
115169689Skan    const AH_UUID           *Info;
116169689Skan    UINT8                   UuidBuffer[UUID_BUFFER_LENGTH];
117169689Skan
118169689Skan
119169689Skan    /* Walk the table of known ACPI-related UUIDs */
120169689Skan
121169689Skan    for (Info = AcpiUuids; Info->Description; Info++)
122169689Skan    {
123169689Skan        AcpiUtConvertStringToUuid (Info->String, UuidBuffer);
124169689Skan
125169689Skan        if (!ACPI_MEMCMP (Data, UuidBuffer, UUID_BUFFER_LENGTH))
126169689Skan        {
127169689Skan            return (Info->Description);
128169689Skan        }
129169689Skan    }
130169689Skan
131169689Skan    return (NULL);
132169689Skan}
133169689Skan