Bugzilla – Attachment 410919 Details for
Bug 623393
hard lock at boot with acpi on acer aspire 1310
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Forgot Password
[patch]
crude patch to trace acpi_ns_init_one_device and prevent 35th call of it
nsinit.patch (text/plain), 5.38 KB, created by
Markus Kohm
on 2011-01-28 07:33:56 UTC
(
hide
)
Description:
crude patch to trace acpi_ns_init_one_device and prevent 35th call of it
Filename:
MIME Type:
Creator:
Markus Kohm
Created:
2011-01-28 07:33:56 UTC
Size:
5.38 KB
patch
obsolete
>--- nsinit.c.orig 2010-11-02 17:19:06.608032180 +0100 >+++ nsinit.c 2011-01-28 08:08:32.492038670 +0100 >@@ -153,21 +153,23 @@ > "by executing _INI methods:")); > > /* Tree analysis: find all subtrees that contain _INI methods */ >- >+ printk( KERN_INFO "acpi_ns_walk_namespace() find\n" ); > status = acpi_ns_walk_namespace(ACPI_TYPE_ANY, ACPI_ROOT_OBJECT, > ACPI_UINT32_MAX, FALSE, > acpi_ns_find_ini_methods, NULL, &info, > NULL); > if (ACPI_FAILURE(status)) { >+ printk( KERN_INFO "goto error_exit\n" ); > goto error_exit; > } > > /* Allocate the evaluation information block */ >- >+ printk( KERN_INFO "allocate evaluation information block\n" ); > info.evaluate_info = > ACPI_ALLOCATE_ZEROED(sizeof(struct acpi_evaluate_info)); > if (!info.evaluate_info) { > status = AE_NO_MEMORY; >+ printk( KERN_INFO "goto error_exit\n" ); > goto error_exit; > } > >@@ -181,13 +183,16 @@ > info.evaluate_info->parameters = NULL; > info.evaluate_info->flags = ACPI_IGNORE_RETURN_VALUE; > >+ printk( KERN_INFO "acpi_ns_evaluate()\n" ); > status = acpi_ns_evaluate(info.evaluate_info); > if (ACPI_SUCCESS(status)) { >+ printk( KERN_INFO "success\n" ); > info.num_INI++; > } > > /* Walk namespace to execute all _INIs on present devices */ > >+ printk( KERN_INFO "acpi_ns_walk_namespace() execute\n" ); > status = acpi_ns_walk_namespace(ACPI_TYPE_ANY, ACPI_ROOT_OBJECT, > ACPI_UINT32_MAX, FALSE, > acpi_ns_init_one_device, NULL, &info, >@@ -199,11 +204,14 @@ > * I/O addresses to 16 bits -- for Windows compatibility. > */ > if (acpi_gbl_osi_data >= ACPI_OSI_WIN_2000) { >+ printk( KERN_INFO "truncate I/O adresses\n" ); > acpi_gbl_truncate_io_addresses = TRUE; > } > >+ printk( KERN_INFO "ACPI_FREE()\n" ); > ACPI_FREE(info.evaluate_info); > if (ACPI_FAILURE(status)) { >+ printk( KERN_INFO "goto error_exit\n" ); > goto error_exit; > } > >@@ -211,10 +219,11 @@ > "\nExecuted %u _INI methods requiring %u _STA executions " > "(examined %u objects)\n", > info.num_INI, info.num_STA, info.device_count)); >- >+ printk( KERN_INFO "return\n" ); > return_ACPI_STATUS(status); > > error_exit: >+ printk( KERN_INFO "error_exit\n" ); > ACPI_EXCEPTION((AE_INFO, status, "During device initialization")); > return_ACPI_STATUS(status); > } >@@ -449,6 +458,7 @@ > acpi_ns_init_one_device(acpi_handle obj_handle, > u32 nesting_level, void *context, void **return_value) > { >+ static int device_number = 0; > struct acpi_device_walk_info *walk_info = > ACPI_CAST_PTR(struct acpi_device_walk_info, context); > struct acpi_evaluate_info *info = walk_info->evaluate_info; >@@ -457,13 +467,17 @@ > struct acpi_namespace_node *device_node; > > ACPI_FUNCTION_TRACE(ns_init_one_device); >+ device_number++; >+ printk( KERN_INFO "acpi_init_one_device (%d with nesting_level=%d)\n", device_number, (int)nesting_level ); > > /* We are interested in Devices, Processors and thermal_zones only */ > > device_node = ACPI_CAST_PTR(struct acpi_namespace_node, obj_handle); >+ printk( KERN_INFO "device_node %p (type=%d)\n", device_node, (int)(device_node->type) ); > if ((device_node->type != ACPI_TYPE_DEVICE) && > (device_node->type != ACPI_TYPE_PROCESSOR) && > (device_node->type != ACPI_TYPE_THERMAL)) { >+ printk( KERN_INFO "return\n" ); > return_ACPI_STATUS(AE_OK); > } > >@@ -474,7 +488,11 @@ > * If this device subtree does not contain any _INI methods, we > * can exit now and stop traversing this entire subtree. > */ >- if (!(device_node->flags & ANOBJ_SUBTREE_HAS_INI)) { >+ /* MKOHM: EXIT FROM THIS TREE, if it is the 35th call of >+ * acpi_init_one_device */ >+ if ( (device_number == 35) || >+ !(device_node->flags & ANOBJ_SUBTREE_HAS_INI)) { >+ printk( KERN_INFO "return\n" ); > return_ACPI_STATUS(AE_CTRL_DEPTH); > } > >@@ -492,11 +510,14 @@ > ACPI_DEBUG_EXEC(acpi_ut_display_init_pathname > (ACPI_TYPE_METHOD, device_node, METHOD_NAME__STA)); > >+ printk( KERN_INFO "acpi_ut_execute_STA: " ); > status = acpi_ut_execute_STA(device_node, &flags); >+ printk( KERN_INFO "done.\n" ); > if (ACPI_FAILURE(status)) { > > /* Ignore error and move on to next device */ > >+ printk( KERN_INFO "return\n" ); > return_ACPI_STATUS(AE_OK); > } > >@@ -540,6 +561,7 @@ > * valid. OSPM should continue enumeration below a device whose > * _STA returns this bit combination" > */ >+ printk( KERN_INFO "return\n" ); > return_ACPI_STATUS(AE_OK); > } else { > /* >@@ -553,6 +575,7 @@ > * OSPM will not run the _INI and will not examine the children > * of the device for _INI methods" > */ >+ printk( KERN_INFO "return\n" ); > return_ACPI_STATUS(AE_CTRL_DEPTH); > } > } >@@ -577,9 +600,13 @@ > * as possible (without an NMI being received in the middle of > * this) - so disable NMIs and initialize the device: > */ >+ printk( KERN_INFO "acpi_nmi_disable, \n" ); > acpi_nmi_disable(); >+ printk( KERN_INFO "acpi_ns_evaluate, \n" ); > status = acpi_ns_evaluate(info); >+ printk( KERN_INFO "acpi_ns_evaluate: " ); > acpi_nmi_enable(); >+ printk( KERN_INFO "done.\n" ); > > if (ACPI_SUCCESS(status)) { > walk_info->num_INI++; >@@ -612,9 +639,12 @@ > * Handler for this device. > */ > if (acpi_gbl_init_handler) { >+ printk( KERN_INFO "acpi_gbl_init_handler: " ); > status = > acpi_gbl_init_handler(device_node, ACPI_INIT_DEVICE_INI); >+ printk( KERN_INFO "done.\n" ); > } > >+ printk( KERN_INFO "return\n" ); > return_ACPI_STATUS(status); > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 623393
:
376715
|
396226
|
396981
|
407035
|
408109
| 410919 |
411024
|
411152
|
411153
|
411484