Skip to contentSkip to conversation

ACPICA 20130725 Release

PATCH In review Lv Zheng 3 participants 12 messages Aug 8, 2013 – Aug 17, 2013

Subsystems (2)
lore
Share & tools
lore

Lv Zheng

author
#0 lore raw

cover ACPICA 20130725 Release

The 20130725 ACPICA kernel resident system updates is linuxized based on the pm/linux-next branch.

The patch set has passed a build/boot test on the following machines:
Dell Inspiron Mini 1010 (i386)
HP Compaq 8200 Elite SFF PC (x86-64)
With the following kernel configuration items enabled:
CONFIG_ACPI_AC
CONFIG_ACPI_BATTERY
CONFIG_ACPI_NUMA
CONFIG_ACPI_PROCESSOR
CONFIG_ACPI_THERMAL
CONFIG_ACPI_VIDEO
CONFIG_CPU_FREQ
CONFIG_I2C_SCMI
CONFIG_SENSORS_ACPI_POWER
CONFIG_PANASONIC_LAPTOP
CONFIG_XO15_EBOOK
No new divergences are introduced in this release.

Please review.

Bob Moore (8):
ACPICA: Export acpi_tb_validate_rsdp().
ACPICA: Emit all unresolved method externals in a text block
ACPICA: DeRefOf operator: Update to fully resolve FieldUnit and
BufferField refs.
ACPICA: Fix possible fault for methods that optionally have no return
value.
ACPICA: Make ACPI Power Management Timer (PM Timer) optional.
ACPICA: Return error if DerefOf resolves to a null package element.
ACPICA: Update names for walk_namespace callbacks to clarify usage.
ACPICA: Update version to 20130725.

Lv Zheng (1):
ACPICA: Fix divergences of the commit - ACPICA: Expose OSI version.

 drivers/acpi/acpica/acglobal.h |    7 +++++-
 drivers/acpi/acpica/aclocal.h  |    1 +
 drivers/acpi/acpica/acnamesp.h |    4 ++--
 drivers/acpi/acpica/actables.h |    2 ++
 drivers/acpi/acpica/exoparg1.c |   48 +++++++++++++++++++++++++++++++++++-----
 drivers/acpi/acpica/hwtimer.c  |   13 ++++++++++-
 drivers/acpi/acpica/nspredef.c |   16 +++++++++++++-
 drivers/acpi/acpica/nswalk.c   |   26 +++++++++++-----------
 drivers/acpi/acpica/nsxfeval.c |   16 +++++++-------
 drivers/acpi/acpica/tbfadt.c   |    4 ++--
 drivers/acpi/acpica/tbxfroot.c |    8 ++-----
 drivers/acpi/acpica/utglobal.c |    1 -
 include/acpi/acpixf.h          |    6 ++---
 include/acpi/actypes.h         |   28 +++++++++++------------
 14 files changed, 121 insertions(+), 59 deletions(-)
Signature · 1 line
1.7.10
author
#1 lore raw

PATCH 1/9 ACPICA: Export acpi_tb_validate_rsdp().

From: Bob Moore <[email protected]>

This patch exports acpi_tb_validate_rsdp(), so that code duplication in some ACPICA utilities can be reduced.
This patch also includes lint changes.

---
 drivers/acpi/acpica/actables.h |    2 ++
 drivers/acpi/acpica/tbxfroot.c |    8 ++------
 2 files changed, 4 insertions(+), 6 deletions(-)
drivers/acpi/acpica/actables.h +2 -0
index 917315e..c54f42c 100644
@@ -49,6 +49,8 @@ acpi_status acpi_allocate_root_table(u32 initial_table_count);
 /*
  * tbxfroot - Root pointer utilities
  */
+acpi_status acpi_tb_validate_rsdp(struct acpi_table_rsdp *rsdp);
+
 u8 *acpi_tb_scan_memory_for_rsdp(u8 *start_address, u32 length);
 
 /*
drivers/acpi/acpica/tbxfroot.c +2 -6
index e76ed0f..948c95e 100644
@@ -48,9 +48,6 @@
 #define _COMPONENT          ACPI_TABLES
 ACPI_MODULE_NAME("tbxfroot")
 
-/* Local prototypes */
-static acpi_status acpi_tb_validate_rsdp(struct acpi_table_rsdp *rsdp);
-
 /*******************************************************************************
  *
  * FUNCTION:    acpi_tb_validate_rsdp
@@ -62,8 +59,7 @@ static acpi_status acpi_tb_validate_rsdp(struct acpi_table_rsdp *rsdp);
  * DESCRIPTION: Validate the RSDP (ptr)
  *
  ******************************************************************************/
-
-static acpi_status acpi_tb_validate_rsdp(struct acpi_table_rsdp *rsdp)
+acpi_status acpi_tb_validate_rsdp(struct acpi_table_rsdp *rsdp)
 {
 
 	/*
@@ -72,7 +68,7 @@ static acpi_status acpi_tb_validate_rsdp(struct acpi_table_rsdp *rsdp)
 	 * Note: Sometimes there exists more than one RSDP in memory; the valid
 	 * RSDP has a valid checksum, all others have an invalid checksum.
 	 */
-	if (ACPI_STRNCMP((char *)rsdp, ACPI_SIG_RSDP,
+	if (ACPI_STRNCMP((char *)rsdp->signature, ACPI_SIG_RSDP,
 			 sizeof(ACPI_SIG_RSDP) - 1) != 0) {
 
 		/* Nope, BAD Signature */
Signature · 1 line
1.7.10
author
#2 lore raw

PATCH 2/9 ACPICA: Emit all unresolved method externals in a text block

In reply to Lv Zheng

From: Bob Moore <[email protected]>

Put all of the unresolved external method declarations in a single block, since they are important and may cause the resulting disassembled ASL file to not compile.
This patch only affects ACPICA utilities and is necessary to avoid adding source code divergences between Linux and ACPICA upstream.

---
 drivers/acpi/acpica/aclocal.h |    1 +
 1 file changed, 1 insertion(+)
drivers/acpi/acpica/aclocal.h +1 -0
index b0e3d15..0ed0066 100644
@@ -1033,6 +1033,7 @@ struct acpi_external_list {
 	u8 type;
 	u8 flags;
 	u8 resolved;
+	u8 emitted;
 };
 
 /* Values for Flags field above */
Signature · 1 line
1.7.10
author
#3 lore raw

PATCH 3/9 ACPICA: DeRefOf operator: Update to fully resolve FieldUnit and BufferField refs.

In reply to Lv Zheng

From: Bob Moore <[email protected]>

Previously, references to these objects were resolved only to the actual FieldUnit or BufferField object. The correct behavior is to resolve these references to an actual value.
The problem is that DerefOf did not resolve these objects to actual values. An "Integer" object is simple, return the value. But a field in an operation region will require a read operation. For a BufferField, the appropriate data must be extracted from the parent buffer.

NOTE: It appears that this issues is present in Windows7 but not Windows8.

---
 drivers/acpi/acpica/exoparg1.c |   35 ++++++++++++++++++++++++++++++++---
 1 file changed, 32 insertions(+), 3 deletions(-)
drivers/acpi/acpica/exoparg1.c +32 -3
index 814b4a3..3482df4 100644
@@ -990,11 +990,40 @@ acpi_status acpi_ex_opcode_1A_0T_1R(struct acpi_walk_state *walk_state)
 									 acpi_namespace_node
 									 *)
 									return_desc);
-				}
+					if (!return_desc) {
+						break;
+					}
+
+					/*
+					 * June 2013:
+					 * buffer_fields/field_units require additional resolution
+					 */
+					switch (return_desc->common.type) {
+					case ACPI_TYPE_BUFFER_FIELD:
+					case ACPI_TYPE_LOCAL_REGION_FIELD:
+					case ACPI_TYPE_LOCAL_BANK_FIELD:
+					case ACPI_TYPE_LOCAL_INDEX_FIELD:
+
+						status =
+						    acpi_ex_read_data_from_field
+						    (walk_state, return_desc,
+						     &temp_desc);
+						if (ACPI_FAILURE(status)) {
+							goto cleanup;
+						}
 
-				/* Add another reference to the object! */
+						return_desc = temp_desc;
+						break;
 
-				acpi_ut_add_reference(return_desc);
+					default:
+
+						/* Add another reference to the object */
+
+						acpi_ut_add_reference
+						    (return_desc);
+						break;
+					}
+				}
 				break;
 
 			default:
Signature · 1 line
1.7.10
author
#4 lore raw

PATCH 4/9 ACPICA: Fix possible fault for methods that optionally have no return value.

In reply to Lv Zheng

From: Bob Moore <[email protected]>

Currently applies to the _WAK method only. If the method has no return value and slack mode is not enabled, the return value validation code can fault.

Also improves the error message when an expected return value is missing (for any predefined name/method).

---
 drivers/acpi/acpica/nspredef.c |   16 +++++++++++++++-
 1 file changed, 15 insertions(+), 1 deletion(-)
drivers/acpi/acpica/nspredef.c +15 -1
index 24b71a0..098e766 100644
@@ -151,6 +151,15 @@ acpi_ns_check_return_value(struct acpi_namespace_node *node,
 	}
 
 	/*
+	 *
+	 * 4) If there is no return value and it is optional, just return
+	 * AE_OK (_WAK).
+	 */
+	if (!(*return_object_ptr)) {
+		goto exit;
+	}
+
+	/*
 	 * For returned Package objects, check the type of all sub-objects.
 	 * Note: Package may have been newly created by call above.
 	 */
@@ -268,7 +277,12 @@ acpi_ns_check_object_type(struct acpi_evaluate_info *info,
 
 	acpi_ut_get_expected_return_types(type_buffer, expected_btypes);
 
-	if (package_index == ACPI_NOT_PACKAGE_ELEMENT) {
+	if (!return_object) {
+		ACPI_WARN_PREDEFINED((AE_INFO, info->full_pathname,
+				      info->node_flags,
+				      "Expected return object of type %s",
+				      type_buffer));
+	} else if (package_index == ACPI_NOT_PACKAGE_ELEMENT) {
 		ACPI_WARN_PREDEFINED((AE_INFO, info->full_pathname,
 				      info->node_flags,
 				      "Return type mismatch - found %s, expected %s",
Signature · 1 line
1.7.10
author
#5 lore raw

PATCH 5/9 ACPICA: Fix divergences of the commit - ACPICA: Expose OSI version.

In reply to Lv Zheng

The original commit 242b2287cd7f27521c8b54a4101d569e53e7a0ca "ACPICA:
expose OSI version" triggers build errors in ACPICA when it is back ported. The patch removes the divergences between Linux and upstream ACPICA resulting from that.

---
 drivers/acpi/acpica/acglobal.h |    7 ++++++-
 drivers/acpi/acpica/utglobal.c |    1 -
 include/acpi/actypes.h         |   28 +++++++++++++---------------
 3 files changed, 19 insertions(+), 17 deletions(-)
drivers/acpi/acpica/acglobal.h +6 -1
index b8d3811..90e846f 100644
@@ -138,6 +138,12 @@ u8 ACPI_INIT_GLOBAL(acpi_gbl_disable_auto_repair, FALSE);
  */
 u8 ACPI_INIT_GLOBAL(acpi_gbl_disable_ssdt_table_load, FALSE);
 
+/*
+ * We keep track of the latest version of Windows that has been requested by
+ * the BIOS.
+ */
+u8 ACPI_INIT_GLOBAL(acpi_gbl_osi_data, 0);
+
 /* acpi_gbl_FADT is a local copy of the FADT, converted to a common format. */
 
 struct acpi_table_fadt acpi_gbl_FADT;
@@ -285,7 +291,6 @@ ACPI_EXTERN u8 acpi_gbl_debugger_configuration;
 ACPI_EXTERN u8 acpi_gbl_step_to_next_call;
 ACPI_EXTERN u8 acpi_gbl_acpi_hardware_present;
 ACPI_EXTERN u8 acpi_gbl_events_initialized;
-ACPI_EXTERN u8 acpi_gbl_osi_data;
 ACPI_EXTERN struct acpi_interface_info *acpi_gbl_supported_interfaces;
 ACPI_EXTERN struct acpi_address_range
     *acpi_gbl_address_range_list[ACPI_ADDRESS_RANGE_MAX];
drivers/acpi/acpica/utglobal.c +0 -1
index f736448..d6f26bf 100644
@@ -336,7 +336,6 @@ acpi_status acpi_ut_init_globals(void)
 	acpi_gbl_trace_dbg_layer = 0;
 	acpi_gbl_debugger_configuration = DEBUGGER_THREADING;
 	acpi_gbl_db_output_flags = ACPI_DB_CONSOLE_OUTPUT;
-	acpi_gbl_osi_data = 0;
 	acpi_gbl_osi_mutex = NULL;
 	acpi_gbl_reg_methods_executed = FALSE;
 
include/acpi/actypes.h +13 -15
index eae55fb..b748aef 100644
@@ -1137,7 +1137,19 @@ struct acpi_memory_list {
 #endif
 };
 
-/* Definitions for _OSI support */
+/* Definitions of _OSI support */
+
+#define ACPI_VENDOR_STRINGS                 0x01
+#define ACPI_FEATURE_STRINGS                0x02
+#define ACPI_ENABLE_INTERFACES              0x00
+#define ACPI_DISABLE_INTERFACES             0x04
+
+#define ACPI_DISABLE_ALL_VENDOR_STRINGS     (ACPI_DISABLE_INTERFACES | ACPI_VENDOR_STRINGS)
+#define ACPI_DISABLE_ALL_FEATURE_STRINGS    (ACPI_DISABLE_INTERFACES | ACPI_FEATURE_STRINGS)
+#define ACPI_DISABLE_ALL_STRINGS            (ACPI_DISABLE_INTERFACES | ACPI_VENDOR_STRINGS | ACPI_FEATURE_STRINGS)
+#define ACPI_ENABLE_ALL_VENDOR_STRINGS      (ACPI_ENABLE_INTERFACES | ACPI_VENDOR_STRINGS)
+#define ACPI_ENABLE_ALL_FEATURE_STRINGS     (ACPI_ENABLE_INTERFACES | ACPI_FEATURE_STRINGS)
+#define ACPI_ENABLE_ALL_STRINGS             (ACPI_ENABLE_INTERFACES | ACPI_VENDOR_STRINGS | ACPI_FEATURE_STRINGS)
 
 #define ACPI_OSI_WIN_2000               0x01
 #define ACPI_OSI_WIN_XP                 0x02
@@ -1152,18 +1164,4 @@ struct acpi_memory_list {
 #define ACPI_OSI_WIN_7                  0x0B
 #define ACPI_OSI_WIN_8                  0x0C
 
-/* _OSI update actions */
-
-#define ACPI_VENDOR_STRINGS                 0x01
-#define ACPI_FEATURE_STRINGS                0x02
-#define ACPI_ENABLE_INTERFACES              0x00
-#define ACPI_DISABLE_INTERFACES             0x04
-
-#define ACPI_DISABLE_ALL_VENDOR_STRINGS     (ACPI_DISABLE_INTERFACES | ACPI_VENDOR_STRINGS)
-#define ACPI_DISABLE_ALL_FEATURE_STRINGS    (ACPI_DISABLE_INTERFACES | ACPI_FEATURE_STRINGS)
-#define ACPI_DISABLE_ALL_STRINGS            (ACPI_DISABLE_INTERFACES | ACPI_VENDOR_STRINGS | ACPI_FEATURE_STRINGS)
-#define ACPI_ENABLE_ALL_VENDOR_STRINGS      (ACPI_ENABLE_INTERFACES | ACPI_VENDOR_STRINGS)
-#define ACPI_ENABLE_ALL_FEATURE_STRINGS     (ACPI_ENABLE_INTERFACES | ACPI_FEATURE_STRINGS)
-#define ACPI_ENABLE_ALL_STRINGS             (ACPI_ENABLE_INTERFACES | ACPI_VENDOR_STRINGS | ACPI_FEATURE_STRINGS)
-
 #endif				/* __ACTYPES_H__ */
Signature · 1 line
1.7.10
author
#6 lore raw

PATCH 6/9 ACPICA: Make ACPI Power Management Timer (PM Timer) optional.

In reply to Lv Zheng

From: Bob Moore <[email protected]>

PM Timer is now optional.
This support is already in Windows8 and "SHOULD" come out in ACPI 5.0A (if all goes well).

The change doesn't affect Linux directly, because it has never relied on the presence of the PM timer.

---
 drivers/acpi/acpica/hwtimer.c |   13 ++++++++++++-
 drivers/acpi/acpica/tbfadt.c  |    4 ++--
 2 files changed, 14 insertions(+), 3 deletions(-)
drivers/acpi/acpica/hwtimer.c +12 -1
index 0c1a8bb..2d7d22e 100644
@@ -100,8 +100,13 @@ acpi_status acpi_get_timer(u32 * ticks)
 		return_ACPI_STATUS(AE_BAD_PARAMETER);
 	}
 
-	status = acpi_hw_read(ticks, &acpi_gbl_FADT.xpm_timer_block);
+	/* ACPI 5.0A: PM Timer is optional */
+
+	if (!acpi_gbl_FADT.xpm_timer_block.address) {
+		return_ACPI_STATUS(AE_SUPPORT);
+	}
 
+	status = acpi_hw_read(ticks, &acpi_gbl_FADT.xpm_timer_block);
 	return_ACPI_STATUS(status);
 }
 
@@ -148,6 +153,12 @@ acpi_get_timer_duration(u32 start_ticks, u32 end_ticks, u32 * time_elapsed)
 		return_ACPI_STATUS(AE_BAD_PARAMETER);
 	}
 
+	/* ACPI 5.0A: PM Timer is optional */
+
+	if (!acpi_gbl_FADT.xpm_timer_block.address) {
+		return_ACPI_STATUS(AE_SUPPORT);
+	}
+
 	/*
 	 * Compute Tick Delta:
 	 * Handle (max one) timer rollovers on 24-bit versus 32-bit timers.
drivers/acpi/acpica/tbfadt.c +2 -2
index 33b00d2..9d99f21 100644
@@ -117,7 +117,7 @@ static struct acpi_fadt_info fadt_info_table[] = {
 	 ACPI_FADT_OFFSET(pm_timer_block),
 	 ACPI_FADT_OFFSET(pm_timer_length),
 	 ACPI_PM_TIMER_WIDTH,
-	 ACPI_FADT_REQUIRED},
+	 ACPI_FADT_SEPARATE_LENGTH},	/* ACPI 5.0A: Timer is optional */
 
 	{"Gpe0Block",
 	 ACPI_FADT_OFFSET(xgpe0_block),
@@ -574,7 +574,7 @@ static void acpi_tb_validate_fadt(void)
 
 		if (fadt_info_table[i].type & ACPI_FADT_REQUIRED) {
 			/*
-			 * Field is required (Pm1a_event, Pm1a_control, pm_timer).
+			 * Field is required (Pm1a_event, Pm1a_control).
 			 * Both the address and length must be non-zero.
 			 */
 			if (!address64->address || !length) {
Signature · 1 line
1.7.10
#7 lore raw

Re: [PATCH 6/9] ACPICA: Make ACPI Power Management Timer (PM Timer) optional.

Hi,

Quoted 4 lines · Lv Zheng

From: Bob Moore <[email protected]>

PM Timer is now optional.

...

Quoted 3 lines

The change doesn't affect Linux directly, because it has never relied on the presence of the PM timer.

Has it been so?

IIRC, there're a couple of accesses to PM Timer via:
- inl(acpi_gbl_FADT.xpm_timer_block.address);
typically in processor driver code: ex) drivers/acpi/processor_idle.c which seems to rely on the presence of the PM timer.

The below snippet shows how it was like (which can be seen in earlier linux kernel such as 2.6 series...)

- drivers/acpi/processor_idle.c:acpi_processor_idle()

    switch (cx->type) {
    case ACPI_STATE_C1:
        ...
        break;

    case ACPI_STATE_C2:
        /* Get start time (ticks) */
-->   t1 = inl(acpi_gbl_FADT.xpm_timer_block.address);
        /* Tell the scheduler that we are going deep-idle: */
        sched_clock_idle_sleep_event();
        /* Invoke C2 */
        acpi_state_timer_broadcast(pr, cx, 1);
        acpi_cstate_enter(cx);
        /* Get end time (ticks) */

--> t2 = inl(acpi_gbl_FADT.xpm_timer_block.address);

#if defined (CONFIG_GENERIC_TIME) && defined (CONFIG_X86)
        /* TSC halts in C2, so notify users */
        if (tsc_halts_in_c(ACPI_STATE_C2))
            mark_tsc_unstable("possible TSC halt in C2");
#endif
        /* Compute time (ticks) that we were actually asleep */

===> sleep_ticks = ticks_elapsed(t1, t2);

        /* Tell the scheduler how much we idled: */

===> sched_clock_idle_wakeup_event(sleep_ticks*PM_TIMER_TICK_NS);
...

#8 lore raw

Re: [PATCH 6/9] ACPICA: Make ACPI Power Management Timer (PM Timer) optional.

Quoted 11 lines · Kenichi

Hi,

Quoted 4 lines · Lv Zheng

From: Bob Moore <[email protected]>

PM Timer is now optional.

...

Quoted 3 lines

The change doesn't affect Linux directly, because it has never relied on the presence of the PM timer.

Quoted 6 lines

Has it been so?

IIRC, there're a couple of accesses to PM Timer via:
- inl(acpi_gbl_FADT.xpm_timer_block.address);
typically in processor driver code: ex) drivers/acpi/processor_idle.c which seems to rely on the presence of the PM timer.

That's correct, so I modified the changelog as it was not accurate. However, we don't rely on the PM timer presence any more, because we found systems in the field where the PM timer was not present.

Thanks,
Rafael

author
#9 lore raw

PATCH 7/9 ACPICA: Return error if DerefOf resolves to a null package element.

In reply to Lv Zheng

From: Bob Moore <[email protected]>

Disallow the dereference of a reference (via index) to an uninitialized package element. Provides compatibility with other ACPI implementations. ACPICA BZ 1003.

---
 drivers/acpi/acpica/exoparg1.c |   13 ++++++++++---
 1 file changed, 10 insertions(+), 3 deletions(-)
drivers/acpi/acpica/exoparg1.c +10 -3
index 3482df4..2cdd41d 100644
@@ -962,10 +962,17 @@ acpi_status acpi_ex_opcode_1A_0T_1R(struct acpi_walk_state *walk_state)
 					 */
 					return_desc =
 					    *(operand[0]->reference.where);
-					if (return_desc) {
-						acpi_ut_add_reference
-						    (return_desc);
+					if (!return_desc) {
+						/*
+						 * Element is NULL, do not allow the dereference.
+						 * This provides compatibility with other ACPI
+						 * implementations.
+						 */
+						return_ACPI_STATUS
+						    (AE_AML_UNINITIALIZED_ELEMENT);
 					}
+
+					acpi_ut_add_reference(return_desc);
 					break;
 
 				default:
Signature · 1 line
1.7.10
author
#10 lore raw

PATCH 8/9 ACPICA: Update names for walk_namespace callbacks to clarify usage.

In reply to Lv Zheng

From: Bob Moore <[email protected]>

Use of "preorder" and "postorder" was incorrect. The callbacks are simply invoked during tree ascent and descent during the depth-first walk.

---
 drivers/acpi/acpica/acnamesp.h |    4 ++--
 drivers/acpi/acpica/nswalk.c   |   26 +++++++++++++-------------
 drivers/acpi/acpica/nsxfeval.c |   16 ++++++++--------
 include/acpi/acpixf.h          |    4 ++--
 4 files changed, 25 insertions(+), 25 deletions(-)
drivers/acpi/acpica/acnamesp.h +2 -2
index b83dc32..40b04bd 100644
@@ -104,8 +104,8 @@ acpi_ns_walk_namespace(acpi_object_type type,
 		       acpi_handle start_object,
 		       u32 max_depth,
 		       u32 flags,
-		       acpi_walk_callback pre_order_visit,
-		       acpi_walk_callback post_order_visit,
+		       acpi_walk_callback descending_callback,
+		       acpi_walk_callback ascending_callback,
 		       void *context, void **return_value);
 
 struct acpi_namespace_node *acpi_ns_get_next_node(struct acpi_namespace_node
drivers/acpi/acpica/nswalk.c +13 -13
index e70911a..e81f15e 100644
@@ -156,9 +156,9 @@ struct acpi_namespace_node *acpi_ns_get_next_node_typed(acpi_object_type type,
  *              max_depth           - Depth to which search is to reach
  *              flags               - Whether to unlock the NS before invoking
  *                                    the callback routine
- *              pre_order_visit     - Called during tree pre-order visit
+ *              descending_callback - Called during tree descent
  *                                    when an object of "Type" is found
- *              post_order_visit    - Called during tree post-order visit
+ *              ascending_callback  - Called during tree ascent
  *                                    when an object of "Type" is found
  *              context             - Passed to user function(s) above
  *              return_value        - from the user_function if terminated
@@ -185,8 +185,8 @@ acpi_ns_walk_namespace(acpi_object_type type,
 		       acpi_handle start_node,
 		       u32 max_depth,
 		       u32 flags,
-		       acpi_walk_callback pre_order_visit,
-		       acpi_walk_callback post_order_visit,
+		       acpi_walk_callback descending_callback,
+		       acpi_walk_callback ascending_callback,
 		       void *context, void **return_value)
 {
 	acpi_status status;
@@ -255,22 +255,22 @@ acpi_ns_walk_namespace(acpi_object_type type,
 			}
 
 			/*
-			 * Invoke the user function, either pre-order or post-order
+			 * Invoke the user function, either descending, ascending,
 			 * or both.
 			 */
 			if (!node_previously_visited) {
-				if (pre_order_visit) {
+				if (descending_callback) {
 					status =
-					    pre_order_visit(child_node, level,
-							    context,
-							    return_value);
+					    descending_callback(child_node,
+								level, context,
+								return_value);
 				}
 			} else {
-				if (post_order_visit) {
+				if (ascending_callback) {
 					status =
-					    post_order_visit(child_node, level,
-							     context,
-							     return_value);
+					    ascending_callback(child_node,
+							       level, context,
+							       return_value);
 				}
 			}
 
drivers/acpi/acpica/nsxfeval.c +8 -8
index f553cfd..b38b4b0 100644
@@ -533,9 +533,9 @@ static void acpi_ns_resolve_references(struct acpi_evaluate_info *info)
  * PARAMETERS:  type                - acpi_object_type to search for
  *              start_object        - Handle in namespace where search begins
  *              max_depth           - Depth to which search is to reach
- *              pre_order_visit     - Called during tree pre-order visit
+ *              descending_callback - Called during tree descent
  *                                    when an object of "Type" is found
- *              post_order_visit    - Called during tree post-order visit
+ *              ascending_callback  - Called during tree ascent
  *                                    when an object of "Type" is found
  *              context             - Passed to user function(s) above
  *              return_value        - Location where return value of
@@ -563,8 +563,8 @@ acpi_status
 acpi_walk_namespace(acpi_object_type type,
 		    acpi_handle start_object,
 		    u32 max_depth,
-		    acpi_walk_callback pre_order_visit,
-		    acpi_walk_callback post_order_visit,
+		    acpi_walk_callback descending_callback,
+		    acpi_walk_callback ascending_callback,
 		    void *context, void **return_value)
 {
 	acpi_status status;
@@ -574,7 +574,7 @@ acpi_walk_namespace(acpi_object_type type,
 	/* Parameter validation */
 
 	if ((type > ACPI_TYPE_LOCAL_MAX) ||
-	    (!max_depth) || (!pre_order_visit && !post_order_visit)) {
+	    (!max_depth) || (!descending_callback && !ascending_callback)) {
 		return_ACPI_STATUS(AE_BAD_PARAMETER);
 	}
 
@@ -606,9 +606,9 @@ acpi_walk_namespace(acpi_object_type type,
 	}
 
 	status = acpi_ns_walk_namespace(type, start_object, max_depth,
-					ACPI_NS_WALK_UNLOCK, pre_order_visit,
-					post_order_visit, context,
-					return_value);
+					ACPI_NS_WALK_UNLOCK,
+					descending_callback, ascending_callback,
+					context, return_value);
 
 	(void)acpi_ut_release_mutex(ACPI_MTX_NAMESPACE);
 
include/acpi/acpixf.h +2 -2
index 0dd03f2..e53f16a 100644
@@ -212,8 +212,8 @@ acpi_status
 acpi_walk_namespace(acpi_object_type type,
 		    acpi_handle start_object,
 		    u32 max_depth,
-		    acpi_walk_callback pre_order_visit,
-		    acpi_walk_callback post_order_visit,
+		    acpi_walk_callback descending_callback,
+		    acpi_walk_callback ascending_callback,
 		    void *context, void **return_value);
 
 acpi_status
Signature · 1 line
1.7.10
author
#11 lore raw

PATCH 9/9 ACPICA: Update version to 20130725.

In reply to Lv Zheng

From: Bob Moore <[email protected]>

Version 20130725.

---
 include/acpi/acpixf.h |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/acpi/acpixf.h +1 -1
index e53f16a..85bfdbe 100644
@@ -46,7 +46,7 @@
 
 /* Current ACPICA subsystem version in YYYYMMDD format */
 
-#define ACPI_CA_VERSION                 0x20130626
+#define ACPI_CA_VERSION                 0x20130725
 
 #include <acpi/acconfig.h>
 #include <acpi/actypes.h>
Signature · 1 line
1.7.10