ReactOS 0.4.16-dev-125-g798ea90
utpredef.c File Reference
#include "acpi.h"
#include "accommon.h"
#include "acpredef.h"
Include dependency graph for utpredef.c:

Go to the source code of this file.

Macros

#define _COMPONENT   ACPI_UTILITIES
 

Functions

const ACPI_PREDEFINED_INFOAcpiUtGetNextPredefinedMethod (const ACPI_PREDEFINED_INFO *ThisName)
 
const ACPI_PREDEFINED_INFOAcpiUtMatchPredefinedMethod (char *Name)
 
void AcpiUtGetExpectedReturnTypes (char *Buffer, UINT32 ExpectedBtypes)
 

Variables

static const charUtRtypeNames []
 

Macro Definition Documentation

◆ _COMPONENT

#define _COMPONENT   ACPI_UTILITIES

Definition at line 49 of file utpredef.c.

Function Documentation

◆ AcpiUtGetExpectedReturnTypes()

void AcpiUtGetExpectedReturnTypes ( char Buffer,
UINT32  ExpectedBtypes 
)

Definition at line 158 of file utpredef.c.

161{
162 UINT32 ThisRtype;
163 UINT32 i;
164 UINT32 j;
165
166
167 if (!ExpectedBtypes)
168 {
169 strcpy (Buffer, "NONE");
170 return;
171 }
172
173 j = 1;
174 Buffer[0] = 0;
175 ThisRtype = ACPI_RTYPE_INTEGER;
176
177 for (i = 0; i < ACPI_NUM_RTYPES; i++)
178 {
179 /* If one of the expected types, concatenate the name of this type */
180
181 if (ExpectedBtypes & ThisRtype)
182 {
184 j = 0; /* Use name separator from now on */
185 }
186
187 ThisRtype <<= 1; /* Next Rtype */
188 }
189}
unsigned int UINT32
char * strcat(char *DstString, const char *SrcString)
Definition: utclib.c:568
char * strcpy(char *DstString, const char *SrcString)
Definition: utclib.c:388
#define ACPI_NUM_RTYPES
Definition: aclocal.h:485
#define ACPI_RTYPE_INTEGER
Definition: aclocal.h:478
Definition: bufpool.h:45
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint GLint GLint j
Definition: glfuncs.h:250
static const char * UtRtypeNames[]
Definition: utpredef.c:57

Referenced by AcpiNsCheckObjectType().

◆ AcpiUtGetNextPredefinedMethod()

const ACPI_PREDEFINED_INFO * AcpiUtGetNextPredefinedMethod ( const ACPI_PREDEFINED_INFO ThisName)

Definition at line 82 of file utpredef.c.

84{
85
86 /*
87 * Skip next entry in the table if this name returns a Package
88 * (next entry contains the package info)
89 */
90 if ((ThisName->Info.ExpectedBtypes & ACPI_RTYPE_PACKAGE) &&
91 (ThisName->Info.ExpectedBtypes != ACPI_RTYPE_ALL))
92 {
93 ThisName++;
94 }
95
96 ThisName++;
97 return (ThisName);
98}
#define ACPI_RTYPE_ALL
Definition: aclocal.h:483
#define ACPI_RTYPE_PACKAGE
Definition: aclocal.h:481
UINT8 ExpectedBtypes
Definition: aclocal.h:377
ACPI_NAME_INFO Info
Definition: aclocal.h:441

Referenced by AcpiUtMatchPredefinedMethod().

◆ AcpiUtMatchPredefinedMethod()

const ACPI_PREDEFINED_INFO * AcpiUtMatchPredefinedMethod ( char Name)

Definition at line 114 of file utpredef.c.

116{
117 const ACPI_PREDEFINED_INFO *ThisName;
118
119
120 /* Quick check for a predefined name, first character must be underscore */
121
122 if (Name[0] != '_')
123 {
124 return (NULL);
125 }
126
127 /* Search info table for a predefined method/object name */
128
129 ThisName = AcpiGbl_PredefinedMethods;
130 while (ThisName->Info.Name[0])
131 {
132 if (ACPI_COMPARE_NAMESEG (Name, ThisName->Info.Name))
133 {
134 return (ThisName);
135 }
136
137 ThisName = AcpiUtGetNextPredefinedMethod (ThisName);
138 }
139
140 return (NULL); /* Not found */
141}
const ACPI_PREDEFINED_INFO AcpiGbl_PredefinedMethods[]
#define ACPI_COMPARE_NAMESEG(a, b)
Definition: actypes.h:564
#define NULL
Definition: types.h:112
char Name[ACPI_NAMESEG_SIZE]
Definition: aclocal.h:375
const ACPI_PREDEFINED_INFO * AcpiUtGetNextPredefinedMethod(const ACPI_PREDEFINED_INFO *ThisName)
Definition: utpredef.c:82

Referenced by AcpiNsEvaluate().

Variable Documentation

◆ UtRtypeNames

const char* UtRtypeNames[]
static
Initial value:
=
{
"/Integer",
"/String",
"/Buffer",
"/Package",
"/Reference",
}

Definition at line 57 of file utpredef.c.

Referenced by AcpiUtGetExpectedReturnTypes().