nsinit.c 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679
  1. // SPDX-License-Identifier: BSD-3-Clause OR GPL-2.0
  2. /******************************************************************************
  3. *
  4. * Module Name: nsinit - namespace initialization
  5. *
  6. * Copyright (C) 2000 - 2025, Intel Corp.
  7. *
  8. *****************************************************************************/
  9. #include <acpi/acpi.h>
  10. #include "accommon.h"
  11. #include "acnamesp.h"
  12. #include "acdispat.h"
  13. #include "acinterp.h"
  14. #include "acevents.h"
  15. #define _COMPONENT ACPI_NAMESPACE
  16. ACPI_MODULE_NAME("nsinit")
  17. /* Local prototypes */
  18. static acpi_status
  19. acpi_ns_init_one_object(acpi_handle obj_handle,
  20. u32 level, void *context, void **return_value);
  21. static acpi_status
  22. acpi_ns_init_one_device(acpi_handle obj_handle,
  23. u32 nesting_level, void *context, void **return_value);
  24. static acpi_status
  25. acpi_ns_find_ini_methods(acpi_handle obj_handle,
  26. u32 nesting_level, void *context, void **return_value);
  27. /*******************************************************************************
  28. *
  29. * FUNCTION: acpi_ns_initialize_objects
  30. *
  31. * PARAMETERS: None
  32. *
  33. * RETURN: Status
  34. *
  35. * DESCRIPTION: Walk the entire namespace and perform any necessary
  36. * initialization on the objects found therein
  37. *
  38. ******************************************************************************/
  39. acpi_status acpi_ns_initialize_objects(void)
  40. {
  41. acpi_status status;
  42. struct acpi_init_walk_info info;
  43. ACPI_FUNCTION_TRACE(ns_initialize_objects);
  44. ACPI_DEBUG_PRINT((ACPI_DB_EXEC,
  45. "[Init] Completing Initialization of ACPI Objects\n"));
  46. ACPI_DEBUG_PRINT((ACPI_DB_DISPATCH,
  47. "**** Starting initialization of namespace objects ****\n"));
  48. ACPI_DEBUG_PRINT_RAW((ACPI_DB_INIT,
  49. "Final data object initialization: "));
  50. /* Clear the info block */
  51. memset(&info, 0, sizeof(struct acpi_init_walk_info));
  52. /* Walk entire namespace from the supplied root */
  53. /*
  54. * TBD: will become ACPI_TYPE_PACKAGE as this type object
  55. * is now the only one that supports deferred initialization
  56. * (forward references).
  57. */
  58. status = acpi_walk_namespace(ACPI_TYPE_ANY, ACPI_ROOT_OBJECT,
  59. ACPI_UINT32_MAX, acpi_ns_init_one_object,
  60. NULL, &info, NULL);
  61. if (ACPI_FAILURE(status)) {
  62. ACPI_EXCEPTION((AE_INFO, status, "During WalkNamespace"));
  63. }
  64. ACPI_DEBUG_PRINT_RAW((ACPI_DB_INIT,
  65. "Namespace contains %u (0x%X) objects\n",
  66. info.object_count, info.object_count));
  67. ACPI_DEBUG_PRINT((ACPI_DB_DISPATCH,
  68. "%u Control Methods found\n%u Op Regions found\n",
  69. info.method_count, info.op_region_count));
  70. return_ACPI_STATUS(AE_OK);
  71. }
  72. /*******************************************************************************
  73. *
  74. * FUNCTION: acpi_ns_initialize_devices
  75. *
  76. * PARAMETERS: None
  77. *
  78. * RETURN: acpi_status
  79. *
  80. * DESCRIPTION: Walk the entire namespace and initialize all ACPI devices.
  81. * This means running _INI on all present devices.
  82. *
  83. * Note: We install PCI config space handler on region access,
  84. * not here.
  85. *
  86. ******************************************************************************/
  87. acpi_status acpi_ns_initialize_devices(u32 flags)
  88. {
  89. acpi_status status = AE_OK;
  90. struct acpi_device_walk_info info;
  91. acpi_handle handle;
  92. ACPI_FUNCTION_TRACE(ns_initialize_devices);
  93. if (!(flags & ACPI_NO_DEVICE_INIT)) {
  94. ACPI_DEBUG_PRINT((ACPI_DB_EXEC,
  95. "[Init] Initializing ACPI Devices\n"));
  96. /* Init counters */
  97. info.device_count = 0;
  98. info.num_STA = 0;
  99. info.num_INI = 0;
  100. ACPI_DEBUG_PRINT_RAW((ACPI_DB_INIT,
  101. "Initializing Device/Processor/Thermal objects "
  102. "and executing _INI/_STA methods:\n"));
  103. /* Tree analysis: find all subtrees that contain _INI methods */
  104. status = acpi_ns_walk_namespace(ACPI_TYPE_ANY, ACPI_ROOT_OBJECT,
  105. ACPI_UINT32_MAX, FALSE,
  106. acpi_ns_find_ini_methods, NULL,
  107. &info, NULL);
  108. if (ACPI_FAILURE(status)) {
  109. goto error_exit;
  110. }
  111. /* Allocate the evaluation information block */
  112. info.evaluate_info =
  113. ACPI_ALLOCATE_ZEROED(sizeof(struct acpi_evaluate_info));
  114. if (!info.evaluate_info) {
  115. status = AE_NO_MEMORY;
  116. goto error_exit;
  117. }
  118. /*
  119. * Execute the "global" _INI method that may appear at the root.
  120. * This support is provided for Windows compatibility (Vista+) and
  121. * is not part of the ACPI specification.
  122. */
  123. info.evaluate_info->prefix_node = acpi_gbl_root_node;
  124. info.evaluate_info->relative_pathname = METHOD_NAME__INI;
  125. info.evaluate_info->parameters = NULL;
  126. info.evaluate_info->flags = ACPI_IGNORE_RETURN_VALUE;
  127. status = acpi_ns_evaluate(info.evaluate_info);
  128. if (ACPI_SUCCESS(status)) {
  129. info.num_INI++;
  130. }
  131. /*
  132. * Execute \_SB._INI.
  133. * There appears to be a strict order requirement for \_SB._INI,
  134. * which should be evaluated before any _REG evaluations.
  135. */
  136. status = acpi_get_handle(NULL, "\\_SB", &handle);
  137. if (ACPI_SUCCESS(status)) {
  138. memset(info.evaluate_info, 0,
  139. sizeof(struct acpi_evaluate_info));
  140. info.evaluate_info->prefix_node = handle;
  141. info.evaluate_info->relative_pathname =
  142. METHOD_NAME__INI;
  143. info.evaluate_info->parameters = NULL;
  144. info.evaluate_info->flags = ACPI_IGNORE_RETURN_VALUE;
  145. status = acpi_ns_evaluate(info.evaluate_info);
  146. if (ACPI_SUCCESS(status)) {
  147. info.num_INI++;
  148. }
  149. }
  150. }
  151. /*
  152. * Run all _REG methods
  153. *
  154. * Note: Any objects accessed by the _REG methods will be automatically
  155. * initialized, even if they contain executable AML (see the call to
  156. * acpi_ns_initialize_objects below).
  157. *
  158. * Note: According to the ACPI specification, we actually needn't execute
  159. * _REG for system_memory/system_io operation regions, but for PCI_Config
  160. * operation regions, it is required to evaluate _REG for those on a PCI
  161. * root bus that doesn't contain _BBN object. So this code is kept here
  162. * in order not to break things.
  163. */
  164. if (!(flags & ACPI_NO_ADDRESS_SPACE_INIT)) {
  165. ACPI_DEBUG_PRINT((ACPI_DB_EXEC,
  166. "[Init] Executing _REG OpRegion methods\n"));
  167. status = acpi_ev_initialize_op_regions();
  168. if (ACPI_FAILURE(status)) {
  169. goto error_exit;
  170. }
  171. }
  172. if (!(flags & ACPI_NO_DEVICE_INIT)) {
  173. /* Walk namespace to execute all _INIs on present devices */
  174. status = acpi_ns_walk_namespace(ACPI_TYPE_ANY, ACPI_ROOT_OBJECT,
  175. ACPI_UINT32_MAX, FALSE,
  176. acpi_ns_init_one_device, NULL,
  177. &info, NULL);
  178. /*
  179. * Any _OSI requests should be completed by now. If the BIOS has
  180. * requested any Windows OSI strings, we will always truncate
  181. * I/O addresses to 16 bits -- for Windows compatibility.
  182. */
  183. if (acpi_gbl_osi_data >= ACPI_OSI_WIN_2000) {
  184. acpi_gbl_truncate_io_addresses = TRUE;
  185. }
  186. ACPI_FREE(info.evaluate_info);
  187. if (ACPI_FAILURE(status)) {
  188. goto error_exit;
  189. }
  190. ACPI_DEBUG_PRINT_RAW((ACPI_DB_INIT,
  191. " Executed %u _INI methods requiring %u _STA executions "
  192. "(examined %u objects)\n",
  193. info.num_INI, info.num_STA,
  194. info.device_count));
  195. }
  196. return_ACPI_STATUS(status);
  197. error_exit:
  198. ACPI_EXCEPTION((AE_INFO, status, "During device initialization"));
  199. return_ACPI_STATUS(status);
  200. }
  201. /*******************************************************************************
  202. *
  203. * FUNCTION: acpi_ns_init_one_package
  204. *
  205. * PARAMETERS: obj_handle - Node
  206. * level - Current nesting level
  207. * context - Not used
  208. * return_value - Not used
  209. *
  210. * RETURN: Status
  211. *
  212. * DESCRIPTION: Callback from acpi_walk_namespace. Invoked for every package
  213. * within the namespace. Used during dynamic load of an SSDT.
  214. *
  215. ******************************************************************************/
  216. acpi_status
  217. acpi_ns_init_one_package(acpi_handle obj_handle,
  218. u32 level, void *context, void **return_value)
  219. {
  220. acpi_status status;
  221. union acpi_operand_object *obj_desc;
  222. struct acpi_namespace_node *node =
  223. (struct acpi_namespace_node *)obj_handle;
  224. obj_desc = acpi_ns_get_attached_object(node);
  225. if (!obj_desc) {
  226. return (AE_OK);
  227. }
  228. /* Exit if package is already initialized */
  229. if (obj_desc->package.flags & AOPOBJ_DATA_VALID) {
  230. return (AE_OK);
  231. }
  232. status = acpi_ds_get_package_arguments(obj_desc);
  233. if (ACPI_FAILURE(status)) {
  234. return (AE_OK);
  235. }
  236. status =
  237. acpi_ut_walk_package_tree(obj_desc, NULL,
  238. acpi_ds_init_package_element, NULL);
  239. if (ACPI_FAILURE(status)) {
  240. return (AE_OK);
  241. }
  242. obj_desc->package.flags |= AOPOBJ_DATA_VALID;
  243. return (AE_OK);
  244. }
  245. /*******************************************************************************
  246. *
  247. * FUNCTION: acpi_ns_init_one_object
  248. *
  249. * PARAMETERS: obj_handle - Node
  250. * level - Current nesting level
  251. * context - Points to a init info struct
  252. * return_value - Not used
  253. *
  254. * RETURN: Status
  255. *
  256. * DESCRIPTION: Callback from acpi_walk_namespace. Invoked for every object
  257. * within the namespace.
  258. *
  259. * Currently, the only objects that require initialization are:
  260. * 1) Methods
  261. * 2) Op Regions
  262. *
  263. ******************************************************************************/
  264. static acpi_status
  265. acpi_ns_init_one_object(acpi_handle obj_handle,
  266. u32 level, void *context, void **return_value)
  267. {
  268. acpi_object_type type;
  269. acpi_status status = AE_OK;
  270. struct acpi_init_walk_info *info =
  271. (struct acpi_init_walk_info *)context;
  272. struct acpi_namespace_node *node =
  273. (struct acpi_namespace_node *)obj_handle;
  274. union acpi_operand_object *obj_desc;
  275. ACPI_FUNCTION_NAME(ns_init_one_object);
  276. info->object_count++;
  277. /* And even then, we are only interested in a few object types */
  278. type = acpi_ns_get_type(obj_handle);
  279. obj_desc = acpi_ns_get_attached_object(node);
  280. if (!obj_desc) {
  281. return (AE_OK);
  282. }
  283. /* Increment counters for object types we are looking for */
  284. switch (type) {
  285. case ACPI_TYPE_REGION:
  286. info->op_region_count++;
  287. break;
  288. case ACPI_TYPE_BUFFER_FIELD:
  289. info->field_count++;
  290. break;
  291. case ACPI_TYPE_LOCAL_BANK_FIELD:
  292. info->field_count++;
  293. break;
  294. case ACPI_TYPE_BUFFER:
  295. info->buffer_count++;
  296. break;
  297. case ACPI_TYPE_PACKAGE:
  298. info->package_count++;
  299. break;
  300. default:
  301. /* No init required, just exit now */
  302. return (AE_OK);
  303. }
  304. /* If the object is already initialized, nothing else to do */
  305. if (obj_desc->common.flags & AOPOBJ_DATA_VALID) {
  306. return (AE_OK);
  307. }
  308. /* Must lock the interpreter before executing AML code */
  309. acpi_ex_enter_interpreter();
  310. /*
  311. * Only initialization of Package objects can be deferred, in order
  312. * to support forward references.
  313. */
  314. switch (type) {
  315. case ACPI_TYPE_LOCAL_BANK_FIELD:
  316. /* TBD: bank_fields do not require deferred init, remove this code */
  317. info->field_init++;
  318. status = acpi_ds_get_bank_field_arguments(obj_desc);
  319. break;
  320. case ACPI_TYPE_PACKAGE:
  321. /* Complete the initialization/resolution of the package object */
  322. info->package_init++;
  323. status =
  324. acpi_ns_init_one_package(obj_handle, level, NULL, NULL);
  325. break;
  326. default:
  327. /* No other types should get here */
  328. status = AE_TYPE;
  329. ACPI_EXCEPTION((AE_INFO, status,
  330. "Opcode is not deferred [%4.4s] (%s)",
  331. acpi_ut_get_node_name(node),
  332. acpi_ut_get_type_name(type)));
  333. break;
  334. }
  335. if (ACPI_FAILURE(status)) {
  336. ACPI_EXCEPTION((AE_INFO, status,
  337. "Could not execute arguments for [%4.4s] (%s)",
  338. acpi_ut_get_node_name(node),
  339. acpi_ut_get_type_name(type)));
  340. }
  341. /*
  342. * We ignore errors from above, and always return OK, since we don't want
  343. * to abort the walk on any single error.
  344. */
  345. acpi_ex_exit_interpreter();
  346. return (AE_OK);
  347. }
  348. /*******************************************************************************
  349. *
  350. * FUNCTION: acpi_ns_find_ini_methods
  351. *
  352. * PARAMETERS: acpi_walk_callback
  353. *
  354. * RETURN: acpi_status
  355. *
  356. * DESCRIPTION: Called during namespace walk. Finds objects named _INI under
  357. * device/processor/thermal objects, and marks the entire subtree
  358. * with a SUBTREE_HAS_INI flag. This flag is used during the
  359. * subsequent device initialization walk to avoid entire subtrees
  360. * that do not contain an _INI.
  361. *
  362. ******************************************************************************/
  363. static acpi_status
  364. acpi_ns_find_ini_methods(acpi_handle obj_handle,
  365. u32 nesting_level, void *context, void **return_value)
  366. {
  367. struct acpi_device_walk_info *info =
  368. ACPI_CAST_PTR(struct acpi_device_walk_info, context);
  369. struct acpi_namespace_node *node;
  370. struct acpi_namespace_node *parent_node;
  371. /* Keep count of device/processor/thermal objects */
  372. node = ACPI_CAST_PTR(struct acpi_namespace_node, obj_handle);
  373. if ((node->type == ACPI_TYPE_DEVICE) ||
  374. (node->type == ACPI_TYPE_PROCESSOR) ||
  375. (node->type == ACPI_TYPE_THERMAL)) {
  376. info->device_count++;
  377. return (AE_OK);
  378. }
  379. /* We are only looking for methods named _INI */
  380. if (!ACPI_COMPARE_NAMESEG(node->name.ascii, METHOD_NAME__INI)) {
  381. return (AE_OK);
  382. }
  383. /*
  384. * The only _INI methods that we care about are those that are
  385. * present under Device, Processor, and Thermal objects.
  386. */
  387. parent_node = node->parent;
  388. switch (parent_node->type) {
  389. case ACPI_TYPE_DEVICE:
  390. case ACPI_TYPE_PROCESSOR:
  391. case ACPI_TYPE_THERMAL:
  392. /* Mark parent and bubble up the INI present flag to the root */
  393. while (parent_node) {
  394. parent_node->flags |= ANOBJ_SUBTREE_HAS_INI;
  395. parent_node = parent_node->parent;
  396. }
  397. break;
  398. default:
  399. break;
  400. }
  401. return (AE_OK);
  402. }
  403. /*******************************************************************************
  404. *
  405. * FUNCTION: acpi_ns_init_one_device
  406. *
  407. * PARAMETERS: acpi_walk_callback
  408. *
  409. * RETURN: acpi_status
  410. *
  411. * DESCRIPTION: This is called once per device soon after ACPI is enabled
  412. * to initialize each device. It determines if the device is
  413. * present, and if so, calls _INI.
  414. *
  415. ******************************************************************************/
  416. static acpi_status
  417. acpi_ns_init_one_device(acpi_handle obj_handle,
  418. u32 nesting_level, void *context, void **return_value)
  419. {
  420. struct acpi_device_walk_info *walk_info =
  421. ACPI_CAST_PTR(struct acpi_device_walk_info, context);
  422. struct acpi_evaluate_info *info = walk_info->evaluate_info;
  423. u32 flags;
  424. acpi_status status;
  425. struct acpi_namespace_node *device_node;
  426. ACPI_FUNCTION_TRACE(ns_init_one_device);
  427. /* We are interested in Devices, Processors and thermal_zones only */
  428. device_node = ACPI_CAST_PTR(struct acpi_namespace_node, obj_handle);
  429. if ((device_node->type != ACPI_TYPE_DEVICE) &&
  430. (device_node->type != ACPI_TYPE_PROCESSOR) &&
  431. (device_node->type != ACPI_TYPE_THERMAL)) {
  432. return_ACPI_STATUS(AE_OK);
  433. }
  434. /*
  435. * Because of an earlier namespace analysis, all subtrees that contain an
  436. * _INI method are tagged.
  437. *
  438. * If this device subtree does not contain any _INI methods, we
  439. * can exit now and stop traversing this entire subtree.
  440. */
  441. if (!(device_node->flags & ANOBJ_SUBTREE_HAS_INI)) {
  442. return_ACPI_STATUS(AE_CTRL_DEPTH);
  443. }
  444. /*
  445. * Run _STA to determine if this device is present and functioning. We
  446. * must know this information for two important reasons (from ACPI spec):
  447. *
  448. * 1) We can only run _INI if the device is present.
  449. * 2) We must abort the device tree walk on this subtree if the device is
  450. * not present and is not functional (we will not examine the children)
  451. *
  452. * The _STA method is not required to be present under the device, we
  453. * assume the device is present if _STA does not exist.
  454. */
  455. ACPI_DEBUG_EXEC(acpi_ut_display_init_pathname
  456. (ACPI_TYPE_METHOD, device_node, METHOD_NAME__STA));
  457. status = acpi_ut_execute_STA(device_node, &flags);
  458. if (ACPI_FAILURE(status)) {
  459. /* Ignore error and move on to next device */
  460. return_ACPI_STATUS(AE_OK);
  461. }
  462. /*
  463. * Flags == -1 means that _STA was not found. In this case, we assume that
  464. * the device is both present and functional.
  465. *
  466. * From the ACPI spec, description of _STA:
  467. *
  468. * "If a device object (including the processor object) does not have an
  469. * _STA object, then OSPM assumes that all of the above bits are set (in
  470. * other words, the device is present, ..., and functioning)"
  471. */
  472. if (flags != ACPI_UINT32_MAX) {
  473. walk_info->num_STA++;
  474. }
  475. /*
  476. * Examine the PRESENT and FUNCTIONING status bits
  477. *
  478. * Note: ACPI spec does not seem to specify behavior for the present but
  479. * not functioning case, so we assume functioning if present.
  480. */
  481. if (!(flags & ACPI_STA_DEVICE_PRESENT)) {
  482. /* Device is not present, we must examine the Functioning bit */
  483. if (flags & ACPI_STA_DEVICE_FUNCTIONING) {
  484. /*
  485. * Device is not present but is "functioning". In this case,
  486. * we will not run _INI, but we continue to examine the children
  487. * of this device.
  488. *
  489. * From the ACPI spec, description of _STA: (note - no mention
  490. * of whether to run _INI or not on the device in question)
  491. *
  492. * "_STA may return bit 0 clear (not present) with bit 3 set
  493. * (device is functional). This case is used to indicate a valid
  494. * device for which no device driver should be loaded (for example,
  495. * a bridge device.) Children of this device may be present and
  496. * valid. OSPM should continue enumeration below a device whose
  497. * _STA returns this bit combination"
  498. */
  499. return_ACPI_STATUS(AE_OK);
  500. } else {
  501. /*
  502. * Device is not present and is not functioning. We must abort the
  503. * walk of this subtree immediately -- don't look at the children
  504. * of such a device.
  505. *
  506. * From the ACPI spec, description of _INI:
  507. *
  508. * "If the _STA method indicates that the device is not present,
  509. * OSPM will not run the _INI and will not examine the children
  510. * of the device for _INI methods"
  511. */
  512. return_ACPI_STATUS(AE_CTRL_DEPTH);
  513. }
  514. }
  515. /*
  516. * The device is present or is assumed present if no _STA exists.
  517. * Run the _INI if it exists (not required to exist)
  518. *
  519. * Note: We know there is an _INI within this subtree, but it may not be
  520. * under this particular device, it may be lower in the branch.
  521. */
  522. if (!ACPI_COMPARE_NAMESEG(device_node->name.ascii, "_SB_") ||
  523. device_node->parent != acpi_gbl_root_node) {
  524. ACPI_DEBUG_EXEC(acpi_ut_display_init_pathname
  525. (ACPI_TYPE_METHOD, device_node,
  526. METHOD_NAME__INI));
  527. memset(info, 0, sizeof(struct acpi_evaluate_info));
  528. info->prefix_node = device_node;
  529. info->relative_pathname = METHOD_NAME__INI;
  530. info->parameters = NULL;
  531. info->flags = ACPI_IGNORE_RETURN_VALUE;
  532. status = acpi_ns_evaluate(info);
  533. if (ACPI_SUCCESS(status)) {
  534. walk_info->num_INI++;
  535. }
  536. #ifdef ACPI_DEBUG_OUTPUT
  537. else if (status != AE_NOT_FOUND) {
  538. /* Ignore error and move on to next device */
  539. char *scope_name =
  540. acpi_ns_get_normalized_pathname(device_node, TRUE);
  541. ACPI_EXCEPTION((AE_INFO, status,
  542. "during %s._INI execution",
  543. scope_name));
  544. ACPI_FREE(scope_name);
  545. }
  546. #endif
  547. }
  548. /* Ignore errors from above */
  549. status = AE_OK;
  550. /*
  551. * The _INI method has been run if present; call the Global Initialization
  552. * Handler for this device.
  553. */
  554. if (acpi_gbl_init_handler) {
  555. status =
  556. acpi_gbl_init_handler(device_node, ACPI_INIT_DEVICE_INI);
  557. }
  558. return_ACPI_STATUS(status);
  559. }