Pass a handle to evaluate_object as start point.
This commit is contained in:
parent
4ef95cb195
commit
92d766df7c
@ -236,8 +236,8 @@ struct acpi_module_info {
|
||||
|
||||
/* Control method execution and data acquisition */
|
||||
|
||||
status_t (*evaluate_object)(const char* object,
|
||||
acpi_object_type *returnValue, size_t bufferLength);
|
||||
status_t (*evaluate_object)(acpi_handle handle, const char* object,
|
||||
acpi_objects *args, acpi_object_type *returnValue, size_t bufferLength);
|
||||
status_t (*evaluate_method)(acpi_handle handle, const char *method,
|
||||
acpi_objects *args, acpi_data *returnValue);
|
||||
|
||||
|
@ -115,8 +115,9 @@ typedef struct acpi_root_info {
|
||||
|
||||
/* Control method execution and data acquisition */
|
||||
|
||||
status_t (*evaluate_object)(const char* object,
|
||||
acpi_object_type *returnValue, size_t bufferLength);
|
||||
status_t (*evaluate_object)(acpi_handle handle, const char* object,
|
||||
acpi_objects *args, acpi_object_type *returnValue,
|
||||
size_t bufferLength);
|
||||
status_t (*evaluate_method)(acpi_handle handle, const char *method,
|
||||
acpi_objects *args, acpi_data *returnValue);
|
||||
|
||||
@ -203,8 +204,8 @@ status_t get_object_typed(const char* path, acpi_object_type** _returnValue,
|
||||
uint32 object_type);
|
||||
status_t ns_handle_to_pathname(acpi_handle targetHandle, acpi_data* buffer);
|
||||
|
||||
status_t evaluate_object(const char* object, acpi_object_type* returnValue,
|
||||
size_t bufferLength);
|
||||
status_t evaluate_object(acpi_handle handle, const char* object,
|
||||
acpi_objects* args, acpi_object_type* returnValue, size_t bufferLength);
|
||||
status_t evaluate_method(acpi_handle handle, const char* method,
|
||||
acpi_objects* args, acpi_data* returnValue);
|
||||
|
||||
|
@ -554,8 +554,8 @@ ns_handle_to_pathname(acpi_handle targetHandle, acpi_data *buffer)
|
||||
|
||||
|
||||
status_t
|
||||
evaluate_object(const char* object, acpi_object_type* returnValue,
|
||||
size_t bufferLength)
|
||||
evaluate_object(acpi_handle handle, const char* object, acpi_objects *args,
|
||||
acpi_object_type* returnValue, size_t bufferLength)
|
||||
{
|
||||
ACPI_BUFFER buffer;
|
||||
ACPI_STATUS status;
|
||||
@ -563,8 +563,8 @@ evaluate_object(const char* object, acpi_object_type* returnValue,
|
||||
buffer.Pointer = returnValue;
|
||||
buffer.Length = bufferLength;
|
||||
|
||||
status = AcpiEvaluateObject(NULL, (ACPI_STRING)object, NULL,
|
||||
returnValue != NULL ? &buffer : NULL);
|
||||
status = AcpiEvaluateObject(handle, (ACPI_STRING)object,
|
||||
(ACPI_OBJECT_LIST*)args, returnValue != NULL ? &buffer : NULL);
|
||||
if (status == AE_BUFFER_OVERFLOW)
|
||||
dprintf("evaluate_object: the passed buffer is too small!\n");
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user