1 /* 2 * Some or all of this work - Copyright (c) 2006 - 2021, Intel Corp. 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without modification, 6 * are permitted provided that the following conditions are met: 7 * 8 * Redistributions of source code must retain the above copyright notice, 9 * this list of conditions and the following disclaimer. 10 * Redistributions in binary form must reproduce the above copyright notice, 11 * this list of conditions and the following disclaimer in the documentation 12 * and/or other materials provided with the distribution. 13 * Neither the name of Intel Corporation nor the names of its contributors 14 * may be used to endorse or promote products derived from this software 15 * without specific prior written permission. 16 * 17 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 18 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 20 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE 21 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 23 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 24 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 25 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, 26 * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 */ 28 /* 29 * Power Resource 30 * 31 * (verify exceptions caused by the imprope use of Power Resource type objects) 32 */ 33 Name (Z103, 0x67) 34 PowerResource (PW00, 0x01, 0x0000) 35 { 36 Method (M000, 0, NotSerialized) 37 { 38 Return (0x00) 39 } 40 } 41 42 /* Expected exceptions: */ 43 /* */ 44 /* 47 - AE_AML_OPERAND_TYPE */ 45 /* */ 46 Method (M4BB, 0, Serialized) 47 { 48 PowerResource (PW01, 0x01, 0x0000) 49 { 50 Method (M000, 0, NotSerialized) 51 { 52 Return (0x00) 53 } 54 } 55 56 Event (E000) 57 Name (I000, 0x00) 58 /* Local Named Object */ 59 60 Method (M000, 1, Serialized) 61 { 62 /* These are now caught by the compiler - Aug 2015 63 PowerResource(pw02, 1, 0) {Method(m000){return (0)}} 64 if (y083) { 65 Store (DerefOf(pw02), Local1) 66 CH06(arg0, 0, 47) 67 } 68 */ 69 } 70 71 /* Global Named Object */ 72 73 Method (M001, 1, NotSerialized) 74 { 75 /* These are now caught by the compiler - Aug 2015 76 if (y083) { 77 Store (DerefOf(pw00), Local1) 78 CH06(arg0, 1, 47) 79 } 80 */ 81 } 82 83 /* Local */ 84 85 Method (M002, 1, Serialized) 86 { 87 PowerResource (PW02, 0x01, 0x0000) 88 { 89 Method (M000, 0, NotSerialized) 90 { 91 Return (0x00) 92 } 93 } 94 95 Event (E000) 96 CopyObject (PW02, Local0) 97 /* CondRefOf */ 98 99 CondRefOf (Local0, Local1) 100 CH03 (__METHOD__, Z103, __LINE__, 0x00, 0x00) 101 /* CopyObject */ 102 103 CopyObject (Local0, Local1) 104 CH03 (__METHOD__, Z103, __LINE__, 0x00, 0x00) 105 /* Decrement */ 106 107 Local0-- 108 CH06 (Arg0, 0x01, 0x2F) 109 /* DerefOf */ 110 111 Local1 = DerefOf (Local0) 112 CH06 (Arg0, 0x02, 0x2F) 113 /* FindSetLeftBit */ 114 115 FindSetLeftBit (Local0, Local1) 116 CH06 (Arg0, 0x04, 0x2F) 117 /* FindSetRightBit */ 118 119 FindSetRightBit (Local0, Local1) 120 CH06 (Arg0, 0x06, 0x2F) 121 /* FromBCD */ 122 123 FromBCD (Local0, Local1) 124 CH06 (Arg0, 0x08, 0x2F) 125 /* Increment */ 126 127 Local0++ 128 CH06 (Arg0, 0x09, 0x2F) 129 /* LNot */ 130 131 Local1 = !Local0 132 CH06 (Arg0, 0x0A, 0x2F) 133 /* Not */ 134 135 Local1 = ~Local0 136 CH06 (Arg0, 0x0C, 0x2F) 137 /* ObjectType */ 138 139 Local1 = ObjectType (Local0) 140 CH03 (__METHOD__, Z103, __LINE__, 0x00, 0x00) 141 /* RefOf */ 142 143 Local1 = RefOf (Local0) 144 CH03 (__METHOD__, Z103, __LINE__, 0x00, 0x00) 145 /* Release */ 146 147 Release (Local0) 148 CH06 (Arg0, 0x0D, 0x2F) 149 /* Reset */ 150 151 Reset (Local0) 152 CH06 (Arg0, 0x0E, 0x2F) 153 /* Signal */ 154 155 Signal (Local0) 156 CH06 (Arg0, 0x0F, 0x2F) 157 /* SizeOf */ 158 159 Local1 = SizeOf (Local0) 160 CH06 (Arg0, 0x10, 0x2F) 161 /* Sleep */ 162 163 Sleep (Local0) 164 CH06 (Arg0, 0x11, 0x2F) 165 /* Stall */ 166 167 Stall (Local0) 168 CH06 (Arg0, 0x12, 0x2F) 169 /* Store */ 170 171 Local1 = Local0 172 CH06 (Arg0, 0x13, 0x2F) 173 /* ToBCD */ 174 175 ToBCD (Local0, Local1) 176 CH06 (Arg0, 0x15, 0x2F) 177 /* ToBuffer */ 178 179 ToBuffer (Local0, Local1) 180 CH06 (Arg0, 0x17, 0x2F) 181 /* ToDecimalString */ 182 183 ToDecimalString (Local0, Local1) 184 CH06 (Arg0, 0x19, 0x2F) 185 /* ToHexString */ 186 187 ToHexString (Local0, Local1) 188 CH06 (Arg0, 0x1B, 0x2F) 189 /* ToInteger */ 190 191 ToInteger (Local0, Local1) 192 CH06 (Arg0, 0x1D, 0x2F) 193 /* Acquire */ 194 195 Local1 = Acquire (Local0, 0x0064) 196 CH06 (Arg0, 0x1E, 0x2F) 197 /* Add */ 198 199 Local1 = (Local0 + I000) /* \M4BB.I000 */ 200 CH06 (Arg0, 0x21, 0x2F) 201 Local1 = (I000 + Local0) 202 CH06 (Arg0, 0x22, 0x2F) 203 /* And */ 204 205 Local1 = (Local0 & I000) /* \M4BB.I000 */ 206 CH06 (Arg0, 0x25, 0x2F) 207 Local1 = (I000 & Local0) 208 CH06 (Arg0, 0x26, 0x2F) 209 /* Concatenate */ 210 211 Concatenate (Local0, I000, Local1) 212 CH06 (Arg0, 0x29, 0x2F) 213 Concatenate (I000, Local0, Local1) 214 CH06 (Arg0, 0x2A, 0x2F) 215 /* ConcatenateResTemplate */ 216 217 ConcatenateResTemplate (Local0, Buffer (0x02) 218 { 219 0x79, 0x00 // y. 220 }, Local1) 221 CH06 (Arg0, 0x2D, 0x2F) 222 ConcatenateResTemplate (Buffer (0x02) 223 { 224 0x79, 0x00 // y. 225 }, Local0, Local1) 226 CH06 (Arg0, 0x2E, 0x2F) 227 /* Divide */ 228 229 Divide (Local0, I000, Local2) 230 CH06 (Arg0, 0x31, 0x2F) 231 Divide (I000, Local0, Local2) 232 CH06 (Arg0, 0x32, 0x2F) 233 Divide (Local0, I000, Local2, Local1) 234 CH06 (Arg0, 0x33, 0x2F) 235 Divide (I000, Local0, Local2, Local1) 236 CH06 (Arg0, 0x34, 0x2F) 237 /* Fatal */ 238 239 Fatal (0xFF, 0xFFFFFFFF, Local0) 240 CH06 (Arg0, 0x35, 0x2F) 241 /* Index */ 242 243 Local1 = Local0 [0x00] 244 CH06 (Arg0, 0x38, 0x2F) 245 Index ("0", Local0, Local1) 246 CH06 (Arg0, 0x39, 0x2F) 247 /* LEqual */ 248 249 Local1 = (Local0 == I000) 250 CH06 (Arg0, 0x3A, 0x2F) 251 Local1 = (I000 == Local0) 252 CH06 (Arg0, 0x3B, 0x2F) 253 /* LGreater */ 254 255 Local1 = (Local0 > I000) 256 CH06 (Arg0, 0x3C, 0x2F) 257 Local1 = (I000 > Local0) 258 CH06 (Arg0, 0x3D, 0x2F) 259 /* LGreaterEqual */ 260 261 Local1 = (Local0 >= I000) 262 CH06 (Arg0, 0x3E, 0xFF) 263 Local1 = (I000 >= Local0) 264 CH06 (Arg0, 0x3F, 0xFF) 265 /* LLess */ 266 267 Local1 = (Local0 < I000) 268 CH06 (Arg0, 0x40, 0x2F) 269 Local1 = (I000 < Local0) 270 CH06 (Arg0, 0x41, 0x2F) 271 /* LLessEqual */ 272 273 Local1 = (Local0 <= I000) 274 CH06 (Arg0, 0x42, 0xFF) 275 Local1 = (I000 <= Local0) 276 CH06 (Arg0, 0x43, 0xFF) 277 /* LNotEqual */ 278 279 Local1 = (Local0 != I000) 280 CH06 (Arg0, 0x44, 0xFF) 281 Local1 = (I000 != Local0) 282 CH06 (Arg0, 0x45, 0xFF) 283 /* LOr */ 284 285 Local1 = (Local0 || I000) 286 CH06 (Arg0, 0x46, 0x2F) 287 Local1 = (I000 || Local0) 288 CH06 (Arg0, 0x47, 0x2F) 289 /* Mod */ 290 291 Local1 = (Local0 % I000) /* \M4BB.I000 */ 292 CH06 (Arg0, 0x4A, 0x2F) 293 Local1 = (I000 % Local0) 294 CH06 (Arg0, 0x4B, 0x2F) 295 /* Multiply */ 296 297 Local1 = (Local0 * I000) /* \M4BB.I000 */ 298 CH06 (Arg0, 0x4E, 0x2F) 299 Local1 = (I000 * Local0) 300 CH06 (Arg0, 0x4F, 0x2F) 301 /* NAnd */ 302 303 NAnd (Local0, I000, Local1) 304 CH06 (Arg0, 0x52, 0x2F) 305 NAnd (I000, Local0, Local1) 306 CH06 (Arg0, 0x53, 0x2F) 307 /* NOr */ 308 309 NOr (Local0, I000, Local1) 310 CH06 (Arg0, 0x56, 0x2F) 311 NOr (I000, Local0, Local1) 312 CH06 (Arg0, 0x57, 0x2F) 313 /* Or */ 314 315 Local1 = (Local0 | I000) /* \M4BB.I000 */ 316 CH06 (Arg0, 0x5A, 0x2F) 317 Local1 = (I000 | Local0) 318 CH06 (Arg0, 0x5B, 0x2F) 319 /* ShiftLeft */ 320 321 Local1 = (Local0 << I000) /* \M4BB.I000 */ 322 CH06 (Arg0, 0x5E, 0x2F) 323 Local1 = (I000 << Local0) 324 CH06 (Arg0, 0x5F, 0x2F) 325 /* ShiftRight */ 326 327 Local1 = (Local0 >> I000) /* \M4BB.I000 */ 328 CH06 (Arg0, 0x62, 0x2F) 329 Local1 = (I000 >> Local0) 330 CH06 (Arg0, 0x63, 0x2F) 331 /* Subtract */ 332 333 Local1 = (Local0 - I000) /* \M4BB.I000 */ 334 CH06 (Arg0, 0x66, 0x2F) 335 Local1 = (I000 - Local0) 336 CH06 (Arg0, 0x67, 0x2F) 337 /* ToString */ 338 339 ToString (Local0, 0x01, Local1) 340 CH06 (Arg0, 0x6A, 0x2F) 341 ToString (I000, Local0, Local1) 342 CH06 (Arg0, 0x6B, 0x2F) 343 /* Wait */ 344 345 Local1 = Wait (Local0, I000) 346 CH06 (Arg0, 0x6C, 0x2F) 347 Local1 = Wait (E000, Local0) 348 CH06 (Arg0, 0x6D, 0x2F) 349 /* XOr */ 350 351 Local1 = (Local0 ^ I000) /* \M4BB.I000 */ 352 CH06 (Arg0, 0x70, 0x2F) 353 Local1 = (I000 ^ Local0) 354 CH06 (Arg0, 0x71, 0x2F) 355 /* Mid */ 356 357 Mid (Local0, 0x01, 0x01, Local1) 358 CH06 (Arg0, 0x75, 0x2F) 359 Mid ("123", Local0, 0x01, Local1) 360 CH06 (Arg0, 0x76, 0x2F) 361 Mid ("123", 0x01, Local0, Local1) 362 CH06 (Arg0, 0x77, 0x2F) 363 /* Match */ 364 365 Local1 = Match (Local0, MTR, 0x00, MTR, 0x00, 0x00) 366 CH06 (Arg0, 0x78, 0x2F) 367 Local1 = Match (Package (0x01) 368 { 369 0x01 370 }, MTR, Local0, MTR, 0x00, 0x00) 371 CH06 (Arg0, 0x79, 0x2F) 372 Local1 = Match (Package (0x01) 373 { 374 0x01 375 }, MTR, 0x00, MTR, Local0, 0x00) 376 CH06 (Arg0, 0x7A, 0x2F) 377 Local1 = Match (Package (0x01) 378 { 379 0x01 380 }, MTR, 0x00, MTR, 0x00, Local0) 381 CH06 (Arg0, 0x7B, 0x2F) 382 } 383 384 /* Reference to Object */ 385 386 Method (M003, 2, NotSerialized) 387 { 388 Local0 = ObjectType (Arg1) 389 If ((Local0 != 0x0B)) 390 { 391 ERR (Arg0, Z103, __LINE__, 0x00, 0x00, Local0, 0x0B) 392 Return (0x01) 393 } 394 395 Local1 = DerefOf (Arg1) 396 If (!SLCK) 397 { 398 CH04 (__METHOD__, 0x00, 0x2F, Z103, __LINE__, 0x00, 0x00) 399 } 400 401 /* CondRefOf */ 402 403 CondRefOf (DerefOf (Arg1), Local1) 404 CH06 (Arg0, 0x01, 0x2F) 405 /* CopyObject */ 406 407 CopyObject (DerefOf (Arg1), Local1) 408 CH03 (__METHOD__, Z103, __LINE__, 0x00, 0x00) 409 /* Decrement */ 410 411 DerefOf (Arg1)-- 412 CH06 (Arg0, 0x03, 0x2F) 413 /* DerefOf */ 414 415 Local1 = DerefOf (DerefOf (Arg1)) 416 CH06 (Arg0, 0x04, 0x2F) 417 /* FindSetLeftBit */ 418 419 FindSetLeftBit (DerefOf (Arg1), Local1) 420 CH06 (Arg0, 0x06, 0x2F) 421 /* FindSetRightBit */ 422 423 FindSetRightBit (DerefOf (Arg1), Local1) 424 CH06 (Arg0, 0x08, 0x2F) 425 /* FromBCD */ 426 427 FromBCD (DerefOf (Arg1), Local1) 428 CH06 (Arg0, 0x0A, 0x2F) 429 /* Increment */ 430 431 DerefOf (Arg1)++ 432 CH06 (Arg0, 0x0B, 0x2F) 433 /* LNot */ 434 435 Local1 = !DerefOf (Arg1) 436 CH06 (Arg0, 0x0C, 0x2F) 437 /* Not */ 438 439 Local1 = ~DerefOf (Arg1) 440 CH06 (Arg0, 0x0E, 0x2F) 441 /* ObjectType */ 442 443 Local1 = ObjectType (DerefOf (Arg1)) 444 CH03 (__METHOD__, Z103, __LINE__, 0x00, 0x00) 445 /* RefOf */ 446 447 Local1 = RefOf (DerefOf (Arg1)) 448 CH06 (Arg0, 0x0F, 0x2F) 449 /* Release */ 450 /* Reset */ 451 /* Signal */ 452 /* SizeOf */ 453 Local1 = SizeOf (DerefOf (Arg1)) 454 CH06 (Arg0, 0x10, 0x2F) 455 /* Sleep */ 456 457 Sleep (DerefOf (Arg1)) 458 CH06 (Arg0, 0x11, 0x2F) 459 /* Stall */ 460 461 Stall (DerefOf (Arg1)) 462 CH06 (Arg0, 0x12, 0x2F) 463 /* Store */ 464 465 Local1 = DerefOf (Arg1) 466 CH06 (Arg0, 0x13, 0x2F) 467 /* ToBCD */ 468 469 ToBCD (DerefOf (Arg1), Local1) 470 CH06 (Arg0, 0x15, 0x2F) 471 /* ToBuffer */ 472 473 ToBuffer (DerefOf (Arg1), Local1) 474 CH06 (Arg0, 0x17, 0x2F) 475 /* ToDecimalString */ 476 477 ToDecimalString (DerefOf (Arg1), Local1) 478 CH06 (Arg0, 0x19, 0x2F) 479 /* ToHexString */ 480 481 ToHexString (DerefOf (Arg1), Local1) 482 CH06 (Arg0, 0x1B, 0x2F) 483 /* ToInteger */ 484 485 ToInteger (DerefOf (Arg1), Local1) 486 CH06 (Arg0, 0x1D, 0x2F) 487 /* Acquire */ 488 /* Add */ 489 Local1 = (DerefOf (Arg1) + I000) /* \M4BB.I000 */ 490 CH06 (Arg0, 0x21, 0x2F) 491 Local1 = (I000 + DerefOf (Arg1)) 492 CH06 (Arg0, 0x22, 0x2F) 493 /* And */ 494 495 Local1 = (DerefOf (Arg1) & I000) /* \M4BB.I000 */ 496 CH06 (Arg0, 0x25, 0x2F) 497 Local1 = (I000 & DerefOf (Arg1)) 498 CH06 (Arg0, 0x26, 0x2F) 499 /* Concatenate */ 500 501 Concatenate (DerefOf (Arg1), I000, Local1) 502 CH06 (Arg0, 0x29, 0x2F) 503 Concatenate (I000, DerefOf (Arg1), Local1) 504 CH06 (Arg0, 0x2A, 0x2F) 505 /* ConcatenateResTemplate */ 506 507 ConcatenateResTemplate (DerefOf (Arg1), Buffer (0x02) 508 { 509 0x79, 0x00 // y. 510 }, Local1) 511 CH06 (Arg0, 0x2D, 0x2F) 512 ConcatenateResTemplate (Buffer (0x02) 513 { 514 0x79, 0x00 // y. 515 }, DerefOf (Arg1), Local1) 516 CH06 (Arg0, 0x2E, 0x2F) 517 /* Divide */ 518 519 Divide (DerefOf (Arg1), I000, Local2) 520 CH06 (Arg0, 0x31, 0x2F) 521 Divide (I000, DerefOf (Arg1), Local2) 522 CH06 (Arg0, 0x32, 0x2F) 523 Divide (DerefOf (Arg1), I000, Local2, Local1) 524 CH06 (Arg0, 0x33, 0x2F) 525 Divide (I000, DerefOf (Arg1), Local2, Local1) 526 CH06 (Arg0, 0x34, 0x2F) 527 /* Fatal */ 528 529 Fatal (0xFF, 0xFFFFFFFF, DerefOf (Arg1)) 530 CH06 (Arg0, 0x35, 0x2F) 531 /* Index */ 532 533 Local1 = DerefOf (Arg1) [0x00] 534 CH06 (Arg0, 0x38, 0x2F) 535 Index ("0", DerefOf (Arg1), Local1) 536 CH06 (Arg0, 0x39, 0x2F) 537 /* LEqual */ 538 539 Local1 = (DerefOf (Arg1) == I000) 540 CH06 (Arg0, 0x3A, 0x2F) 541 Local1 = (I000 == DerefOf (Arg1)) 542 CH06 (Arg0, 0x3B, 0x2F) 543 /* LGreater */ 544 545 Local1 = (DerefOf (Arg1) > I000) 546 CH06 (Arg0, 0x3C, 0x2F) 547 Local1 = (I000 > DerefOf (Arg1)) 548 CH06 (Arg0, 0x3D, 0x2F) 549 /* LGreaterEqual */ 550 551 Local1 = (DerefOf (Arg1) >= I000) 552 CH06 (Arg0, 0x3E, 0xFF) 553 Local1 = (I000 >= DerefOf (Arg1)) 554 CH06 (Arg0, 0x3F, 0xFF) 555 /* LLess */ 556 557 Local1 = (DerefOf (Arg1) < I000) 558 CH06 (Arg0, 0x40, 0x2F) 559 Local1 = (I000 < DerefOf (Arg1)) 560 CH06 (Arg0, 0x41, 0x2F) 561 /* LLessEqual */ 562 563 Local1 = (DerefOf (Arg1) <= I000) 564 CH06 (Arg0, 0x42, 0xFF) 565 Local1 = (I000 <= DerefOf (Arg1)) 566 CH06 (Arg0, 0x43, 0xFF) 567 /* LNotEqual */ 568 569 Local1 = (DerefOf (Arg1) != I000) 570 CH06 (Arg0, 0x44, 0xFF) 571 Local1 = (I000 != DerefOf (Arg1)) 572 CH06 (Arg0, 0x45, 0xFF) 573 /* LOr */ 574 575 Local1 = (DerefOf (Arg1) || I000) 576 CH06 (Arg0, 0x46, 0x2F) 577 Local1 = (I000 || DerefOf (Arg1)) 578 CH06 (Arg0, 0x47, 0x2F) 579 /* Mod */ 580 581 Local1 = (DerefOf (Arg1) % I000) /* \M4BB.I000 */ 582 CH06 (Arg0, 0x4A, 0x2F) 583 Local1 = (I000 % DerefOf (Arg1)) 584 CH06 (Arg0, 0x4B, 0x2F) 585 /* Multiply */ 586 587 Local1 = (DerefOf (Arg1) * I000) /* \M4BB.I000 */ 588 CH06 (Arg0, 0x4E, 0x2F) 589 Local1 = (I000 * DerefOf (Arg1)) 590 CH06 (Arg0, 0x4F, 0x2F) 591 /* NAnd */ 592 593 NAnd (DerefOf (Arg1), I000, Local1) 594 CH06 (Arg0, 0x52, 0x2F) 595 NAnd (I000, DerefOf (Arg1), Local1) 596 CH06 (Arg0, 0x53, 0x2F) 597 /* NOr */ 598 599 NOr (DerefOf (Arg1), I000, Local1) 600 CH06 (Arg0, 0x56, 0x2F) 601 NOr (I000, DerefOf (Arg1), Local1) 602 CH06 (Arg0, 0x57, 0x2F) 603 /* Or */ 604 605 Local1 = (DerefOf (Arg1) | I000) /* \M4BB.I000 */ 606 CH06 (Arg0, 0x5A, 0x2F) 607 Local1 = (I000 | DerefOf (Arg1)) 608 CH06 (Arg0, 0x5B, 0x2F) 609 /* ShiftLeft */ 610 611 Local1 = (DerefOf (Arg1) << I000) /* \M4BB.I000 */ 612 CH06 (Arg0, 0x5E, 0x2F) 613 Local1 = (I000 << DerefOf (Arg1)) 614 CH06 (Arg0, 0x5F, 0x2F) 615 /* ShiftRight */ 616 617 Local1 = (DerefOf (Arg1) >> I000) /* \M4BB.I000 */ 618 CH06 (Arg0, 0x62, 0x2F) 619 Local1 = (I000 >> DerefOf (Arg1)) 620 CH06 (Arg0, 0x63, 0x2F) 621 /* Subtract */ 622 623 Local1 = (DerefOf (Arg1) - I000) /* \M4BB.I000 */ 624 CH06 (Arg0, 0x66, 0x2F) 625 Local1 = (I000 - DerefOf (Arg1)) 626 CH06 (Arg0, 0x67, 0x2F) 627 /* ToString */ 628 629 ToString (DerefOf (Arg1), 0x01, Local1) 630 CH06 (Arg0, 0x6A, 0x2F) 631 ToString (I000, DerefOf (Arg1), Local1) 632 CH06 (Arg0, 0x6B, 0x2F) 633 /* Wait */ 634 635 Local1 = Wait (E000, DerefOf (Arg1)) 636 CH06 (Arg0, 0x6D, 0x2F) 637 /* XOr */ 638 639 Local1 = (DerefOf (Arg1) ^ I000) /* \M4BB.I000 */ 640 CH06 (Arg0, 0x70, 0x2F) 641 Local1 = (I000 ^ DerefOf (Arg1)) 642 CH06 (Arg0, 0x71, 0x2F) 643 /* Mid */ 644 645 Mid (DerefOf (Arg1), 0x01, 0x01, Local1) 646 CH06 (Arg0, 0x75, 0x2F) 647 Mid ("123", DerefOf (Arg1), 0x01, Local1) 648 CH06 (Arg0, 0x76, 0x2F) 649 Mid ("123", 0x01, DerefOf (Arg1), Local1) 650 CH06 (Arg0, 0x77, 0x2F) 651 /* Match */ 652 653 Local1 = Match (DerefOf (Arg1), MTR, 0x00, MTR, 0x00, 0x00) 654 CH06 (Arg0, 0x78, 0x2F) 655 Local1 = Match (Package (0x01) 656 { 657 0x01 658 }, MTR, DerefOf (Arg1), MTR, 0x00, 0x00) 659 CH06 (Arg0, 0x79, 0x2F) 660 Local1 = Match (Package (0x01) 661 { 662 0x01 663 }, MTR, 0x00, MTR, DerefOf (Arg1), 0x00) 664 CH06 (Arg0, 0x7A, 0x2F) 665 Local1 = Match (Package (0x01) 666 { 667 0x01 668 }, MTR, 0x00, MTR, 0x00, DerefOf (Arg1)) 669 CH06 (Arg0, 0x7B, 0x2F) 670 Return (0x00) 671 } 672 673 /* Result of Method invocation */ 674 675 Method (M004, 1, Serialized) 676 { 677 Name (I000, 0x00) /* Label to check m000 invocations */ 678 Method (M000, 0, NotSerialized) 679 { 680 CopyObject (PW00, Local0) 681 Return (Local0) 682 } 683 684 /* CondRefOf */ 685 /* **** 10/2016 changed method invocation to just a namestring */ 686 /* CondRefOf no longer invokes the method */ 687 If (Y601) 688 { 689 Local1 = CondRefOf (M000) 690 CH06 (Arg0, 0x00, 0x2F) 691 Local1 = CondRefOf (M000) 692 CH06 (Arg0, 0x01, 0x2F) 693 } 694 695 /* CopyObject */ 696 697 CopyObject (M000 (), Local1) 698 CH03 (__METHOD__, Z103, __LINE__, 0x00, 0x00) 699 /* Decrement */ 700 701 M000 ()-- 702 CH06 (Arg0, 0x02, 0x2F) 703 /* DerefOf */ 704 705 Local1 = DerefOf (M000 ()) 706 CH06 (Arg0, 0x03, 0x2F) 707 /* FindSetLeftBit */ 708 709 FindSetLeftBit (M000 (), Local1) 710 CH06 (Arg0, 0x05, 0x2F) 711 /* FindSetRightBit */ 712 713 FindSetRightBit (M000 (), Local1) 714 CH06 (Arg0, 0x07, 0x2F) 715 /* FromBCD */ 716 717 FromBCD (M000 (), Local1) 718 CH06 (Arg0, 0x09, 0x2F) 719 /* Increment */ 720 721 M000 ()++ 722 CH06 (Arg0, 0x0A, 0x2F) 723 /* LNot */ 724 725 Local1 = !M000 () 726 CH06 (Arg0, 0x0B, 0x2F) 727 /* Not */ 728 729 Local1 = ~M000 () 730 CH06 (Arg0, 0x0D, 0x2F) 731 /* ObjectType */ 732 /* **** Nov. 2016: Method invocation as arg to ObjectType is now illegal */ 733 Local0 = ObjectType (M000) 734 CH03 (__METHOD__, Z103, __LINE__, 0x00, 0x00) 735 /* RefOf */ 736 /* **** Oct. 2016: Method invocation as arg to RefOf is now illegal */ 737 /* if (y601) { */ 738 /* Store (RefOf(m000()), Local1) */ 739 /* CH06(arg0, 14, 47) */ 740 /* } */ 741 /* Release */ 742 Release (M000 ()) 743 CH06 (Arg0, 0x0D, 0x2F) 744 /* Reset */ 745 746 Reset (M000 ()) 747 CH06 (Arg0, 0x0E, 0x2F) 748 /* Signal */ 749 750 Signal (M000 ()) 751 CH06 (Arg0, 0x0F, 0x2F) 752 /* SizeOf */ 753 754 Local1 = SizeOf (M000 ()) 755 CH06 (Arg0, 0x10, 0x2F) 756 /* Sleep */ 757 758 Sleep (M000 ()) 759 CH06 (Arg0, 0x11, 0x2F) 760 /* Stall */ 761 762 Stall (M000 ()) 763 CH06 (Arg0, 0x12, 0x2F) 764 /* Store */ 765 766 Local1 = M000 () 767 CH06 (Arg0, 0x13, 0x2F) 768 /* ToBCD */ 769 770 ToBCD (M000 (), Local1) 771 CH06 (Arg0, 0x15, 0x2F) 772 /* ToBuffer */ 773 774 ToBuffer (M000 (), Local1) 775 CH06 (Arg0, 0x17, 0x2F) 776 /* ToDecimalString */ 777 778 ToDecimalString (M000 (), Local1) 779 CH06 (Arg0, 0x19, 0x2F) 780 /* ToHexString */ 781 782 ToHexString (M000 (), Local1) 783 CH06 (Arg0, 0x1B, 0x2F) 784 /* ToInteger */ 785 786 ToInteger (M000 (), Local1) 787 CH06 (Arg0, 0x1D, 0x2F) 788 /* Acquire */ 789 790 Local1 = Acquire (M000 (), 0x0064) 791 CH06 (Arg0, 0x1E, 0x2F) 792 /* Add */ 793 794 Local1 = (M000 () + I000) /* \M4BB.M004.I000 */ 795 CH06 (Arg0, 0x21, 0x2F) 796 Local1 = (I000 + M000 ()) 797 CH06 (Arg0, 0x22, 0x2F) 798 /* And */ 799 800 Local1 = (M000 () & I000) /* \M4BB.M004.I000 */ 801 CH06 (Arg0, 0x25, 0x2F) 802 Local1 = (I000 & M000 ()) 803 CH06 (Arg0, 0x26, 0x2F) 804 /* Concatenate */ 805 806 Concatenate (M000 (), I000, Local1) 807 CH06 (Arg0, 0x29, 0x2F) 808 Concatenate (I000, M000 (), Local1) 809 CH06 (Arg0, 0x2A, 0x2F) 810 /* ConcatenateResTemplate */ 811 812 ConcatenateResTemplate (M000 (), Buffer (0x02) 813 { 814 0x79, 0x00 // y. 815 }, Local1) 816 CH06 (Arg0, 0x2D, 0x2F) 817 ConcatenateResTemplate (Buffer (0x02) 818 { 819 0x79, 0x00 // y. 820 }, M000 (), Local1) 821 CH06 (Arg0, 0x2E, 0x2F) 822 /* Divide */ 823 824 Divide (M000 (), I000, Local2) 825 CH06 (Arg0, 0x31, 0x2F) 826 Divide (I000, M000 (), Local2) 827 CH06 (Arg0, 0x32, 0x2F) 828 Divide (M000 (), I000, Local2, Local1) 829 CH06 (Arg0, 0x33, 0x2F) 830 Divide (I000, M000 (), Local2, Local1) 831 CH06 (Arg0, 0x34, 0x2F) 832 /* Fatal */ 833 834 Fatal (0xFF, 0xFFFFFFFF, M000 ()) 835 CH06 (Arg0, 0x35, 0x2F) 836 /* Index */ 837 838 Local1 = M000 () [0x00] 839 CH06 (Arg0, 0x38, 0x2F) 840 Index ("0", M000 (), Local1) 841 CH06 (Arg0, 0x39, 0x2F) 842 /* LEqual */ 843 844 Local1 = (M000 () == I000) 845 CH06 (Arg0, 0x3A, 0x2F) 846 Local1 = (I000 == M000 ()) 847 CH06 (Arg0, 0x3B, 0x2F) 848 /* LGreater */ 849 850 Local1 = (M000 () > I000) 851 CH06 (Arg0, 0x3C, 0x2F) 852 Local1 = (I000 > M000 ()) 853 CH06 (Arg0, 0x3D, 0x2F) 854 /* LGreaterEqual */ 855 856 Local1 = (M000 () >= I000) 857 CH06 (Arg0, 0x3E, 0xFF) 858 Local1 = (I000 >= M000 ()) 859 CH06 (Arg0, 0x3F, 0xFF) 860 /* LLess */ 861 862 Local1 = (M000 () < I000) 863 CH06 (Arg0, 0x40, 0x2F) 864 Local1 = (I000 < M000 ()) 865 CH06 (Arg0, 0x41, 0x2F) 866 /* LLessEqual */ 867 868 Local1 = (M000 () <= I000) 869 CH06 (Arg0, 0x42, 0xFF) 870 Local1 = (I000 <= M000 ()) 871 CH06 (Arg0, 0x43, 0xFF) 872 /* LNotEqual */ 873 874 Local1 = (M000 () != I000) 875 CH06 (Arg0, 0x44, 0xFF) 876 Local1 = (I000 != M000 ()) 877 CH06 (Arg0, 0x45, 0xFF) 878 /* LOr */ 879 880 Local1 = (M000 () || I000) 881 CH06 (Arg0, 0x46, 0x2F) 882 Local1 = (I000 || M000 ()) 883 CH06 (Arg0, 0x47, 0x2F) 884 /* Mod */ 885 886 Local1 = (M000 () % I000) /* \M4BB.M004.I000 */ 887 CH06 (Arg0, 0x4A, 0x2F) 888 Local1 = (I000 % M000 ()) 889 CH06 (Arg0, 0x4B, 0x2F) 890 /* Multiply */ 891 892 Local1 = (M000 () * I000) /* \M4BB.M004.I000 */ 893 CH06 (Arg0, 0x4E, 0x2F) 894 Local1 = (I000 * M000 ()) 895 CH06 (Arg0, 0x4F, 0x2F) 896 /* NAnd */ 897 898 NAnd (M000 (), I000, Local1) 899 CH06 (Arg0, 0x52, 0x2F) 900 NAnd (I000, M000 (), Local1) 901 CH06 (Arg0, 0x53, 0x2F) 902 /* NOr */ 903 904 NOr (M000 (), I000, Local1) 905 CH06 (Arg0, 0x56, 0x2F) 906 NOr (I000, M000 (), Local1) 907 CH06 (Arg0, 0x57, 0x2F) 908 /* Or */ 909 910 Local1 = (M000 () | I000) /* \M4BB.M004.I000 */ 911 CH06 (Arg0, 0x5A, 0x2F) 912 Local1 = (I000 | M000 ()) 913 CH06 (Arg0, 0x5B, 0x2F) 914 /* ShiftLeft */ 915 916 Local1 = (M000 () << I000) /* \M4BB.M004.I000 */ 917 CH06 (Arg0, 0x5E, 0x2F) 918 Local1 = (I000 << M000 ()) 919 CH06 (Arg0, 0x5F, 0x2F) 920 /* ShiftRight */ 921 922 Local1 = (M000 () >> I000) /* \M4BB.M004.I000 */ 923 CH06 (Arg0, 0x62, 0x2F) 924 Local1 = (I000 >> M000 ()) 925 CH06 (Arg0, 0x63, 0x2F) 926 /* Subtract */ 927 928 Local1 = (M000 () - I000) /* \M4BB.M004.I000 */ 929 CH06 (Arg0, 0x66, 0x2F) 930 Local1 = (I000 - M000 ()) 931 CH06 (Arg0, 0x67, 0x2F) 932 /* ToString */ 933 934 ToString (M000 (), 0x01, Local1) 935 CH06 (Arg0, 0x6A, 0x2F) 936 ToString (I000, M000 (), Local1) 937 CH06 (Arg0, 0x6B, 0x2F) 938 /* Wait */ 939 940 Local1 = Wait (M000 (), I000) 941 CH06 (Arg0, 0x6C, 0x2F) 942 Local1 = Wait (E000, M000 ()) 943 CH06 (Arg0, 0x6D, 0x2F) 944 /* XOr */ 945 946 Local1 = (M000 () ^ I000) /* \M4BB.M004.I000 */ 947 CH06 (Arg0, 0x70, 0x2F) 948 Local1 = (I000 ^ M000 ()) 949 CH06 (Arg0, 0x71, 0x2F) 950 /* Mid */ 951 952 Mid (M000 (), 0x01, 0x01, Local1) 953 CH06 (Arg0, 0x75, 0x2F) 954 Mid ("123", M000 (), 0x01, Local1) 955 CH06 (Arg0, 0x76, 0x2F) 956 Mid ("123", 0x01, M000 (), Local1) 957 CH06 (Arg0, 0x77, 0x2F) 958 /* Match */ 959 960 Local1 = Match (M000 (), MTR, 0x00, MTR, 0x00, 0x00) 961 CH06 (Arg0, 0x78, 0x2F) 962 Local1 = Match (Package (0x01) 963 { 964 0x01 965 }, MTR, M000 (), MTR, 0x00, 0x00) 966 CH06 (Arg0, 0x79, 0x2F) 967 Local1 = Match (Package (0x01) 968 { 969 0x01 970 }, MTR, 0x00, MTR, M000 (), 0x00) 971 CH06 (Arg0, 0x7A, 0x2F) 972 Local1 = Match (Package (0x01) 973 { 974 0x01 975 }, MTR, 0x00, MTR, 0x00, M000 ()) 976 CH06 (Arg0, 0x7B, 0x2F) 977 } 978 979 /* Reference to Object as Result of Method invocation */ 980 981 Method (M005, 1, Serialized) 982 { 983 PowerResource (PW02, 0x01, 0x0000) 984 { 985 Method (M000, 0, NotSerialized) 986 { 987 Return (0x00) 988 } 989 } 990 991 Name (I000, 0x00) /* Label to check m000 invocations */ 992 Method (M000, 2, NotSerialized) 993 { 994 I000 = Arg0 995 If ((Arg1 == 0x00)) 996 { 997 Local0 = RefOf (PW00) 998 } 999 ElseIf ((Arg1 == 0x01)) 1000 { 1001 Local0 = RefOf (PW02) 1002 } 1003 1004 Return (Local0) 1005 } 1006 1007 Method (CH00, 2, NotSerialized) 1008 { 1009 If ((I000 != Arg1)) 1010 { 1011 ERR (Arg0, Z103, __LINE__, 0x00, 0x00, I000, Arg1) 1012 } 1013 } 1014 1015 Name (LPN0, 0x02) 1016 Name (LPC0, 0x00) 1017 While (LPN0) 1018 { 1019 Local0 = (0x03 * LPC0) /* \M4BB.M005.LPC0 */ 1020 I000 = 0x00 1021 Local1 = DerefOf (M000 (0x01, LPC0)) 1022 If (!SLCK) 1023 { 1024 CH04 (__METHOD__, 0x00, 0x2F, Z103, __LINE__, 0x00, 0x00) 1025 } 1026 1027 CH00 (Arg0, 0x01) 1028 Local1 = DerefOf (DerefOf (M000 (0x02, LPC0))) 1029 If (!SLCK) 1030 { 1031 CH06 (Arg0, (0x01 + Local0), 0x2F) 1032 } 1033 1034 CH00 (Arg0, 0x02) 1035 Store (DerefOf (M000 (0x03, LPC0)) [0x00], Local1) 1036 CH06 (Arg0, (0x02 + Local0), 0x2F) 1037 CH00 (Arg0, 0x03) 1038 Local1 = Match (DerefOf (M000 (0x04, LPC0)), MTR, 0x00, MTR, 0x00, 0x00) 1039 CH06 (Arg0, (0x03 + Local0), 0x2F) 1040 CH00 (Arg0, 0x04) 1041 LPN0-- 1042 LPC0++ 1043 } 1044 } 1045 1046 SET0 (Z103, __METHOD__, 0x00) 1047 CH03 (__METHOD__, Z103, __LINE__, 0x00, 0x00) 1048 /* Local Named Object */ 1049 1050 M000 (__METHOD__) 1051 /* Global Named Object */ 1052 1053 M001 (__METHOD__) 1054 /* Local */ 1055 1056 M002 (Concatenate (__METHOD__, "-m002")) 1057 /* Reference to Local Named Object */ 1058 1059 M003 (Concatenate (__METHOD__, "-m003-RefLocName"), RefOf (PW01)) 1060 Local0 = RefOf (PW01) 1061 M003 (Concatenate (__METHOD__, "-m003-RefLocName2"), Local0) 1062 CondRefOf (PW01, Local0) 1063 M003 (Concatenate (__METHOD__, "-m003-CondRefLocName"), Local0) 1064 M003 (Concatenate (__METHOD__, "-m003-RefGlobName"), RefOf (PW00)) 1065 Local0 = RefOf (PW00) 1066 M003 (Concatenate (__METHOD__, "-m003-RefGlobName2"), Local0) 1067 CondRefOf (PW00, Local0) 1068 M003 (Concatenate (__METHOD__, "-m003-CondRefGlobName"), Local0) 1069 /* Reference to Object as element of Package */ 1070 1071 Name (PP00, Package (0x01) 1072 { 1073 PW00 1074 }) 1075 If (Y113) 1076 { 1077 M003 (Concatenate (__METHOD__, "-m003-Index"), PP00 [0x00]) 1078 } 1079 1080 Store (PP00 [0x00], Local1) 1081 M003 (Concatenate (__METHOD__, "-m003-Index2"), Local1) 1082 If (Y113) 1083 { 1084 M003 (Concatenate (__METHOD__, "-m003-Index3"), Local2 = PP00 [0x00]) 1085 } 1086 1087 Local3 = PP00 [0x00] 1088 M003 (Concatenate (__METHOD__, "-m003-Index4"), Local3) 1089 Local5 = Local4 = PP00 [0x00] 1090 M003 (Concatenate (__METHOD__, "-m003-Index5"), Local5) 1091 /* Result of Method invocation */ 1092 1093 M004 (Concatenate (__METHOD__, "-m004")) 1094 /* Reference to Object as Result of Method invocation */ 1095 1096 M005 (Concatenate (__METHOD__, "-m005")) 1097 RST0 () 1098 } 1099