Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: aiboost panics my kernel



On Wed, 16 Apr 2008, Paul Goyette wrote:

Erm right. Just change it to ACPI_TYPE_LOCAL_REFERENCE as Jared
pointed out.

Well, in hopes of narrowing this down a bit further, I defined symbol AIBOOST_DEBUG and modified the DPRINTF to tell me what the actual value of elem->Type was; somehow, printing what it is NOT didn't seem to be very helpful. :)

Anyway, it turns out that the elem->Type has value 0x04, which equates to ACPI_TYPE_PACKAGE. It's definitely neither ACPI_TYPE_ANY (0x00) nor ACPI_TYPE_LOCAL_REFERENCE (0x14).

I've attached the output from ``acpidump -r'' in case it helps narrow this down.

----------------------------------------------------------------------
|   Paul Goyette   | PGP DSS Key fingerprint: |  E-mail addresses:   |
| Customer Service | FA29 0E3B 35AF E8AE 6651 |  paul%whooppee.com@localhost   |
| Network Engineer | 0786 F758 55DE 53BA 7731 | pgoyette%juniper.net@localhost |
----------------------------------------------------------------------
/*
RSD PTR: Checksum=103, OEMID=Nvidia, RsdtAddress=0xbfee3040
 */
/*
RSDT: Length=52, Revision=1, Checksum=237,
        OEMID=Nvidia, OEM Table ID=ASUSACPI, OEM Revision=0x42302e31,
        Creator ID=AWRD, Creator Revision=0x0
 */
/*
        Entries={ 0xbfee31c0, 0xbfeeae40, 0xbfeeaec0, 0xbfeead40 }
 */
/*
        DSDT=0xbfee3280
        INT_MODEL=APIC
        SCI_INT=9
        SMI_CMD=0x142e, ACPI_ENABLE=0xa1, ACPI_DISABLE=0xa0, S4BIOS_REQ=0x0
        PM1a_EVT_BLK=0x1000-0x1003
        PM1a_CNT_BLK=0x1004-0x1005
        PM2_CNT_BLK=0x101c-0x101c
        PM2_TMR_BLK=0x1008-0x100b
        PM2_GPE0_BLK=0x1020-0x1027
        PM2_GPE1_BLK=0x14a0-0x14af, GPE1_BASE=32
        P_LVL2_LAT=101ms, P_LVL3_LAT=1001ms
        FLUSH_SIZE=0, FLUSH_STRIDE=0
        DUTY_OFFSET=1, DUTY_WIDTH=3
        DAY_ALRM=125, MON_ALRM=126, CENTURY=50
        Flags={WBINVD,PROC_C1,SLP_BUTTON,RTC_S4}
 */
/*
DSDT: Length=30984, Revision=1, Checksum=243,
        OEMID=NVIDIA, OEM Table ID=AWRDACPI, OEM Revision=0x1000,
        Creator ID=MSFT, Creator Revision=0x3000000
 */
DefinitionBlock ("acpi_dst.aml", "DSDT", 0x1, "NVIDIA", "AWRDACPI", 0x1000)
{
Scope(\_PR) {
    Processor(\_PR.C000, 0, 0x0, 0x0) {
    }
    Processor(\_PR.C001, 1, 0x0, 0x0) {
    }
    Processor(\_PR.C002, 2, 0x0, 0x0) {
    }
    Processor(\_PR.C003, 3, 0x0, 0x0) {
    }
}
Name(\_S0, Package(0x04) {
    0x00,
    0x00,
    0x00,
    0x00,
})
Name(\_S1, Package(0x04) {
    0x01,
    0x00,
    0x00,
    0x00,
})
Name(\_S3, Package(0x04) {
    0x05,
    0x00,
    0x00,
    0x00,
})
Name(\_S4, Package(0x04) {
    0x06,
    0x00,
    0x00,
    0x00,
})
Name(\_S5, Package(0x04) {
    0x07,
    0x00,
    0x00,
    0x00,
})
OperationRegion(\DEBG, SystemIO, 0x80, 0x01)
Field(\DEBG, ByteAcc, NoLock, Preserve) {
    DBG1,       8
}
OperationRegion(KBC, SystemIO, 0x64, 0x01)
Field(KBC, ByteAcc, NoLock, Preserve) {
    KCMD,       8
}
OperationRegion(KBCD, SystemIO, 0x60, 0x01)
Field(KBCD, ByteAcc, NoLock, Preserve) {
    KDAT,       8
}
OperationRegion(EXTM, SystemMemory, 0x000ff830, 0x10)
Field(EXTM, WordAcc, NoLock, Preserve) {
    ROM1,       16,
    RMS1,       16,
    ROM2,       16,
    RMS2,       16,
    ROM3,       16,
    RMS3,       16,
    AMEM,       32
}
OperationRegion(\PM1S, SystemIO, 0x1000, 0x02)
Field(\PM1S, ByteAcc, NoLock, Preserve) {
    Offset(0x1),
    PBTS,       1,
    ,   1,
    RTCS,       1,
    ,   4,
    WAKS,       1
}
OperationRegion(\APA4, SystemIO, 0x10a4, 0x04)
Field(\APA4, ByteAcc, NoLock, Preserve) {
    Offset(0x2),
    LCTM,       1,
    LCNM,       1
}
OperationRegion(ELCR, SystemIO, 0x04d0, 0x02)
Field(ELCR, ByteAcc, NoLock, Preserve) {
    ELC1,       8,
    ELC2,       8
}
OperationRegion(\STUS, SystemIO, 0x1400, 0x04)
Field(\STUS, ByteAcc, NoLock, Preserve) {
    G_ST,       32
}
OperationRegion(\GPS0, SystemIO, 0x1020, 0x04)
Field(\GPS0, ByteAcc, NoLock, Preserve) {
    GS00,       8,
    GS01,       8,
    GS02,       8,
    GS03,       8
}
OperationRegion(\SMIC, SystemIO, 0x142e, 0x01)
Field(\SMIC, ByteAcc, NoLock, Preserve) {
    SCP,        8
}
OperationRegion(\GP1, SystemIO, 0x14c0, 0x32)
Field(\GP1, ByteAcc, NoLock, Preserve) {
    GP00,       8,
    GP01,       8,
    GP02,       8,
    GP03,       8,
    GP04,       8,
    GP05,       8,
    GP06,       8,
    GP07,       8,
    GP08,       8,
    GP09,       8,
    GP10,       8,
    GP11,       8,
    GP12,       8,
    GP13,       8,
    GP14,       8,
    GP15,       8,
    GP16,       8,
    GP17,       8,
    GP18,       8,
    GP19,       8,
    GP20,       8,
    GP21,       8,
    GP22,       8,
    Offset(0x18),
    GP24,       8,
    GP25,       8,
    GP26,       8,
    GP27,       8,
    GP28,       8,
    GP29,       8,
    GP30,       8,
    GP31,       8,
    GP32,       8,
    GP33,       8,
    GP34,       8,
    GP35,       8,
    GP36,       8,
    GP37,       8,
    GP38,       8,
    GP39,       8,
    GP40,       8,
    GP41,       8,
    GP42,       8,
    GP43,       8,
    GP44,       8,
    GP45,       8,
    GP46,       8,
    GP47,       8,
    GP48,       8,
    GP49,       8
}
Name(VSTA, 0x01)
Name(OSFX, 0x01)
Name(OSFL, 0x01)
Method(STRC, 2) {
    If(LNot(LEqual(SizeOf(Arg0), SizeOf(Arg1)))) {
        Return(0x00)
    }
    Add(SizeOf(Arg0), 0x01, Local0)
    Name(BUF0, Buffer(Local0) { })
    Name(BUF1, Buffer(Local0) { })
    Store(Arg0, BUF0)
    Store(Arg1, BUF1)
    While(Local0) {
        Decrement(Local0)
        If(LNot(LEqual(DerefOf(Index(BUF0, Local0, )), DerefOf(Index(BUF1, 
Local0, ))))) {
            Return(Zero)
        }
    }
    Return(One)
}
OperationRegion(RTCM, SystemIO, 0x70, 0x02)
Field(RTCM, ByteAcc, NoLock, Preserve) {
    CMIN,       8,
    CMDA,       8
}
IndexField(CMIN, CMDA, ByteAcc, NoLock, Preserve) {
    Offset(0xf),
    SHUT,       8
}
OperationRegion(INFO, SystemMemory, 0x000ff840, 0x01)
Field(INFO, ByteAcc, NoLock, Preserve) {
    KBDI,       1,
    RTCW,       1,
    PS2F,       1,
    IRFL,       2,
    DISE,       1,
    SSHU,       1
}
OperationRegion(BEEP, SystemIO, 0x61, 0x01)
Field(BEEP, ByteAcc, NoLock, Preserve) {
    S1B,        8
}
OperationRegion(CONT, SystemIO, 0x40, 0x04)
Field(CONT, ByteAcc, NoLock, Preserve) {
    CNT0,       8,
    CNT1,       8,
    CNT2,       8,
    CTRL,       8
}
Method(SPKR, 1) {
    Store(S1B, Local0)
    Store(0xb6, CTRL)
    Store(0x55, CNT2)
    Store(0x03, CNT2)
    Store(Arg0, Local2)
    While(LGreater(Local2, 0x00)) {
        Or(S1B, 0x03, S1B)
        Store(0x5fff, Local3)
        While(LGreater(Local3, 0x00)) {
            Decrement(Local3)
        }
        And(S1B, 0xfc, S1B)
        Store(0x0eff, Local3)
        While(LGreater(Local3, 0x00)) {
            Decrement(Local3)
        }
        Decrement(Local2)
    }
    Store(Local0, S1B)
}
OperationRegion(AMDL, SystemMemory, 0x000fffea, 0x01)
Field(AMDL, ByteAcc, NoLock, Preserve) {
    ,   1,
    AWEN,       1,
    ,   1,
    ,   1,
    ,   1,
    ,   1,
    ,   1,
    Offset(0x1)
}
Scope(\_SB) {
    Device(AWY) {
        Name(_HID, "AWY0001")
        Method(SMOD, 1) {
        }
        Method(_STA) {
            If(LEqual(AWEN, 0x00)) {
                Return(0x00)
            }
            Return(0x0f)
        }
    }
}
Scope(\) {
    Name(PICF, 0x00)
    Method(_PIC, 1) {
        Store(Arg0, PICF)
    }
}
Name(SID4, 0x00)
Name(SLG0, 0x00)
Name(SLG1, 0x00)
Name(SLG2, 0x00)
Name(SLG3, 0x00)
Name(SLG4, 0x00)
Name(SLG5, 0x00)
Name(SLG6, 0x00)
Name(SLG7, 0x00)
Name(SLG8, 0x00)
Name(SLG9, 0x00)
Name(SLGA, 0x00)
Name(SID5, 0x00)
Name(SSM0, 0x00)
Name(SSM1, 0x00)
Name(SSM2, 0x00)
Name(SSM3, 0x00)
Name(SSM4, 0x00)
Name(SUA0, 0x00)
Name(SUB0, 0x00)
Name(SX, 0x00)
Name(SFLG, 0x00)
Name(SID0, 0x00)
Name(SID1, 0x00)
Name(SID2, 0x00)
Name(SID3, 0x00)
Method(\_PTS, 1) {
    Store(Arg0, Local0)
    Store(Local0, SX)
    Or(Arg0, 0xf0, Local0)
    Store(Local0, DBG1)
    OSTP()
    Store(\_SB.PCI0.IDE0.ID20, SID0)
    Store(\_SB.PCI0.IDE0.IDTS, SID1)
    Store(\_SB.PCI0.IDE0.IDTP, SID2)
    Store(\_SB.PCI0.IDE0.ID22, SID3)
    Store(\_SB.PCI0.IDE0.UMSS, SID4)
    Store(\_SB.PCI0.IDE0.UMSP, SID5)
    If(LEqual(Arg0, 0x01)) {
    }
    If(LEqual(Arg0, 0x03)) {
        Store(0x00, LCTM)
        Store(0x00, LCNM)
    }
    If(LEqual(Arg0, 0x04)) {
    }
    If(LEqual(Arg0, 0x05)) {
        If(LNot(LEqual(OSFL, 0x00))) {
            Sleep(0x01f4)
        }
    }
}
Method(\_WAK, 1) {
    Store(0xff, DBG1)
    Store(0x00, SFLG)
    If(LEqual(RTCW, 0x00)) {
        Notify(\_SB.PWRB, 0x02)
    }
    Notify(\_SB.PCI0.USB0, 0x00)
    If(LNot(LLess(OSFL, 0x01))) {
        Store(0x00, \_SB.PCI0.SMB0.SMPM)
    }
}
Scope(\_SI) {
    Method(_MSG, 1) {
        Store("\x3d\x3d\x3d\x3d\x20MSG\x20Working\x20\x3d\x3d\x3d\x3d", Debug)
    }
    Method(_SST, 1) {
        Store("\x3d\x3d\x3d\x3d\x20SST\x20Working\x20\x3d\x3d\x3d\x3d", Debug)
    }
}
Scope(\_GPE) {
    Method(_L11) {
        Store(0x02, GS02)
        If(LNot(LEqual(PEV0, 0xffff))) {
            If(PES0) {
                While(PES0) {
                    Store(0x01, PES0)
                }
                Notify(\_SB.PCI0.XVR0, 0x02)
            }
        }
        If(LNot(LEqual(PEV1, 0xffff))) {
            If(PES1) {
                While(PES1) {
                    Store(0x01, PES1)
                }
                Notify(\_SB.PCI0.XVR1, 0x02)
            }
        }
        If(LNot(LEqual(PEV2, 0xffff))) {
            If(PES2) {
                While(PES2) {
                    Store(0x01, PES2)
                }
                Notify(\_SB.PCI0.XVR2, 0x02)
            }
        }
        If(LNot(LEqual(PEV3, 0xffff))) {
            If(PES3) {
                While(PES3) {
                    Store(0x01, PES3)
                }
                Notify(\_SB.PCI0.XVR3, 0x02)
            }
        }
        If(LNot(LEqual(PEV4, 0xffff))) {
            If(PES4) {
                While(PES4) {
                    Store(0x01, PES4)
                }
                Notify(\_SB.PCI0.XVR4, 0x02)
            }
        }
        If(LNot(LEqual(PEV5, 0xffff))) {
            If(PES5) {
                While(PES5) {
                    Store(0x01, PES5)
                }
                Notify(\_SB.PCI0.XVR5, 0x02)
            }
        }
    }
    Method(_L00) {
        Notify(\_SB.PCI0.HUB0, 0x02)
    }
    Method(_L03) {
        Notify(\_SB.PCI0.LEG0.UAR1, 0x02)
    }
    Method(_L0B) {
        Notify(\_SB.PCI0.MMAC, 0x02)
    }
    Method(_L0D) {
        Notify(\_SB.PCI0.USB0, 0x02)
    }
    Method(_L05) {
        Notify(\_SB.PCI0.USB2, 0x02)
    }
    Method(_L10) {
        \_SB.PCI0.LEG0.PS2W()
    }
    Method(_L15) {
        Notify(\_SB.PCI0.AZAD, 0x02)
    }
    Method(_L31) {
        Notify(\_SB.PCI0.ASOC, 0x01)
    }
}
Scope(\_SB) {
    OperationRegion(\CTCR, SystemIO, 0x1010, 0x04)
    Field(\CTCR, DWordAcc, NoLock, Preserve) {
        CTCR,   32
    }
    Method(SCTC, 1) {
        If(LEqual(Arg0, 0x00)) {
            And(CTCR, 0xffffffef, CTCR)
        }
        Else {
            Store(Arg0, Local0)
            If(LNot(LGreater(Local0, 0x07))) {
                If(LNot(LLess(Local0, 0x01))) {
                    And(CTCR, 0xfffffff1, CTCR)
                    Decrement(Local0)
                    Not(Local0, Local0)
                    And(Local0, 0x07, Local0)
                    Or(Local0, 0x08, Local0)
                    ShiftLeft(Local0, 0x01, Local0)
                    Or(CTCR, Local0, CTCR)
                }
            }
        }
    }
    Device(PWRB) {
        Name(_HID, 0x0c0cd041)
        Method(_STA) {
            Return(0x0b)
        }
    }
    Device(PCI0) {
        Name(_HID, 0x080ad041)
        Name(_CID, 0x030ad041)
        Name(_ADR, 0x00)
        Name(_UID, 0x01)
        Name(_BBN, 0x00)
        Name(PCIA, 0x00)
        Method(_REG, 2) {
            If(LEqual(Arg0, 0x02)) {
                Store(Arg1, PCIA)
            }
        }
        Device(MBIO) {
            Name(_HID, 0x020cd041)
            Name(_UID, 0x05)
            Method(_CRS) {
                Name(BUF0, Buffer(0x32) {0x47, 0x1, 0x0, 0x10, 0x0, 0x10, 0x1, 
0x80, 0x47, 0x1, 0x80, 0x10, 0x80, 0x10, 0x1, 0x80, 0x47, 0x1, 0x0, 0x14, 0x0, 
0x14, 0x1, 0x80, 0x47, 0x1, 0x80, 0x14, 0x80, 0x14, 0x1, 0x80, 0x47, 0x1, 0x0, 
0x18, 0x0, 0x18, 0x1, 0x80, 0x47, 0x1, 0x80, 0x18, 0x80, 0x18, 0x1, 0x80, 0x79, 
0x0
                /* ResourceTemplate() {
                 0x0000  IO(Decode16, 0x1000, 0x1000, 0x1, 0x80)
                 0x0008  IO(Decode16, 0x1080, 0x1080, 0x1, 0x80)
                 0x0010  IO(Decode16, 0x1400, 0x1400, 0x1, 0x80)
                 0x0018  IO(Decode16, 0x1480, 0x1480, 0x1, 0x80)
                 0x0020  IO(Decode16, 0x1800, 0x1800, 0x1, 0x80)
                 0x0028  IO(Decode16, 0x1880, 0x1880, 0x1, 0x80)
                } */
                 })
                Return(BUF0)
            }
        }
        Name(NATA, Package(0x01) {
            0x00040000,
        })
        Method(_S3D) {
            If(LEqual(OSFL, 0x02)) {
                Return(0x02)
            }
            Else {
                Return(0x03)
            }
        }
        Method(_STA) {
            Return(0x0f)
        }
        OperationRegion(LDT3, PCI_Config, 0x6c, 0x04)
        Field(LDT3, DWordAcc, NoLock, Preserve) {
            UCFG,       32
        }
        Method(_CRS) {
            Name(BUF0, Buffer(0x88) {0x88, 0xd, 0x0, 0x2, 0x1, 0x0, 0x0, 0x0, 
0x0, 0x0, 0xff, 0x0, 0x0, 0x0, 0x0, 0x1, 0x47, 0x1, 0xf8, 0xc, 0xf8, 0xc, 0x1, 
0x8, 0x88, 0xd, 0x0, 0x1, 0xc, 0x3, 0x0, 0x0, 0x0, 0x0, 0xf7, 0xc, 0x0, 0x0, 
0xf8, 0xc, 0x88, 0xd, 0x0, 0x1, 0xc, 0x3, 0x0, 0x0, 0x0, 0xd, 0xff, 0xff, 0x0, 
0x0, 0x0, 0xf3, 0x87, 0x17, 0x0, 0x0, 0xc, 0x3, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 
0xa, 0x0, 0xff, 0xff, 0xb, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x2, 0x0, 0x87, 
0x17, 0x0, 0x0, 0xc, 0x3, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc, 0x0, 0xff, 0xff, 
0xd, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x2, 0x0, 0x87, 0x17, 0x0, 0x0, 0xc, 
0x3, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x10, 0x0, 0xff, 0xff, 0xbf, 0xfe, 0x0, 0x0, 
0x0, 0x0, 0x0, 0x0, 0xf0, 0xff, 0x79, 0x0
            /* ResourceTemplate() {
             0x0000  WordBus(ResourceConsumer, PosDecode, MinNotFixed, 
MaxNotFixed, 0x0, 0x0, 0xff, 0x0, 0x100, 71, 'øøˆ
')
             0x0010  IO(Decode16, 0xcf8, 0xcf8, 0x1, 0x8)
             0x0018  WordIO(ResourceProducer, MinFixed, MaxFixed, PosDecode, 
EntireRange, 0x0, 0x0, 0xcf7, 0x0, 0xcf8, 136, '
', TypeStatic, DenseTranslation)
             0x0028  WordIO(ResourceProducer, MinFixed, MaxFixed, PosDecode, 
EntireRange, 0x0, 0xd00, 0xffff, 0x0, 0xf300, 135, '', TypeStatic, 
DenseTranslation)
             0x0038  DWordMemory(ResourceProducer, PosDecode, MinFixed, 
MaxFixed, Cacheable, ReadWrite, 0x0, 0xa0000, 0xbffff, 0x0, 0x20000, 135, '', 
AddressRangeMemory, TypeStatic)
             0x0052  DWordMemory(ResourceProducer, PosDecode, MinFixed, 
MaxFixed, Cacheable, ReadWrite, 0x0, 0xc0000, 0xdffff, 0x0, 0x20000, 135, '', 
AddressRangeMemory, TypeStatic)
             0x006c  DWordMemory(ResourceProducer, PosDecode, MinFixed, 
MaxFixed, Cacheable, ReadWrite, 0x0, 0x100000, 0xfebfffff, 0x0, 0xfff00000, 
121, '', AddressRangeMemory, TypeStatic)
            } */
             })
            CreateDWordField(BUF0, 0x76, TCMM)
            CreateDWordField(BUF0, 0x82, TOMM)
            Add(AMEM, 0x00010000, TCMM)
            Add(TCMM, 0x00010000, TCMM)
            Subtract(0xfec00000, TCMM, TOMM)
            Return(BUF0)
        }
        Name(PICM, Package(0x23) {
            Package(0x04) {
                0x0001ffff,
                0x00,
                \_SB.PCI0.LSMB,
                0x00,
            },
            Package(0x04) {
                0x0001ffff,
                0x01,
                \_SB.PCI0.LPMU,
                0x00,
            },
            Package(0x04) {
                0x0002ffff,
                0x00,
                \_SB.PCI0.LUBA,
                0x00,
            },
            Package(0x04) {
                0x0002ffff,
                0x01,
                \_SB.PCI0.LUB2,
                0x00,
            },
            Package(0x04) {
                0x0008ffff,
                0x00,
                \_SB.PCI0.LMAC,
                0x00,
            },
            Package(0x04) {
                0x0006ffff,
                0x00,
                \_SB.PCI0.LP2P,
                0x00,
            },
            Package(0x04) {
                0x0006ffff,
                0x01,
                \_SB.PCI0.LAZA,
                0x00,
            },
            Package(0x04) {
                0x0004ffff,
                0x00,
                \_SB.PCI0.LIDE,
                0x00,
            },
            Package(0x04) {
                0x0005ffff,
                0x00,
                \_SB.PCI0.LSID,
                0x00,
            },
            Package(0x04) {
                0x0005ffff,
                0x01,
                \_SB.PCI0.LFID,
                0x00,
            },
            Package(0x04) {
                0x0005ffff,
                0x02,
                \_SB.PCI0.LSA2,
                0x00,
            },
            Package(0x04) {
                0x000fffff,
                0x00,
                \_SB.PCI0.LNK6,
                0x00,
            },
            Package(0x04) {
                0x000fffff,
                0x01,
                \_SB.PCI0.LNK7,
                0x00,
            },
            Package(0x04) {
                0x000fffff,
                0x02,
                \_SB.PCI0.LNK8,
                0x00,
            },
            Package(0x04) {
                0x000fffff,
                0x03,
                \_SB.PCI0.LNK5,
                0x00,
            },
            Package(0x04) {
                0x000effff,
                0x00,
                \_SB.PCI0.LNK7,
                0x00,
            },
            Package(0x04) {
                0x000effff,
                0x01,
                \_SB.PCI0.LNK8,
                0x00,
            },
            Package(0x04) {
                0x000effff,
                0x02,
                \_SB.PCI0.LNK5,
                0x00,
            },
            Package(0x04) {
                0x000effff,
                0x03,
                \_SB.PCI0.LNK6,
                0x00,
            },
            Package(0x04) {
                0x000dffff,
                0x00,
                \_SB.PCI0.LNK8,
                0x00,
            },
            Package(0x04) {
                0x000dffff,
                0x01,
                \_SB.PCI0.LNK5,
                0x00,
            },
            Package(0x04) {
                0x000dffff,
                0x02,
                \_SB.PCI0.LNK6,
                0x00,
            },
            Package(0x04) {
                0x000dffff,
                0x03,
                \_SB.PCI0.LNK7,
                0x00,
            },
            Package(0x04) {
                0x000cffff,
                0x00,
                \_SB.PCI0.LNK5,
                0x00,
            },
            Package(0x04) {
                0x000cffff,
                0x01,
                \_SB.PCI0.LNK6,
                0x00,
            },
            Package(0x04) {
                0x000cffff,
                0x02,
                \_SB.PCI0.LNK7,
                0x00,
            },
            Package(0x04) {
                0x000cffff,
                0x03,
                \_SB.PCI0.LNK8,
                0x00,
            },
            Package(0x04) {
                0x000bffff,
                0x00,
                \_SB.PCI0.LNK6,
                0x00,
            },
            Package(0x04) {
                0x000bffff,
                0x01,
                \_SB.PCI0.LNK7,
                0x00,
            },
            Package(0x04) {
                0x000bffff,
                0x02,
                \_SB.PCI0.LNK8,
                0x00,
            },
            Package(0x04) {
                0x000bffff,
                0x03,
                \_SB.PCI0.LNK5,
                0x00,
            },
            Package(0x04) {
                0x000affff,
                0x00,
                \_SB.PCI0.LNK7,
                0x00,
            },
            Package(0x04) {
                0x000affff,
                0x01,
                \_SB.PCI0.LNK8,
                0x00,
            },
            Package(0x04) {
                0x000affff,
                0x02,
                \_SB.PCI0.LNK5,
                0x00,
            },
            Package(0x04) {
                0x000affff,
                0x03,
                \_SB.PCI0.LNK6,
                0x00,
            },
        })
        Name(APIC, Package(0x23) {
            Package(0x04) {
                0x0001ffff,
                0x00,
                \_SB.PCI0.APCS,
                0x00,
            },
            Package(0x04) {
                0x0001ffff,
                0x01,
                \_SB.PCI0.APMU,
                0x00,
            },
            Package(0x04) {
                0x0002ffff,
                0x00,
                \_SB.PCI0.APCF,
                0x00,
            },
            Package(0x04) {
                0x0002ffff,
                0x01,
                \_SB.PCI0.APCL,
                0x00,
            },
            Package(0x04) {
                0x0008ffff,
                0x00,
                \_SB.PCI0.APCH,
                0x00,
            },
            Package(0x04) {
                0x0006ffff,
                0x00,
                \_SB.PCI0.APCM,
                0x00,
            },
            Package(0x04) {
                0x0006ffff,
                0x01,
                \_SB.PCI0.AAZA,
                0x00,
            },
            Package(0x04) {
                0x0004ffff,
                0x00,
                \_SB.PCI0.APCZ,
                0x00,
            },
            Package(0x04) {
                0x0005ffff,
                0x00,
                \_SB.PCI0.APSI,
                0x00,
            },
            Package(0x04) {
                0x0005ffff,
                0x01,
                \_SB.PCI0.APSJ,
                0x00,
            },
            Package(0x04) {
                0x0005ffff,
                0x02,
                \_SB.PCI0.ASA2,
                0x00,
            },
            Package(0x04) {
                0x000fffff,
                0x00,
                \_SB.PCI0.APC6,
                0x00,
            },
            Package(0x04) {
                0x000fffff,
                0x01,
                \_SB.PCI0.APC7,
                0x00,
            },
            Package(0x04) {
                0x000fffff,
                0x02,
                \_SB.PCI0.APC8,
                0x00,
            },
            Package(0x04) {
                0x000fffff,
                0x03,
                \_SB.PCI0.APC5,
                0x00,
            },
            Package(0x04) {
                0x000effff,
                0x00,
                \_SB.PCI0.APC7,
                0x00,
            },
            Package(0x04) {
                0x000effff,
                0x01,
                \_SB.PCI0.APC8,
                0x00,
            },
            Package(0x04) {
                0x000effff,
                0x02,
                \_SB.PCI0.APC5,
                0x00,
            },
            Package(0x04) {
                0x000effff,
                0x03,
                \_SB.PCI0.APC6,
                0x00,
            },
            Package(0x04) {
                0x000dffff,
                0x00,
                \_SB.PCI0.APC8,
                0x00,
            },
            Package(0x04) {
                0x000dffff,
                0x01,
                \_SB.PCI0.APC5,
                0x00,
            },
            Package(0x04) {
                0x000dffff,
                0x02,
                \_SB.PCI0.APC6,
                0x00,
            },
            Package(0x04) {
                0x000dffff,
                0x03,
                \_SB.PCI0.APC7,
                0x00,
            },
            Package(0x04) {
                0x000cffff,
                0x00,
                \_SB.PCI0.APC5,
                0x00,
            },
            Package(0x04) {
                0x000cffff,
                0x01,
                \_SB.PCI0.APC6,
                0x00,
            },
            Package(0x04) {
                0x000cffff,
                0x02,
                \_SB.PCI0.APC7,
                0x00,
            },
            Package(0x04) {
                0x000cffff,
                0x03,
                \_SB.PCI0.APC8,
                0x00,
            },
            Package(0x04) {
                0x000bffff,
                0x00,
                \_SB.PCI0.APC6,
                0x00,
            },
            Package(0x04) {
                0x000bffff,
                0x01,
                \_SB.PCI0.APC7,
                0x00,
            },
            Package(0x04) {
                0x000bffff,
                0x02,
                \_SB.PCI0.APC8,
                0x00,
            },
            Package(0x04) {
                0x000bffff,
                0x03,
                \_SB.PCI0.APC5,
                0x00,
            },
            Package(0x04) {
                0x000affff,
                0x00,
                \_SB.PCI0.APC7,
                0x00,
            },
            Package(0x04) {
                0x000affff,
                0x01,
                \_SB.PCI0.APC8,
                0x00,
            },
            Package(0x04) {
                0x000affff,
                0x02,
                \_SB.PCI0.APC5,
                0x00,
            },
            Package(0x04) {
                0x000affff,
                0x03,
                \_SB.PCI0.APC6,
                0x00,
            },
        })
        Method(_PRT) {
            If(LNot(PICF)) {
                Return(PICM)
            }
            Else {
                Return(APIC)
            }
        }
        Device(HUB0) {
            Name(_ADR, 0x00060000)
            Method(_STA) {
                Return(0x0f)
            }
            Name(PICM, Package(0x10) {
                Package(0x04) {
                    0x0006ffff,
                    0x00,
                    \_SB.PCI0.LNK1,
                    0x00,
                },
                Package(0x04) {
                    0x0006ffff,
                    0x01,
                    \_SB.PCI0.LNK2,
                    0x00,
                },
                Package(0x04) {
                    0x0006ffff,
                    0x02,
                    \_SB.PCI0.LNK3,
                    0x00,
                },
                Package(0x04) {
                    0x0006ffff,
                    0x03,
                    \_SB.PCI0.LNK4,
                    0x00,
                },
                Package(0x04) {
                    0x0007ffff,
                    0x00,
                    \_SB.PCI0.LNK2,
                    0x00,
                },
                Package(0x04) {
                    0x0007ffff,
                    0x01,
                    \_SB.PCI0.LNK3,
                    0x00,
                },
                Package(0x04) {
                    0x0007ffff,
                    0x02,
                    \_SB.PCI0.LNK4,
                    0x00,
                },
                Package(0x04) {
                    0x0007ffff,
                    0x03,
                    \_SB.PCI0.LNK1,
                    0x00,
                },
                Package(0x04) {
                    0x0008ffff,
                    0x00,
                    \_SB.PCI0.LNK3,
                    0x00,
                },
                Package(0x04) {
                    0x0008ffff,
                    0x01,
                    \_SB.PCI0.LNK4,
                    0x00,
                },
                Package(0x04) {
                    0x0008ffff,
                    0x02,
                    \_SB.PCI0.LNK1,
                    0x00,
                },
                Package(0x04) {
                    0x0008ffff,
                    0x03,
                    \_SB.PCI0.LNK2,
                    0x00,
                },
                Package(0x04) {
                    0x000bffff,
                    0x00,
                    \_SB.PCI0.LNK4,
                    0x00,
                },
                Package(0x04) {
                    0x000bffff,
                    0x01,
                    \_SB.PCI0.LNK4,
                    0x00,
                },
                Package(0x04) {
                    0x000bffff,
                    0x02,
                    \_SB.PCI0.LNK4,
                    0x00,
                },
                Package(0x04) {
                    0x000bffff,
                    0x03,
                    \_SB.PCI0.LNK4,
                    0x00,
                },
            })
            Name(APIC, Package(0x10) {
                Package(0x04) {
                    0x0006ffff,
                    0x00,
                    \_SB.PCI0.APC1,
                    0x00,
                },
                Package(0x04) {
                    0x0006ffff,
                    0x01,
                    \_SB.PCI0.APC2,
                    0x00,
                },
                Package(0x04) {
                    0x0006ffff,
                    0x02,
                    \_SB.PCI0.APC3,
                    0x00,
                },
                Package(0x04) {
                    0x0006ffff,
                    0x03,
                    \_SB.PCI0.APC4,
                    0x00,
                },
                Package(0x04) {
                    0x0007ffff,
                    0x00,
                    \_SB.PCI0.APC2,
                    0x00,
                },
                Package(0x04) {
                    0x0007ffff,
                    0x01,
                    \_SB.PCI0.APC3,
                    0x00,
                },
                Package(0x04) {
                    0x0007ffff,
                    0x02,
                    \_SB.PCI0.APC4,
                    0x00,
                },
                Package(0x04) {
                    0x0007ffff,
                    0x03,
                    \_SB.PCI0.APC1,
                    0x00,
                },
                Package(0x04) {
                    0x0008ffff,
                    0x00,
                    \_SB.PCI0.APC3,
                    0x00,
                },
                Package(0x04) {
                    0x0008ffff,
                    0x01,
                    \_SB.PCI0.APC4,
                    0x00,
                },
                Package(0x04) {
                    0x0008ffff,
                    0x02,
                    \_SB.PCI0.APC1,
                    0x00,
                },
                Package(0x04) {
                    0x0008ffff,
                    0x03,
                    \_SB.PCI0.APC2,
                    0x00,
                },
                Package(0x04) {
                    0x000bffff,
                    0x00,
                    \_SB.PCI0.APC4,
                    0x00,
                },
                Package(0x04) {
                    0x000bffff,
                    0x01,
                    \_SB.PCI0.APC4,
                    0x00,
                },
                Package(0x04) {
                    0x000bffff,
                    0x02,
                    \_SB.PCI0.APC4,
                    0x00,
                },
                Package(0x04) {
                    0x000bffff,
                    0x03,
                    \_SB.PCI0.APC4,
                    0x00,
                },
            })
            Method(_PRT) {
                If(LNot(PICF)) {
                    Return(PICM)
                }
                Else {
                    Return(APIC)
                }
            }
            Name(_PRW, Package(0x02) {
                0x00,
                0x05,
            })
        }
        Device(SAT1) {
            Name(_ADR, 0x00050000)
            Device(PRI0) {
                Name(_ADR, 0x00)
                Name(PCS0, 0x00)
                Name(PSS0, 0x00)
                Name(SPTM, Buffer(0x14) {0x78, 0x0, 0x0, 0x0, 0xf, 0x0, 0x0, 
0x0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x13, 0x0, 0x0, 0x0
                /* ResourceTemplate() {
                } */
                 })
                Method(_GTM) {
                    Return(SPTM)
                }
                Method(_STM, 3) {
                    Store(Arg0, SPTM)
                    CreateWordField(Arg1, 0xa4, ICM0)
                    CreateWordField(Arg1, 0x0100, ISE0)
                    Store(ICM0, PCS0)
                    Store(ISE0, PSS0)
                }
                Device(MAST) {
                    Name(_ADR, 0x00)
                    Method(_GTF) {
                        Store(Buffer(0x07) {0x3, 0x46, 0x0, 0x0, 0x0, 0xa0, 
0xef }, Local0)
                        And(PCS0, 0x02, Local2)
                        And(PSS0, 0x01, Local3)
                        If(LEqual(Local2, 0x02)) {
                            If(LEqual(Local3, 0x01)) {
                                Store(Buffer(0x0e) {0x3, 0x46, 0x0, 0x0, 0x0, 
0xa0, 0xef, 0x0, 0x0, 0x0, 0x0, 0x0, 0xa0, 0xf5 }, Local0)
                            }
                        }
                        Return(Local0)
                    }
                }
            }
            Device(SEC0) {
                Name(_ADR, 0x01)
                Name(PCS1, 0x00)
                Name(PSS1, 0x00)
                Name(SSTM, Buffer(0x14) {0x78, 0x0, 0x0, 0x0, 0xf, 0x0, 0x0, 
0x0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x13, 0x0, 0x0, 0x0
                /* ResourceTemplate() {
                } */
                 })
                Method(_GTM) {
                    Return(SSTM)
                }
                Method(_STM, 3) {
                    Store(Arg0, SSTM)
                    CreateWordField(Arg1, 0xa4, ICM1)
                    CreateWordField(Arg1, 0x0100, ISE1)
                    Store(ICM1, PCS1)
                    Store(ISE1, PSS1)
                }
                Device(MAST) {
                    Name(_ADR, 0x00)
                    Method(_GTF) {
                        Store(Buffer(0x07) {0x3, 0x46, 0x0, 0x0, 0x0, 0xa0, 
0xef }, Local0)
                        And(PCS1, 0x02, Local2)
                        And(PSS1, 0x01, Local3)
                        If(LEqual(Local2, 0x02)) {
                            If(LEqual(Local3, 0x01)) {
                                Store(Buffer(0x0e) {0x3, 0x46, 0x0, 0x0, 0x0, 
0xa0, 0xef, 0x0, 0x0, 0x0, 0x0, 0x0, 0xa0, 0xf5 }, Local0)
                            }
                        }
                        Return(Local0)
                    }
                }
            }
            Method(DRMP) {
                Return(\_SB.PCI0.NVRB.R_S0)
            }
        }
        Device(SAT2) {
            Name(_ADR, 0x00050001)
            Device(PRI0) {
                Name(_ADR, 0x00)
                Name(PCS0, 0x00)
                Name(PSS0, 0x00)
                Name(SPTM, Buffer(0x14) {0x78, 0x0, 0x0, 0x0, 0xf, 0x0, 0x0, 
0x0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x13, 0x0, 0x0, 0x0
                /* ResourceTemplate() {
                } */
                 })
                Method(_GTM) {
                    Return(SPTM)
                }
                Method(_STM, 3) {
                    Store(Arg0, SPTM)
                    CreateWordField(Arg1, 0xa4, ICM0)
                    CreateWordField(Arg1, 0x0100, ISE0)
                    Store(ICM0, PCS0)
                    Store(ISE0, PSS0)
                }
                Device(MAST) {
                    Name(_ADR, 0x00)
                    Method(_GTF) {
                        Store(Buffer(0x07) {0x3, 0x46, 0x0, 0x0, 0x0, 0xa0, 
0xef }, Local0)
                        And(PCS0, 0x02, Local2)
                        And(PSS0, 0x01, Local3)
                        If(LEqual(Local2, 0x02)) {
                            If(LEqual(Local3, 0x01)) {
                                Store(Buffer(0x0e) {0x3, 0x46, 0x0, 0x0, 0x0, 
0xa0, 0xef, 0x0, 0x0, 0x0, 0x0, 0x0, 0xa0, 0xf5 }, Local0)
                            }
                        }
                        Return(Local0)
                    }
                }
            }
            Device(SEC0) {
                Name(_ADR, 0x01)
                Name(PCS1, 0x00)
                Name(PSS1, 0x00)
                Name(SSTM, Buffer(0x14) {0x78, 0x0, 0x0, 0x0, 0xf, 0x0, 0x0, 
0x0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x13, 0x0, 0x0, 0x0
                /* ResourceTemplate() {
                } */
                 })
                Method(_GTM) {
                    Return(SSTM)
                }
                Method(_STM, 3) {
                    Store(Arg0, SSTM)
                    CreateWordField(Arg1, 0xa4, ICM1)
                    CreateWordField(Arg1, 0x0100, ISE1)
                    Store(ICM1, PCS1)
                    Store(ISE1, PSS1)
                }
                Device(MAST) {
                    Name(_ADR, 0x00)
                    Method(_GTF) {
                        Store(Buffer(0x07) {0x3, 0x46, 0x0, 0x0, 0x0, 0xa0, 
0xef }, Local0)
                        And(PCS1, 0x02, Local2)
                        And(PSS1, 0x01, Local3)
                        If(LEqual(Local2, 0x02)) {
                            If(LEqual(Local3, 0x01)) {
                                Store(Buffer(0x0e) {0x3, 0x46, 0x0, 0x0, 0x0, 
0xa0, 0xef, 0x0, 0x0, 0x0, 0x0, 0x0, 0xa0, 0xf5 }, Local0)
                            }
                        }
                        Return(Local0)
                    }
                }
            }
            Method(DRMP) {
                Return(\_SB.PCI0.NVRB.R_S1)
            }
        }
        Device(SAT3) {
            Name(_ADR, 0x00050002)
            Device(PRI0) {
                Name(_ADR, 0x00)
                Name(PCS0, 0x00)
                Name(PSS0, 0x00)
                Name(SPTM, Buffer(0x14) {0x78, 0x0, 0x0, 0x0, 0xf, 0x0, 0x0, 
0x0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x13, 0x0, 0x0, 0x0
                /* ResourceTemplate() {
                } */
                 })
                Method(_GTM) {
                    Return(SPTM)
                }
                Method(_STM, 3) {
                    Store(Arg0, SPTM)
                    CreateWordField(Arg1, 0xa4, ICM0)
                    CreateWordField(Arg1, 0x0100, ISE0)
                    Store(ICM0, PCS0)
                    Store(ISE0, PSS0)
                }
                Device(MAST) {
                    Name(_ADR, 0x00)
                    Method(_GTF) {
                        Store(Buffer(0x07) {0x3, 0x46, 0x0, 0x0, 0x0, 0xa0, 
0xef }, Local0)
                        And(PCS0, 0x02, Local2)
                        And(PSS0, 0x01, Local3)
                        If(LEqual(Local2, 0x02)) {
                            If(LEqual(Local3, 0x01)) {
                                Store(Buffer(0x0e) {0x3, 0x46, 0x0, 0x0, 0x0, 
0xa0, 0xef, 0x0, 0x0, 0x0, 0x0, 0x0, 0xa0, 0xf5 }, Local0)
                            }
                        }
                        Return(Local0)
                    }
                }
            }
            Device(SEC0) {
                Name(_ADR, 0x01)
                Name(PCS1, 0x00)
                Name(PSS1, 0x00)
                Name(SSTM, Buffer(0x14) {0x78, 0x0, 0x0, 0x0, 0xf, 0x0, 0x0, 
0x0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x13, 0x0, 0x0, 0x0
                /* ResourceTemplate() {
                } */
                 })
                Method(_GTM) {
                    Return(SSTM)
                }
                Method(_STM, 3) {
                    Store(Arg0, SSTM)
                    CreateWordField(Arg1, 0xa4, ICM1)
                    CreateWordField(Arg1, 0x0100, ISE1)
                    Store(ICM1, PCS1)
                    Store(ISE1, PSS1)
                }
                Device(MAST) {
                    Name(_ADR, 0x00)
                    Method(_GTF) {
                        Store(Buffer(0x07) {0x3, 0x46, 0x0, 0x0, 0x0, 0xa0, 
0xef }, Local0)
                        And(PCS1, 0x02, Local2)
                        And(PSS1, 0x01, Local3)
                        If(LEqual(Local2, 0x02)) {
                            If(LEqual(Local3, 0x01)) {
                                Store(Buffer(0x0e) {0x3, 0x46, 0x0, 0x0, 0x0, 
0xa0, 0xef, 0x0, 0x0, 0x0, 0x0, 0x0, 0xa0, 0xf5 }, Local0)
                            }
                        }
                        Return(Local0)
                    }
                }
            }
            Method(DRMP) {
                Return(\_SB.PCI0.NVRB.R_S2)
            }
        }
        Device(IDE0) {
            Name(_ADR, 0x00040000)
            OperationRegion(A090, PCI_Config, 0x50, 0x18)
            Field(A090, DWordAcc, NoLock, Preserve) {
                ID20,   16,
                Offset(0x8),
                IDTS,   16,
                IDTP,   16,
                ID22,   32,
                UMSS,   16,
                UMSP,   16
            }
            Name(IDEP, Buffer(0x14) { })
            Name(IDES, Buffer(0x14) { })
            Method(GTM, 1) {
                If(LEqual(Arg0, 0x00)) {
                    Store(IDTP, Local0)
                    Store(UMSP, Local1)
                    Store(IDEP, Local2)
                }
                Else {
                    Store(IDTS, Local0)
                    Store(UMSS, Local1)
                    Store(IDES, Local2)
                }
                CreateDWordField(Local2, 0x00, PIO0)
                CreateDWordField(Local2, 0x04, DMA0)
                CreateDWordField(Local2, 0x08, PIO1)
                CreateDWordField(Local2, 0x0c, DMA1)
                CreateDWordField(Local2, 0x10, FLAG)
                Store(0x10, FLAG)
                And(Local0, 0x0f00, Local3)
                And(Local0, 0xf000, Local4)
                ShiftRight(Local3, 0x08, Local3)
                ShiftRight(Local4, 0x0c, Local4)
                Add(Local3, Local4, Local3)
                Multiply(Add(Local3, 0x02, ), 0x1e, PIO0)
                If(LNot(LGreater(PIO0, 0xb4))) {
                    Or(FLAG, 0x02, FLAG)
                }
                If(And(Local1, 0x4000, )) {
                    Or(FLAG, 0x01, FLAG)
                    And(Local1, 0x0700, Local3)
                    ShiftRight(Local3, 0x08, Local3)
                    Store(U2T(Local3), DMA0)
                }
                Else {
                    Store(PIO0, DMA0)
                }
                And(Local0, 0x0f, Local3)
                And(Local0, 0xf0, Local4)
                ShiftRight(Local4, 0x04, Local4)
                Add(Local3, Local4, Local3)
                Multiply(Add(Local3, 0x02, ), 0x1e, PIO1)
                If(LNot(LGreater(PIO1, 0xb4))) {
                    Or(FLAG, 0x08, FLAG)
                }
                If(And(Local1, 0x40, )) {
                    Or(FLAG, 0x04, FLAG)
                    And(Local1, 0x07, Local3)
                    Store(U2T(Local3), DMA1)
                }
                Else {
                    Store(PIO1, DMA1)
                }
                If(LEqual(Arg0, 0x00)) {
                    Store(Local2, IDEP)
                    Return(IDEP)
                }
                Else {
                    Store(Local2, IDES)
                    Return(IDES)
                }
            }
            Method(U2T, 1) {
                If(LEqual(Arg0, 0x00)) {
                    Return(0x3c)
                }
                If(LEqual(Arg0, 0x01)) {
                    Return(0x5a)
                }
                If(LEqual(Arg0, 0x02)) {
                    Return(0x78)
                }
                If(LEqual(Arg0, 0x03)) {
                    Return(0x96)
                }
                If(LEqual(Arg0, 0x04)) {
                    Return(0x2d)
                }
                If(LEqual(Arg0, 0x05)) {
                    Return(0x1e)
                }
                If(LEqual(Arg0, 0x06)) {
                    Return(0x14)
                }
                Return(0x0f)
            }
            Method(T2U, 1) {
                If(LGreater(Arg0, 0x78)) {
                    Return(0x03)
                }
                If(LGreater(Arg0, 0x5a)) {
                    Return(0x02)
                }
                If(LGreater(Arg0, 0x3c)) {
                    Return(0x01)
                }
                If(LGreater(Arg0, 0x2d)) {
                    Return(0x00)
                }
                If(LGreater(Arg0, 0x1e)) {
                    Return(0x04)
                }
                If(LGreater(Arg0, 0x14)) {
                    Return(0x05)
                }
                If(LGreater(Arg0, 0x0f)) {
                    Return(0x06)
                }
                Return(0x07)
            }
            Method(T2D, 1) {
                If(LGreater(Arg0, 0x01e0)) {
                    Return(0xa8)
                }
                If(LGreater(Arg0, 0x0186)) {
                    Return(0x77)
                }
                If(LGreater(Arg0, 0xf0)) {
                    Return(0x47)
                }
                If(LGreater(Arg0, 0xb4)) {
                    Return(0x33)
                }
                If(LGreater(Arg0, 0x96)) {
                    Return(0x22)
                }
                If(LGreater(Arg0, 0x78)) {
                    Return(0x21)
                }
                Return(0x20)
            }
            Method(STM, 4) {
                If(SX) {
                    Store(SID0, ID20)
                    Store(SID1, IDTS)
                    Store(SID2, IDTP)
                    Store(SID3, ID22)
                    Store(SID4, UMSS)
                    Store(SID5, UMSP)
                }
                Else {
                    Store(ID20, SID0)
                    Store(IDTS, SID1)
                    Store(IDTP, SID2)
                    Store(ID22, SID3)
                    Store(UMSS, SID4)
                    Store(UMSP, SID5)
                }
                Store(0x00, SX)
                CreateDWordField(Arg0, 0x00, PIO0)
                CreateDWordField(Arg0, 0x04, DMA0)
                CreateDWordField(Arg0, 0x08, PIO1)
                CreateDWordField(Arg0, 0x0c, DMA1)
                CreateDWordField(Arg0, 0x10, FLAG)
                If(LEqual(Arg3, 0x00)) {
                    Store(SID2, Local0)
                    Store(SID5, Local1)
                }
                Else {
                    Store(SID1, Local0)
                    Store(SID4, Local1)
                }
                If(LNot(LEqual(PIO0, 0xffffffff))) {
                    And(Local0, 0xff, Local0)
                    ShiftLeft(T2D(PIO0), 0x08, Local2)
                    Or(Local0, Local2, Local0)
                }
                If(LNot(LEqual(PIO1, 0xffffffff))) {
                    And(Local0, 0xff00, Local0)
                    Or(Local0, T2D(PIO1), Local0)
                }
                If(And(FLAG, 0x01, )) {
                    And(Local1, 0xff, Local1)
                    ShiftLeft(T2U(DMA0), 0x08, Local2)
                    Or(0xc000, Local2, Local2)
                    Or(Local2, Local1, Local1)
                }
                Else {
                    If(LNot(LEqual(DMA0, 0xffffffff))) {
                        And(Local0, 0xff, Local0)
                        ShiftLeft(T2D(DMA0), 0x08, Local2)
                        Or(Local0, Local2, Local0)
                    }
                }
                If(And(FLAG, 0x04, )) {
                    And(Local1, 0xff00, Local1)
                    Or(0xc0, T2U(DMA1), Local2)
                    Or(Local2, Local1, Local1)
                }
                Else {
                    If(LNot(LEqual(DMA1, 0xffffffff))) {
                        And(Local0, 0xff00, Local0)
                        Or(Local0, T2D(DMA1), Local0)
                    }
                }
                If(LEqual(Arg3, 0x00)) {
                    Store(Local0, IDTP)
                    Store(Local1, UMSP)
                }
                Else {
                    Store(Local0, IDTS)
                    Store(Local1, UMSS)
                }
            }
            Method(GTF, 2) {
                Store(Buffer(0x07) {0x3, 0x0, 0x0, 0x0, 0x0, 0xa0, 0xef }, 
Local0)
                CreateByteField(Local0, 0x01, MODE)
                CreateByteField(Local0, 0x05, DRIV)
                Store(Arg1, DRIV)
                If(LEqual(Arg0, 0x00)) {
                    Store(IDEP, Local1)
                }
                Else {
                    Store(IDES, Local1)
                }
                CreateDWordField(Local1, 0x00, PIO0)
                CreateDWordField(Local1, 0x04, DMA0)
                CreateDWordField(Local1, 0x08, PIO1)
                CreateDWordField(Local1, 0x0c, DMA1)
                CreateDWordField(Local1, 0x10, FLGX)
                If(LEqual(Arg1, 0xa0)) {
                    Store(PIO0, Local2)
                    Store(DMA0, Local3)
                    And(FLGX, 0x01, FLGX)
                }
                Else {
                    Store(PIO1, Local2)
                    Store(DMA1, Local3)
                    And(FLGX, 0x04, FLGX)
                }
                Store(FLGX, Local1)
                If(LGreater(Local2, 0x0186)) {
                    Store(0x00, Local2)
                }
                Else {
                    If(LGreater(Local2, 0xf0)) {
                        Store(0x01, Local2)
                    }
                    Else {
                        If(LGreater(Local2, 0xb4)) {
                            Store(0x02, Local2)
                        }
                        Else {
                            If(LGreater(Local2, 0x78)) {
                                Store(0x03, Local2)
                            }
                            Else {
                                Store(0x04, Local2)
                            }
                        }
                    }
                }
                Or(0x08, Local2, MODE)
                Store(Local0, Local2)
                If(FLGX) {
                    If(LGreater(Local3, 0x5a)) {
                        Store(0x00, Local3)
                    }
                    Else {
                        If(LGreater(Local3, 0x3c)) {
                            Store(0x01, Local3)
                        }
                        Else {
                            If(LGreater(Local3, 0x2d)) {
                                Store(0x02, Local3)
                            }
                            Else {
                                If(LGreater(Local3, 0x1e)) {
                                    Store(0x03, Local3)
                                }
                                Else {
                                    If(LGreater(Local3, 0x14)) {
                                        Store(0x04, Local3)
                                    }
                                    Else {
                                        If(LGreater(Local3, 0x0f)) {
                                            Store(0x05, Local3)
                                        }
                                        Else {
                                            Store(0x06, Local3)
                                        }
                                    }
                                }
                            }
                        }
                    }
                    Or(0x40, Local3, MODE)
                }
                Else {
                    If(LEqual(Local3, 0xffffffff)) {
                        Return(Local0)
                    }
                    Else {
                        If(LGreater(Local3, 0x96)) {
                            Store(0x00, Local3)
                        }
                        Else {
                            If(LGreater(Local3, 0x78)) {
                                Store(0x01, Local3)
                            }
                            Else {
                                Store(0x02, Local3)
                            }
                        }
                        Or(0x20, Local3, MODE)
                    }
                }
                Concatenate(Local0, Local2, Local1)
                Return(Local1)
            }
            Device(PRI0) {
                Name(_ADR, 0x00)
                Name(PCS0, 0x00)
                Name(PSS0, 0x00)
                Name(PCS1, 0x00)
                Name(PSS1, 0x00)
                Method(_GTM) {
                    Return(GTM(0x00))
                }
                Method(_STM, 3) {
                    STM(Arg0, Arg1, Arg2, 0x00)
                    CreateWordField(Arg1, 0xa4, ICM0)
                    CreateWordField(Arg1, 0x0100, ISE0)
                    CreateWordField(Arg2, 0xa4, ICM1)
                    CreateWordField(Arg2, 0x0100, ISE1)
                    Store(ICM0, PCS0)
                    Store(ISE0, PSS0)
                    Store(ICM1, PCS1)
                    Store(ISE1, PSS1)
                }
                Device(MAST) {
                    Name(_ADR, 0x00)
                    Method(_GTF) {
                        Store(GTF(0x00, 0xa0), Local0)
                        And(PCS0, 0x02, Local2)
                        And(PSS0, 0x01, Local3)
                        If(LEqual(Local2, 0x02)) {
                            If(LEqual(Local3, 0x01)) {
                                Store(Buffer(0x07) {0x0, 0x0, 0x0, 0x0, 0x0, 
0xa0, 0xf5 }, Local1)
                                Concatenate(Local0, Local1, Local0)
                            }
                        }
                        Return(Local0)
                    }
                }
                Device(SLAV) {
                    Name(_ADR, 0x01)
                    Method(_GTF) {
                        Store(GTF(0x00, 0xb0), Local0)
                        And(PCS1, 0x02, Local2)
                        And(PSS1, 0x01, Local3)
                        If(LEqual(Local2, 0x02)) {
                            If(LEqual(Local3, 0x01)) {
                                Store(Buffer(0x07) {0x0, 0x0, 0x0, 0x0, 0x0, 
0xa0, 0xf5 }, Local1)
                                Concatenate(Local0, Local1, Local0)
                            }
                        }
                        Return(Local0)
                    }
                }
            }
            Device(SEC0) {
                Name(_ADR, 0x01)
                Name(PCS0, 0x00)
                Name(PSS0, 0x00)
                Name(PCS1, 0x00)
                Name(PSS1, 0x00)
                Method(_GTM) {
                    Return(GTM(0x01))
                }
                Method(_STM, 3) {
                    STM(Arg0, Arg1, Arg2, 0x01)
                    CreateWordField(Arg1, 0xa4, ICM0)
                    CreateWordField(Arg1, 0x0100, ISE0)
                    CreateWordField(Arg2, 0xa4, ICM1)
                    CreateWordField(Arg2, 0x0100, ISE1)
                    Store(ICM0, PCS0)
                    Store(ISE0, PSS0)
                    Store(ICM1, PCS1)
                    Store(ISE1, PSS1)
                }
                Device(MAST) {
                    Name(_ADR, 0x00)
                    Method(_GTF) {
                        Store(GTF(0x01, 0xa0), Local0)
                        And(PCS0, 0x02, Local2)
                        And(PSS0, 0x01, Local3)
                        If(LEqual(Local2, 0x02)) {
                            If(LEqual(Local3, 0x01)) {
                                Store(Buffer(0x07) {0x0, 0x0, 0x0, 0x0, 0x0, 
0xa0, 0xf5 }, Local1)
                                Concatenate(Local0, Local1, Local0)
                            }
                        }
                        Return(Local0)
                    }
                }
                Device(SLAV) {
                    Name(_ADR, 0x01)
                    Method(_GTF) {
                        Store(GTF(0x01, 0xb0), Local0)
                        And(PCS1, 0x02, Local2)
                        And(PSS1, 0x01, Local3)
                        If(LEqual(Local2, 0x02)) {
                            If(LEqual(Local3, 0x01)) {
                                Store(Buffer(0x07) {0x0, 0x0, 0x0, 0x0, 0x0, 
0xb0, 0xf5 }, Local1)
                                Concatenate(Local0, Local1, Local0)
                            }
                        }
                        Return(Local0)
                    }
                }
            }
            Method(DRMP) {
                Return(\_SB.PCI0.NVRB.R_P0)
            }
        }
        Device(XVR0) {
            Name(_ADR, 0x000f0000)
            OperationRegion(PCV0, PCI_Config, 0x00, 0xff)
            Scope(\) {
                Field(\_SB.PCI0.XVR0.PCV0, ByteAcc, NoLock, Preserve) {
                    PEV0,       16,
                    Offset(0x9c),
                    ,   3,
                    XPE0,       1,
                    Offset(0xa0),
                    RQD0,       16,
                    PES0,       1,
                    PEP0,       1
                }
            }
            Name(_PRW, Package(0x02) {
                0x11,
                0x05,
            })
        }
        Device(XVR1) {
            Name(_ADR, 0x000e0000)
            OperationRegion(PCV1, PCI_Config, 0x00, 0xff)
            Scope(\) {
                Field(\_SB.PCI0.XVR1.PCV1, ByteAcc, NoLock, Preserve) {
                    PEV1,       16,
                    Offset(0x9c),
                    ,   3,
                    XPE1,       1,
                    Offset(0xa0),
                    RQD1,       16,
                    PES1,       1,
                    PEP1,       1
                }
            }
            Name(_PRW, Package(0x02) {
                0x11,
                0x05,
            })
        }
        Device(XVR2) {
            Name(_ADR, 0x000d0000)
            OperationRegion(PCV2, PCI_Config, 0x00, 0xff)
            Scope(\) {
                Field(\_SB.PCI0.XVR2.PCV2, ByteAcc, NoLock, Preserve) {
                    PEV2,       16,
                    Offset(0x9c),
                    ,   3,
                    XPE2,       1,
                    Offset(0xa0),
                    RQD2,       16,
                    PES2,       1,
                    PEP2,       1
                }
            }
            Name(_PRW, Package(0x02) {
                0x11,
                0x05,
            })
        }
        Device(XVR3) {
            Name(_ADR, 0x000c0000)
            OperationRegion(PCV3, PCI_Config, 0x00, 0xff)
            Scope(\) {
                Field(\_SB.PCI0.XVR3.PCV3, ByteAcc, NoLock, Preserve) {
                    PEV3,       16,
                    Offset(0x9c),
                    ,   3,
                    XPE3,       1,
                    Offset(0xa0),
                    RQD3,       16,
                    PES3,       1,
                    PEP3,       1
                }
            }
            Name(_PRW, Package(0x02) {
                0x11,
                0x05,
            })
        }
        Device(XVR4) {
            Name(_ADR, 0x000b0000)
            OperationRegion(PCV4, PCI_Config, 0x00, 0xff)
            Scope(\) {
                Field(\_SB.PCI0.XVR4.PCV4, ByteAcc, NoLock, Preserve) {
                    PEV4,       16,
                    Offset(0x9c),
                    ,   3,
                    XPE4,       1,
                    Offset(0xa0),
                    RQD4,       16,
                    PES4,       1,
                    PEP4,       1
                }
            }
            Name(_PRW, Package(0x02) {
                0x11,
                0x05,
            })
        }
        Device(XVR5) {
            Name(_ADR, 0x000a0000)
            OperationRegion(PCV5, PCI_Config, 0x00, 0xff)
            Scope(\) {
                Field(\_SB.PCI0.XVR5.PCV5, ByteAcc, NoLock, Preserve) {
                    PEV5,       16,
                    Offset(0x9c),
                    ,   3,
                    XPE5,       1,
                    Offset(0xa0),
                    RQD5,       16,
                    PES5,       1,
                    PEP5,       1
                }
            }
            Name(_PRW, Package(0x02) {
                0x11,
                0x05,
            })
        }
        Device(SMB0) {
            Name(_ADR, 0x00010001)
            OperationRegion(SMCF, PCI_Config, 0x48, 0x10)
            Field(SMCF, DWordAcc, NoLock, Preserve) {
                SMPM,   4,
                SMT1,   28,
                SMT2,   32
            }
            OperationRegion(SMCA, PCI_Config, 0x20, 0x08)
            Field(SMCA, DWordAcc, NoLock, Preserve) {
                SB1,    32,
                SB2,    32
            }
            Method(SMBB) {
                If(PCIA) {
                    And(SB1, 0xfffe, Local0)
                    And(SB2, 0xfffe, Local0)
                }
                Else {
                    Store(0x1c00, Local0)
                    Store(0x1c40, Local0)
                }
                Return(Local0)
            }
        }
        Device(LEG0) {
            Name(_ADR, 0x00010000)
            OperationRegion(PIO0, PCI_Config, 0x04, 0x20)
            Scope(\) {
                Field(\_SB.PCI0.LEG0.PIO0, ByteAcc, NoLock, Preserve) {
                    SMEN,       8,
                    Offset(0xc),
                    Offset(0xd),
                    SMIO,       8
                }
            }
            Scope(\) {
                OperationRegion(\SCPP, SystemIO, 0x142e, 0x01)
                Field(\SCPP, ByteAcc, NoLock, Preserve) {
                    SMIP,       8
                }
            }
            Method(\_SB.PCI0._INI) {
                If(STRC(\_OS, "Microsoft\x20Windows")) {
                    Store(0x56, SMIP)
                }
                Else {
                    If(STRC(\_OS, "Microsoft\x20Windows\x20NT")) {
                        If(CondRefOf(\_OSI, Local0)) {
                            If(\_OSI("Windows\x202001")) {
                                Store(0x59, SMIP)
                                Store(0x00, OSFL)
                                Store(0x03, OSFX)
                            }
                            If(\_OSI("Windows\x202006")) {
                                Store(0x01, VSTA)
                            }
                        }
                        Else {
                            Store(0x58, SMIP)
                            Store(0x00, OSFX)
                            Store(0x00, OSFL)
                        }
                    }
                    Else {
                        Store(0x57, SMIP)
                        Store(0x02, OSFX)
                        Store(0x02, OSFL)
                    }
                }
                Name(TEMP, 0x00)
                Store(UA1D, TEMP)
                And(TEMP, 0x0f, TEMP)
                If(LEqual(TEMP, 0x01)) {
                    Store(0x01, UARA)
                }
                If(LEqual(TEMP, 0x02)) {
                    Store(0x02, UARA)
                }
                If(LEqual(TEMP, 0x03)) {
                    Store(0x20, UARA)
                }
                If(LEqual(TEMP, 0x04)) {
                    Store(0x80, UARA)
                }
                Store(UA1D, TEMP)
                And(TEMP, 0xf0, TEMP)
                ShiftRight(TEMP, 0x04, TEMP)
                If(LEqual(TEMP, 0x01)) {
                    Store(0x01, UARB)
                }
                If(LEqual(TEMP, 0x02)) {
                    Store(0x02, UARB)
                }
                If(LEqual(TEMP, 0x03)) {
                    Store(0x20, UARB)
                }
                If(LEqual(TEMP, 0x04)) {
                    Store(0x80, UARB)
                }
            }
            Scope(\) {
                Method(OSTP) {
                    If(LEqual(OSFX, 0x01)) {
                        Store(0x56, SMIP)
                    }
                    If(LEqual(OSFX, 0x02)) {
                        Store(0x57, SMIP)
                    }
                    If(LEqual(OSFX, 0x00)) {
                        Store(0x58, SMIP)
                    }
                    If(LEqual(OSFX, 0x03)) {
                        Store(0x59, SMIP)
                    }
                }
            }
            Device(SYSR) {
                Name(_HID, 0x020cd041)
                Name(_UID, 0x01)
                Name(_CRS, Buffer(0x62) {0x47, 0x1, 0x10, 0x0, 0x10, 0x0, 0x1, 
0x10, 0x47, 0x1, 0x22, 0x0, 0x22, 0x0, 0x1, 0x1e, 0x47, 0x1, 0x44, 0x0, 0x44, 
0x0, 0x1, 0x1c, 0x47, 0x1, 0x62, 0x0, 0x62, 0x0, 0x1, 0x2, 0x47, 0x1, 0x65, 
0x0, 0x65, 0x0, 0x1, 0xb, 0x47, 0x1, 0x74, 0x0, 0x74, 0x0, 0x1, 0xc, 0x47, 0x1, 
0x91, 0x0, 0x91, 0x0, 0x1, 0x3, 0x47, 0x1, 0xa2, 0x0, 0xa2, 0x0, 0x1, 0x1e, 
0x47, 0x1, 0xe0, 0x0, 0xe0, 0x0, 0x1, 0x10, 0x47, 0x1, 0xd0, 0x4, 0xd0, 0x4, 
0x1, 0x2, 0x47, 0x1, 0x0, 0x8, 0x0, 0x8, 0x1, 0x2, 0x47, 0x1, 0x90, 0x2, 0x90, 
0x2, 0x1, 0x8, 0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  IO(Decode16, 0x10, 0x10, 0x1, 0x10)
                 0x0008  IO(Decode16, 0x22, 0x22, 0x1, 0x1e)
                 0x0010  IO(Decode16, 0x44, 0x44, 0x1, 0x1c)
                 0x0018  IO(Decode16, 0x62, 0x62, 0x1, 0x2)
                 0x0020  IO(Decode16, 0x65, 0x65, 0x1, 0xb)
                 0x0028  IO(Decode16, 0x74, 0x74, 0x1, 0xc)
                 0x0030  IO(Decode16, 0x91, 0x91, 0x1, 0x3)
                 0x0038  IO(Decode16, 0xa2, 0xa2, 0x1, 0x1e)
                 0x0040  IO(Decode16, 0xe0, 0xe0, 0x1, 0x10)
                 0x0048  IO(Decode16, 0x4d0, 0x4d0, 0x1, 0x2)
                 0x0050  IO(Decode16, 0x800, 0x800, 0x1, 0x2)
                 0x0058  IO(Decode16, 0x290, 0x290, 0x1, 0x8)
                } */
                 })
            }
            Device(PIC) {
                Name(_HID, 0xd041)
                Name(_CRS, Buffer(0x15) {0x47, 0x1, 0x20, 0x0, 0x20, 0x0, 0x1, 
0x2, 0x47, 0x1, 0xa0, 0x0, 0xa0, 0x0, 0x1, 0x2, 0x22, 0x4, 0x0, 0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  IO(Decode16, 0x20, 0x20, 0x1, 0x2)
                 0x0008  IO(Decode16, 0xa0, 0xa0, 0x1, 0x2)
                 0x0010  IRQ() {2}
                } */
                 })
            }
            Device(DMA1) {
                Name(_HID, 0x0002d041)
                Name(_CRS, Buffer(0x25) {0x2a, 0x10, 0x4, 0x47, 0x1, 0x0, 0x0, 
0x0, 0x0, 0x1, 0x10, 0x47, 0x1, 0x80, 0x0, 0x80, 0x0, 0x1, 0x11, 0x47, 0x1, 
0x94, 0x0, 0x94, 0x0, 0x1, 0xc, 0x47, 0x1, 0xc0, 0x0, 0xc0, 0x0, 0x1, 0x20, 
0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  DMA(Compatibility, BusMaster, Transfer8) {4}
                 0x0003  IO(Decode16, 0x0, 0x0, 0x1, 0x10)
                 0x000b  IO(Decode16, 0x80, 0x80, 0x1, 0x11)
                 0x0013  IO(Decode16, 0x94, 0x94, 0x1, 0xc)
                 0x001b  IO(Decode16, 0xc0, 0xc0, 0x1, 0x20)
                } */
                 })
            }
            Device(TMR) {
                Name(_HID, 0x0001d041)
                Name(ATT5, Buffer(0x0d) {0x47, 0x1, 0x40, 0x0, 0x40, 0x0, 0x0, 
0x4, 0x22, 0x1, 0x0, 0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  IO(Decode16, 0x40, 0x40, 0x0, 0x4)
                 0x0008  IRQ() {0}
                } */
                 })
                Name(ATT6, Buffer(0x0a) {0x47, 0x1, 0x40, 0x0, 0x40, 0x0, 0x0, 
0x4, 0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  IO(Decode16, 0x40, 0x40, 0x0, 0x4)
                } */
                 })
                Method(_CRS) {
                    If(LEqual(OSFX, 0x03)) {
                        If(HPTF) {
                            Return(ATT6)
                        }
                        Else {
                            Return(ATT5)
                        }
                    }
                    Else {
                        Return(ATT5)
                    }
                }
            }
            Device(HPET) {
                Name(_HID, 0x0301d041)
                Name(ATT3, Buffer(0x14) {0x22, 0x1, 0x0, 0x22, 0x0, 0x1, 0x86, 
0x9, 0x0, 0x1, 0x0, 0xf0, 0xff, 0xfe, 0x0, 0x4, 0x0, 0x0, 0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  IRQ() {0}
                 0x0003  IRQ() {8}
                 0x0006  Memory32Fixed(ReadWrite, 0xfefff000, 0x400)
                } */
                 })
                Name(ATT4, Buffer(0x02) {0x79, 0x0
                /* ResourceTemplate() {
                } */
                 })
                Method(_STA) {
                    If(LEqual(OSFX, 0x03)) {
                        If(HPTF) {
                            Return(0x0f)
                        }
                        Else {
                            Return(0x00)
                        }
                    }
                    Else {
                        Return(0x00)
                    }
                }
                Method(_CRS) {
                    If(LEqual(OSFX, 0x03)) {
                        If(HPTF) {
                            Return(ATT3)
                        }
                        Else {
                            Return(ATT4)
                        }
                    }
                    Else {
                        Return(ATT4)
                    }
                }
            }
            Device(RTC) {
                Name(_HID, 0x000bd041)
                Name(ATT0, Buffer(0x0d) {0x47, 0x1, 0x70, 0x0, 0x70, 0x0, 0x0, 
0x4, 0x22, 0x0, 0x1, 0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  IO(Decode16, 0x70, 0x70, 0x0, 0x4)
                 0x0008  IRQ() {8}
                } */
                 })
                Name(ATT1, Buffer(0x0a) {0x47, 0x1, 0x70, 0x0, 0x70, 0x0, 0x0, 
0x4, 0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  IO(Decode16, 0x70, 0x70, 0x0, 0x4)
                } */
                 })
                Method(_CRS) {
                    If(LEqual(OSFX, 0x03)) {
                        If(HPTF) {
                            Return(ATT1)
                        }
                        Else {
                            Return(ATT0)
                        }
                    }
                    Else {
                        Return(ATT0)
                    }
                }
            }
            Device(SPKR) {
                Name(_HID, 0x0008d041)
                Name(_CRS, Buffer(0x0a) {0x47, 0x1, 0x61, 0x0, 0x61, 0x0, 0x1, 
0x1, 0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  IO(Decode16, 0x61, 0x61, 0x1, 0x1)
                } */
                 })
            }
            Device(COPR) {
                Name(_HID, 0x040cd041)
                Name(_CRS, Buffer(0x0d) {0x47, 0x1, 0xf0, 0x0, 0xf0, 0x0, 0x1, 
0x10, 0x22, 0x0, 0x20, 0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  IO(Decode16, 0xf0, 0xf0, 0x1, 0x10)
                 0x0008  IRQ() {13}
                } */
                 })
            }
            Scope(\) {
                OperationRegion(WNFG, SystemIO, 0x2e, 0x01)
                Field(WNFG, ByteAcc, NoLock, Preserve) {
                    INSX,       8
                }
                OperationRegion(WIN1, SystemIO, 0x2e, 0x02)
                Field(WIN1, ByteAcc, NoLock, Preserve) {
                    INDP,       8,
                    DATP,       8
                }
                IndexField(INDP, DATP, ByteAcc, NoLock, Preserve) {
                    Offset(0x2),
                    CFG,        8,
                    Offset(0x7),
                    LDN,        8,
                    Offset(0x20),
                    IDHI,       8,
                    IDLO,       8,
                    POWC,       8,
                    Offset(0x30),
                    ACTR,       8,
                    Offset(0x60),
                    IOAH,       8,
                    IOAL,       8,
                    IO2H,       8,
                    IO2L,       8,
                    Offset(0x70),
                    INTR,       8,
                    Offset(0x72),
                    INT1,       8,
                    Offset(0x74),
                    DMCH,       8,
                    Offset(0xf0),
                    OPT1,       8,
                    OPT2,       8,
                    OPT3,       8
                }
                Method(ENFG) {
                    Store(0x87, INDP)
                    Store(0x01, INDP)
                    Store(0x55, INDP)
                    Store(0x55, INDP)
                    Or(POWC, 0x80, POWC)
                }
                Method(EXFG) {
                    Store(0x02, CFG)
                }
                Method(GSRG, 1) {
                    Store(Arg0, INDP)
                    Return(DATP)
                }
                Method(SSRG, 2) {
                    Store(Arg0, INDP)
                    Store(Arg1, DATP)
                }
            }
            Device(FDC0) {
                Name(_HID, 0x0007d041)
                Method(_STA) {
                    ENFG()
                    Store(Zero, LDN)
                    If(ACTR) {
                        EXFG()
                        Return(0x0f)
                    }
                    Else {
                        If(LOr(IOAH, IOAL)) {
                            EXFG()
                            Return(0x0d)
                        }
                        Else {
                            EXFG()
                            Return(0x00)
                        }
                    }
                }
                Method(_DIS) {
                    ENFG()
                    Store(0x00, LDN)
                    Store(Zero, ACTR)
                    SLDM(DMCH, 0x04)
                    EXFG()
                    DISD(0x03)
                }
                Method(_CRS) {
                    Name(BUF0, Buffer(0x18) {0x47, 0x1, 0xf0, 0x3, 0xf0, 0x3, 
0x1, 0x6, 0x47, 0x1, 0xf7, 0x3, 0xf7, 0x3, 0x1, 0x1, 0x22, 0x40, 0x0, 0x2a, 
0x4, 0x0, 0x79, 0x0
                    /* ResourceTemplate() {
                     0x0000  IO(Decode16, 0x3f0, 0x3f0, 0x1, 0x6)
                     0x0008  IO(Decode16, 0x3f7, 0x3f7, 0x1, 0x1)
                     0x0010  IRQ() {6}
                     0x0013  DMA(Compatibility, NotBusMaster, Transfer8) {2}
                    } */
                     })
                    CreateByteField(BUF0, 0x02, IOLO)
                    CreateByteField(BUF0, 0x03, IOHI)
                    CreateByteField(BUF0, 0x04, IORL)
                    CreateByteField(BUF0, 0x05, IORH)
                    ENFG()
                    EXFG()
                    Return(BUF0)
                }
                Name(_PRS, Buffer(0x1a) {0x30, 0x47, 0x1, 0xf0, 0x3, 0xf0, 0x3, 
0x1, 0x6, 0x47, 0x1, 0xf7, 0x3, 0xf7, 0x3, 0x1, 0x1, 0x22, 0x40, 0x0, 0x2a, 
0x4, 0x0, 0x38, 0x79, 0x0
                /* ResourceTemplate() {
                    StartDependentFn() {
                     0x0001  IO(Decode16, 0x3f0, 0x3f0, 0x1, 0x6)
                     0x0009  IO(Decode16, 0x3f7, 0x3f7, 0x1, 0x1)
                     0x0011  IRQ() {6}
                     0x0014  DMA(Compatibility, NotBusMaster, Transfer8) {2}
                    }
                    EndDependentFn() {}
                } */
                 })
                Method(_SRS, 1) {
                    CreateByteField(Arg0, 0x02, IOLO)
                    CreateByteField(Arg0, 0x03, IOHI)
                    CreateWordField(Arg0, 0x02, IOAD)
                    CreateWordField(Arg0, 0x19, IRQW)
                    CreateByteField(Arg0, 0x1c, DMAV)
                    ENFG()
                    Store(Zero, LDN)
                    Store(One, ACTR)
                    SLDM(DMCH, DMCH)
                    CKIO(IOAD, 0x03)
                    EXFG()
                }
            }
            Device(UAR1) {
                Name(_HID, 0x0105d041)
                Name(_UID, 0x01)
                Method(_STA) {
                    ENFG()
                    Store(0x01, LDN)
                    If(ACTR) {
                        EXFG()
                        Return(0x0f)
                    }
                    Else {
                        If(LOr(IOAH, IOAL)) {
                            EXFG()
                            Return(0x0d)
                        }
                        Else {
                            EXFG()
                            Return(0x00)
                        }
                    }
                    EXFG()
                }
                Method(_DIS) {
                    ENFG()
                    Store(0x01, LDN)
                    Store(Zero, ACTR)
                    EXFG()
                    DISD(0x00)
                }
                Method(_CRS) {
                    Name(BUF1, Buffer(0x0d) {0x47, 0x1, 0x0, 0x0, 0x0, 0x0, 
0x1, 0x8, 0x22, 0x0, 0x0, 0x79, 0x0
                    /* ResourceTemplate() {
                     0x0000  IO(Decode16, 0x0, 0x0, 0x1, 0x8)
                     0x0008  IRQ()
                    } */
                     })
                    CreateByteField(BUF1, 0x02, IOLO)
                    CreateByteField(BUF1, 0x03, IOHI)
                    CreateByteField(BUF1, 0x04, IORL)
                    CreateByteField(BUF1, 0x05, IORH)
                    CreateWordField(BUF1, 0x09, IRQW)
                    ENFG()
                    Store(0x01, LDN)
                    Store(IOAL, IOLO)
                    Store(IOAL, IORL)
                    Store(IOAH, IOHI)
                    Store(IOAH, IORH)
                    Store(One, Local0)
                    ShiftLeft(Local0, INTR, IRQW)
                    EXFG()
                    Return(BUF1)
                }
                Name(_PRS, Buffer(0x33) {0x30, 0x47, 0x1, 0xf8, 0x3, 0xf8, 0x3, 
0x1, 0x8, 0x22, 0xb8, 0x1e, 0x30, 0x47, 0x1, 0xf8, 0x2, 0xf8, 0x2, 0x1, 0x8, 
0x22, 0xb8, 0x1e, 0x30, 0x47, 0x1, 0xe8, 0x3, 0xe8, 0x3, 0x1, 0x8, 0x22, 0xb8, 
0x1e, 0x30, 0x47, 0x1, 0xe8, 0x2, 0xe8, 0x2, 0x1, 0x8, 0x22, 0xb8, 0x1e, 0x38, 
0x79, 0x0
                /* ResourceTemplate() {
                    StartDependentFn() {
                     0x0001  IO(Decode16, 0x3f8, 0x3f8, 0x1, 0x8)
                     0x0009  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                    }
                    StartDependentFn() {
                     0x000d  IO(Decode16, 0x2f8, 0x2f8, 0x1, 0x8)
                     0x0015  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                    }
                    StartDependentFn() {
                     0x0019  IO(Decode16, 0x3e8, 0x3e8, 0x1, 0x8)
                     0x0021  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                    }
                    StartDependentFn() {
                     0x0025  IO(Decode16, 0x2e8, 0x2e8, 0x1, 0x8)
                     0x002d  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                    }
                    EndDependentFn() {}
                } */
                 })
                Method(_SRS, 1) {
                    CreateByteField(Arg0, 0x02, IOLO)
                    CreateByteField(Arg0, 0x03, IOHI)
                    CreateWordField(Arg0, 0x02, IOAD)
                    CreateWordField(Arg0, 0x09, IRQW)
                    ENFG()
                    Store(0x01, LDN)
                    Store(One, ACTR)
                    Store(IOLO, IOAL)
                    Store(IOHI, IOAH)
                    FindSetRightBit(IRQW, Local0)
                    Subtract(Local0, 0x01, INTR)
                    EXFG()
                    CKIO(IOAD, 0x00)
                }
            }
            Device(UAR2) {
                Method(_HID) {
                    ENFG()
                    Store(0x02, LDN)
                    And(OPT1, 0x70, Local0)
                    If(LEqual(Local0, 0x40)) {
                        Return(0x05878526)
                    }
                    Else {
                        Return(0x0105d041)
                    }
                    EXFG()
                }
                Name(_UID, 0x02)
                Method(_STA) {
                    ENFG()
                    Store(0x02, LDN)
                    And(OPT1, 0x70, Local0)
                    If(LNot(LEqual(Local0, 0x10))) {
                        If(ACTR) {
                            EXFG()
                            Return(0x0f)
                        }
                        Else {
                            If(LOr(IOAH, IOAL)) {
                                EXFG()
                                Return(0x0d)
                            }
                            Else {
                                EXFG()
                                Return(0x00)
                            }
                        }
                    }
                    Else {
                        EXFG()
                        Return(0x00)
                    }
                }
                Method(_DIS) {
                    ENFG()
                    Store(0x02, LDN)
                    Store(Zero, ACTR)
                    EXFG()
                    DISD(0x01)
                }
                Method(_CRS) {
                    Name(BUF2, Buffer(0x0d) {0x47, 0x1, 0x0, 0x0, 0x0, 0x0, 
0x1, 0x8, 0x22, 0x10, 0x0, 0x79, 0x0
                    /* ResourceTemplate() {
                     0x0000  IO(Decode16, 0x0, 0x0, 0x1, 0x8)
                     0x0008  IRQ() {4}
                    } */
                     })
                    CreateByteField(BUF2, 0x02, IOLO)
                    CreateByteField(BUF2, 0x03, IOHI)
                    CreateByteField(BUF2, 0x04, IORL)
                    CreateByteField(BUF2, 0x05, IORH)
                    CreateWordField(BUF2, 0x09, IRQW)
                    ENFG()
                    Store(0x02, LDN)
                    Store(IOAL, IOLO)
                    Store(IOAL, IORL)
                    Store(IOAH, IOHI)
                    Store(IOAH, IORH)
                    Store(One, Local0)
                    ShiftLeft(Local0, INTR, IRQW)
                    EXFG()
                    Return(BUF2)
                }
                Name(_PRS, Buffer(0x33) {0x30, 0x47, 0x1, 0xf8, 0x3, 0xf8, 0x3, 
0x1, 0x8, 0x22, 0xb8, 0x1e, 0x30, 0x47, 0x1, 0xf8, 0x2, 0xf8, 0x2, 0x1, 0x8, 
0x22, 0xb8, 0x1e, 0x30, 0x47, 0x1, 0xe8, 0x3, 0xe8, 0x3, 0x1, 0x8, 0x22, 0xb8, 
0x1e, 0x30, 0x47, 0x1, 0xe8, 0x2, 0xe8, 0x2, 0x1, 0x8, 0x22, 0xb8, 0x1e, 0x38, 
0x79, 0x0
                /* ResourceTemplate() {
                    StartDependentFn() {
                     0x0001  IO(Decode16, 0x3f8, 0x3f8, 0x1, 0x8)
                     0x0009  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                    }
                    StartDependentFn() {
                     0x000d  IO(Decode16, 0x2f8, 0x2f8, 0x1, 0x8)
                     0x0015  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                    }
                    StartDependentFn() {
                     0x0019  IO(Decode16, 0x3e8, 0x3e8, 0x1, 0x8)
                     0x0021  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                    }
                    StartDependentFn() {
                     0x0025  IO(Decode16, 0x2e8, 0x2e8, 0x1, 0x8)
                     0x002d  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                    }
                    EndDependentFn() {}
                } */
                 })
                Method(_SRS, 1) {
                    CreateByteField(Arg0, 0x02, IOLO)
                    CreateByteField(Arg0, 0x03, IOHI)
                    CreateWordField(Arg0, 0x02, IOAD)
                    CreateWordField(Arg0, 0x09, IRQW)
                    ENFG()
                    Store(0x02, LDN)
                    Store(One, ACTR)
                    Store(IOLO, IOAL)
                    Store(IOHI, IOAH)
                    FindSetRightBit(IRQW, Local0)
                    Subtract(Local0, 0x01, INTR)
                    EXFG()
                    CKIO(IOAD, 0x01)
                }
            }
            Method(\_SB.PCI0.LEG0.UAR2._PRW) {
                Return(Package(0x02) {
                    0x03,
                    0x05,
                })
            }
            Device(LPT1) {
                Name(_HID, 0x0004d041)
                Name(_UID, 0x01)
                Method(_STA) {
                    ENFG()
                    Store(0x03, LDN)
                    And(OPT1, 0x02, Local0)
                    If(LNot(LEqual(Local0, 0x02))) {
                        If(ACTR) {
                            EXFG()
                            Return(0x0f)
                        }
                        Else {
                            If(LOr(IOAH, IOAL)) {
                                EXFG()
                                Return(0x0d)
                            }
                            Else {
                                EXFG()
                                Return(0x00)
                            }
                        }
                    }
                    Else {
                        EXFG()
                        Return(0x00)
                    }
                }
                Method(_DIS) {
                    ENFG()
                    Store(0x03, LDN)
                    Store(Zero, ACTR)
                    EXFG()
                    DISD(0x02)
                }
                Method(_CRS) {
                    Name(BUF5, Buffer(0x0d) {0x47, 0x1, 0x0, 0x0, 0x0, 0x0, 
0x1, 0x8, 0x22, 0x0, 0x0, 0x79, 0x0
                    /* ResourceTemplate() {
                     0x0000  IO(Decode16, 0x0, 0x0, 0x1, 0x8)
                     0x0008  IRQ()
                    } */
                     })
                    CreateByteField(BUF5, 0x02, IOLO)
                    CreateByteField(BUF5, 0x03, IOHI)
                    CreateByteField(BUF5, 0x04, IORL)
                    CreateByteField(BUF5, 0x05, IORH)
                    CreateByteField(BUF5, 0x07, IOLE)
                    CreateWordField(BUF5, 0x09, IRQW)
                    ENFG()
                    Store(0x03, LDN)
                    Store(IOAL, IOLO)
                    Store(IOLO, IORL)
                    Store(IOAH, IOHI)
                    Store(IOHI, IORH)
                    If(LEqual(IOLO, 0xbc)) {
                        Store(0x04, IOLE)
                    }
                    Else {
                        Store(0x08, IOLE)
                    }
                    Store(One, Local0)
                    Store(INTR, Local5)
                    ShiftLeft(Local0, Local5, IRQW)
                    EXFG()
                    Return(BUF5)
                }
                Name(_PRS, Buffer(0x27) {0x30, 0x47, 0x1, 0x78, 0x3, 0x78, 0x3, 
0x1, 0x8, 0x22, 0xb8, 0x1e, 0x30, 0x47, 0x1, 0x78, 0x2, 0x78, 0x2, 0x1, 0x8, 
0x22, 0xb8, 0x1e, 0x30, 0x47, 0x1, 0xbc, 0x3, 0xbc, 0x3, 0x1, 0x4, 0x22, 0xb8, 
0x1e, 0x38, 0x79, 0x0
                /* ResourceTemplate() {
                    StartDependentFn() {
                     0x0001  IO(Decode16, 0x378, 0x378, 0x1, 0x8)
                     0x0009  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                    }
                    StartDependentFn() {
                     0x000d  IO(Decode16, 0x278, 0x278, 0x1, 0x8)
                     0x0015  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                    }
                    StartDependentFn() {
                     0x0019  IO(Decode16, 0x3bc, 0x3bc, 0x1, 0x4)
                     0x0021  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                    }
                    EndDependentFn() {}
                } */
                 })
                Method(_SRS, 1) {
                    CreateByteField(Arg0, 0x02, IOLO)
                    CreateByteField(Arg0, 0x03, IOHI)
                    CreateWordField(Arg0, 0x02, IOAD)
                    CreateByteField(Arg0, 0x04, IORL)
                    CreateByteField(Arg0, 0x05, IORH)
                    CreateWordField(Arg0, 0x09, IRQW)
                    ENFG()
                    Store(0x03, LDN)
                    Store(One, ACTR)
                    Store(IOLO, IOAL)
                    Store(IOHI, IOAH)
                    FindSetLeftBit(IRQW, Local0)
                    Subtract(Local0, 0x01, Local0)
                    Store(Local0, INTR)
                    EXFG()
                    CKIO(IOAD, 0x02)
                }
            }
            Device(ECP1) {
                Name(_HID, 0x0104d041)
                Name(_UID, 0x01)
                Method(_STA) {
                    ENFG()
                    Store(0x03, LDN)
                    And(OPT1, 0x02, Local0)
                    If(LEqual(Local0, 0x02)) {
                        If(ACTR) {
                            EXFG()
                            Return(0x0f)
                        }
                        Else {
                            If(LOr(IOAH, IOAL)) {
                                EXFG()
                                Return(0x0d)
                            }
                            Else {
                                EXFG()
                                Return(0x00)
                            }
                        }
                    }
                    Else {
                        EXFG()
                        Return(0x00)
                    }
                }
                Method(_DIS) {
                    ENFG()
                    Store(0x03, LDN)
                    Store(Zero, ACTR)
                    SLDM(DMCH, 0x04)
                    EXFG()
                    DISD(0x02)
                }
                Method(_CRS) {
                    Name(BUF6, Buffer(0x18) {0x47, 0x1, 0x0, 0x0, 0x0, 0x0, 
0x1, 0x4, 0x47, 0x1, 0x0, 0x0, 0x0, 0x0, 0x1, 0x4, 0x22, 0x0, 0x0, 0x2a, 0x0, 
0x0, 0x79, 0x0
                    /* ResourceTemplate() {
                     0x0000  IO(Decode16, 0x0, 0x0, 0x1, 0x4)
                     0x0008  IO(Decode16, 0x0, 0x0, 0x1, 0x4)
                     0x0010  IRQ()
                     0x0013  DMA(Compatibility, NotBusMaster, Transfer8)
                    } */
                     })
                    CreateByteField(BUF6, 0x02, IOLO)
                    CreateByteField(BUF6, 0x03, IOHI)
                    CreateByteField(BUF6, 0x04, IORL)
                    CreateByteField(BUF6, 0x05, IORH)
                    CreateByteField(BUF6, 0x07, IOLE)
                    CreateByteField(BUF6, 0x0a, IOEL)
                    CreateByteField(BUF6, 0x0b, IOEH)
                    CreateByteField(BUF6, 0x0c, IOML)
                    CreateByteField(BUF6, 0x0d, IOMH)
                    CreateWordField(BUF6, 0x11, IRQW)
                    CreateByteField(BUF6, 0x14, DMAC)
                    ENFG()
                    Store(0x03, LDN)
                    Store(IOAL, Local2)
                    Store(Local2, IOLO)
                    Store(IOAH, Local3)
                    Store(Local3, IOHI)
                    Or(Local3, 0x04, Local3)
                    Store(Local3, IOEH)
                    Store(Local3, IOMH)
                    Store(IOLO, IORL)
                    Store(IOLO, IOEL)
                    Store(IOLO, IOML)
                    Store(IOHI, IORH)
                    If(LEqual(IOLO, 0xbc)) {
                        Store(0x04, IOLE)
                    }
                    Else {
                        Store(0x08, IOLE)
                    }
                    Store(One, Local0)
                    Store(INTR, Local5)
                    ShiftLeft(Local0, Local5, IRQW)
                    Store(One, Local0)
                    Store(DMCH, Local5)
                    ShiftLeft(Local0, Local5, DMAC)
                    EXFG()
                    Return(BUF6)
                }
                Name(_PRS, Buffer(0x48) {0x30, 0x47, 0x1, 0x78, 0x3, 0x78, 0x3, 
0x0, 0x8, 0x47, 0x1, 0x78, 0x7, 0x78, 0x7, 0x0, 0x4, 0x22, 0xb8, 0x1e, 0x2a, 
0xb, 0x0, 0x30, 0x47, 0x1, 0x78, 0x2, 0x78, 0x2, 0x0, 0x8, 0x47, 0x1, 0x78, 
0x6, 0x78, 0x6, 0x0, 0x4, 0x22, 0xb8, 0x1e, 0x2a, 0xb, 0x0, 0x30, 0x47, 0x1, 
0xbc, 0x3, 0xbc, 0x3, 0x0, 0x4, 0x47, 0x1, 0xbc, 0x7, 0xbc, 0x7, 0x0, 0x4, 
0x22, 0xb8, 0x1e, 0x2a, 0xb, 0x0, 0x38, 0x79, 0x0
                /* ResourceTemplate() {
                    StartDependentFn() {
                     0x0001  IO(Decode16, 0x378, 0x378, 0x0, 0x8)
                     0x0009  IO(Decode16, 0x778, 0x778, 0x0, 0x4)
                     0x0011  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                     0x0014  DMA(Compatibility, NotBusMaster, Transfer8) {0, 1, 
3}
                    }
                    StartDependentFn() {
                     0x0018  IO(Decode16, 0x278, 0x278, 0x0, 0x8)
                     0x0020  IO(Decode16, 0x678, 0x678, 0x0, 0x4)
                     0x0028  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                     0x002b  DMA(Compatibility, NotBusMaster, Transfer8) {0, 1, 
3}
                    }
                    StartDependentFn() {
                     0x002f  IO(Decode16, 0x3bc, 0x3bc, 0x0, 0x4)
                     0x0037  IO(Decode16, 0x7bc, 0x7bc, 0x0, 0x4)
                     0x003f  IRQ() {3, 4, 5, 7, 9, 10, 11, 12}
                     0x0042  DMA(Compatibility, NotBusMaster, Transfer8) {0, 1, 
3}
                    }
                    EndDependentFn() {}
                } */
                 })
                Method(_SRS, 1) {
                    CreateByteField(Arg0, 0x02, IOLO)
                    CreateByteField(Arg0, 0x03, IOHI)
                    CreateWordField(Arg0, 0x02, IOAD)
                    CreateWordField(Arg0, 0x11, IRQW)
                    CreateByteField(Arg0, 0x14, DMAC)
                    ENFG()
                    Store(0x03, LDN)
                    Store(One, ACTR)
                    Store(IOLO, IOAL)
                    Store(IOHI, IOAH)
                    FindSetLeftBit(IRQW, Local0)
                    Subtract(Local0, 0x01, Local0)
                    Store(Local0, INTR)
                    FindSetLeftBit(DMAC, Local1)
                    Store(DMCH, Local0)
                    Subtract(Local1, 0x01, DMCH)
                    SLDM(Local0, DMCH)
                    EXFG()
                    CKIO(IOAD, 0x02)
                }
            }
            OperationRegion(KBCT, SystemIO, 0x60, 0x05)
            Field(KBCT, ByteAcc, NoLock, Preserve) {
                P060,   8,
                Offset(0x4),
                P064,   8
            }
            Device(PS2M) {
                Name(_HID, 0x130fd041)
                Method(_STA) {
                    If(LEqual(PS2F, 0x00)) {
                        Return(0x0f)
                    }
                    Else {
                        Return(0x00)
                    }
                }
                Method(_CRS) {
                    Name(BUF1, Buffer(0x05) {0x22, 0x0, 0x10, 0x79, 0x0
                    /* ResourceTemplate() {
                     0x0000  IRQ() {12}
                    } */
                     })
                    Name(BUF2, Buffer(0x15) {0x47, 0x1, 0x60, 0x0, 0x60, 0x0, 
0x1, 0x1, 0x47, 0x1, 0x64, 0x0, 0x64, 0x0, 0x1, 0x1, 0x22, 0x0, 0x10, 0x79, 0x0
                    /* ResourceTemplate() {
                     0x0000  IO(Decode16, 0x60, 0x60, 0x1, 0x1)
                     0x0008  IO(Decode16, 0x64, 0x64, 0x1, 0x1)
                     0x0010  IRQ() {12}
                    } */
                     })
                    If(LEqual(KBDI, 0x01)) {
                        If(LEqual(OSFL, 0x02)) {
                            Return(BUF1)
                        }
                        If(LEqual(OSFL, 0x01)) {
                            Return(BUF1)
                        }
                        Else {
                            Return(BUF2)
                        }
                    }
                    Else {
                        Return(BUF1)
                    }
                }
            }
            Device(PS2K) {
                Name(_HID, 0x0303d041)
                Name(_CID, 0x0b03d041)
                Method(_STA) {
                    If(LEqual(KBDI, 0x01)) {
                        Return(0x00)
                    }
                    Else {
                        Return(0x0f)
                    }
                }
                Name(_CRS, Buffer(0x15) {0x47, 0x1, 0x60, 0x0, 0x60, 0x0, 0x1, 
0x1, 0x47, 0x1, 0x64, 0x0, 0x64, 0x0, 0x1, 0x1, 0x22, 0x2, 0x0, 0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  IO(Decode16, 0x60, 0x60, 0x1, 0x1)
                 0x0008  IO(Decode16, 0x64, 0x64, 0x1, 0x1)
                 0x0010  IRQ() {1}
                } */
                 })
            }
            Device(PSMR) {
                Name(_HID, 0x020cd041)
                Name(_UID, 0x03)
                Method(_STA) {
                    If(LEqual(KBDI, 0x00)) {
                        Return(0x00)
                    }
                    If(LEqual(PS2F, 0x00)) {
                        If(LEqual(OSFL, 0x02)) {
                            Return(0x0f)
                        }
                        If(LEqual(OSFL, 0x01)) {
                            Return(0x0f)
                        }
                        Return(0x00)
                    }
                    Return(0x00)
                }
                Name(_CRS, Buffer(0x12) {0x47, 0x1, 0x60, 0x0, 0x60, 0x0, 0x1, 
0x1, 0x47, 0x1, 0x64, 0x0, 0x64, 0x0, 0x1, 0x1, 0x79, 0x0
                /* ResourceTemplate() {
                 0x0000  IO(Decode16, 0x60, 0x60, 0x1, 0x1)
                 0x0008  IO(Decode16, 0x64, 0x64, 0x1, 0x1)
                } */
                 })
            }
            Method(PS2W) {
                ENFG()
                Store(GSRG(0x07), Local0)
                SSRG(0x07, 0x04)
                Store(GSRG(0xf1), Local1)
                If(And(Local1, 0x10, )) {
                    Notify(\_SB.PCI0.LEG0.PS2M, 0x02)
                }
                If(And(Local1, 0x08, )) {
                    Notify(\_SB.PCI0.LEG0.PS2K, 0x02)
                }
                SSRG(0xf1, 0xff)
                SSRG(0x07, Local0)
                EXFG()
            }
            Method(\_SB.PCI0.LEG0.PS2M._PSW, 1) {
                If(Arg0) {
                    Or(WAKF, 0x02, WAKF)
                }
                Else {
                    And(WAKF, Not(0x02, ), WAKF)
                }
            }
            Method(\_SB.PCI0.LEG0.PS2K._PSW, 1) {
                If(Arg0) {
                    Or(WAKF, 0x01, WAKF)
                }
                Else {
                    And(WAKF, Not(0x01, ), WAKF)
                }
            }
            Method(\_SB.PCI0.LEG0.UAR1._PRW) {
                Return(Package(0x02) {
                    0x03,
                    0x05,
                })
            }
            Method(\_SB.PCI0.LEG0.PS2K._PRW) {
                Return(Package(0x02) {
                    0x10,
                    0x04,
                })
            }
            Method(\_SB.PCI0.LEG0.PS2M._PRW) {
                Return(Package(0x02) {
                    0x10,
                    0x04,
                })
            }
            OperationRegion(PIO1, PCI_Config, 0x74, 0x01)
            Scope(\) {
                Field(\_SB.PCI0.LEG0.PIO1, ByteAcc, NoLock, Preserve) {
                    ,   2,
                    HPTF,       1,
                    Offset(0x1)
                }
            }
            OperationRegion(PIRQ, PCI_Config, 0x7c, 0x0c)
            Scope(\) {
                Field(\_SB.PCI0.LEG0.PIRQ, AnyAcc, NoLock, Preserve) {
                    INTA,       4,
                    INTB,       4,
                    INTC,       4,
                    INTD,       4,
                    PCEA,       4,
                    PCEB,       4,
                    PCEC,       4,
                    PCED,       4,
                    SCII,       4,
                    TCOI,       4,
                    INTF,       4,
                    INTQ,       4,
                    INTU,       4,
                    INTS,       4,
                    IS0P,       4,
                    ITID,       4,
                    INTG,       4,
                    INTH,       4,
                    INTJ,       4,
                    INTK,       4,
                    INTL,       4,
                    INTM,       4,
                    INTN,       4,
                    ISA2,       4
                }
            }
            OperationRegion(LPIO, PCI_Config, 0xa0, 0x18)
            Scope(\) {
                Field(\_SB.PCI0.LEG0.LPIO, ByteAcc, NoLock, Preserve) {
                    UAIO,       8,
                    SNDD,       4,
                    MIDD,       4,
                    MSSD,       4,
                    FDCD,       2,
                    Offset(0x3),
                    PRIO,       3,
                    ,   1,
                    GEN1,       1,
                    GEN2,       1,
                    GEN3,       1,
                    GEN4,       1,
                    GAM1,       8,
                    GAM2,       8
                }
                OperationRegion(RTC2, SystemIO, 0x72, 0x02)
                Field(RTC2, ByteAcc, NoLock, Preserve) {
                    CM2I,       8,
                    CM2D,       8
                }
                IndexField(CM2I, CM2D, ByteAcc, NoLock, Preserve) {
                    Offset(0xcc),
                    UA1D,       8
                }
                Name(UARA, 0x00)
                Name(UARB, 0x00)
                Method(DISD, 1) {
                    If(LEqual(Arg0, 0x00)) {
                        Store(UARA, Local0)
                        XOr(Local0, 0xff, Local0)
                        And(UAIO, Local0, UAIO)
                    }
                    If(LEqual(Arg0, 0x01)) {
                        Store(UARB, Local0)
                        XOr(Local0, 0xff, Local0)
                        And(UAIO, Local0, UAIO)
                    }
                    If(LEqual(Arg0, 0x02)) {
                        Store(0x00, PRIO)
                    }
                    If(LEqual(Arg0, 0x03)) {
                        Store(0x00, FDCD)
                    }
                    If(LEqual(Arg0, 0x04)) {
                        Store(0x00, GAM1)
                        Store(0x00, GAM2)
                    }
                    If(LEqual(Arg0, 0x05)) {
                        Store(0x00, MIDD)
                    }
                }
                Method(CKIO, 2) {
                    If(LEqual(Arg1, 0x00)) {
                        Or(UARA, UARB, Local0)
                        And(UAIO, Local0, UAIO)
                        Store(UARA, Local0)
                        XOr(Local0, 0xff, Local0)
                        And(UAIO, Local0, UAIO)
                        If(LEqual(Arg0, 0x03f8)) {
                            Store(0x01, Local0)
                        }
                        If(LEqual(Arg0, 0x02f8)) {
                            Store(0x02, Local0)
                        }
                        If(LEqual(Arg0, 0x02e8)) {
                            Store(0x20, Local0)
                        }
                        If(LEqual(Arg0, 0x03e8)) {
                            Store(0x80, Local0)
                        }
                        Or(UAIO, Local0, UAIO)
                        Store(Local0, UARA)
                    }
                    If(LEqual(Arg1, 0x01)) {
                        Or(UARA, UARB, Local0)
                        And(UAIO, Local0, UAIO)
                        Store(UARB, Local0)
                        XOr(Local0, 0xff, Local0)
                        And(UAIO, Local0, UAIO)
                        If(LEqual(Arg0, 0x03f8)) {
                            Store(0x01, Local0)
                        }
                        If(LEqual(Arg0, 0x02f8)) {
                            Store(0x02, Local0)
                        }
                        If(LEqual(Arg0, 0x02e8)) {
                            Store(0x20, Local0)
                        }
                        If(LEqual(Arg0, 0x03e8)) {
                            Store(0x80, Local0)
                        }
                        Or(UAIO, Local0, UAIO)
                        Store(Local0, UARB)
                    }
                    If(LEqual(Arg1, 0x02)) {
                        If(LEqual(Arg0, 0x0378)) {
                            Store(0x00, PRIO)
                            Or(PRIO, 0x01, PRIO)
                        }
                        If(LEqual(Arg0, 0x0278)) {
                            Store(0x00, PRIO)
                            Or(PRIO, 0x02, PRIO)
                        }
                        If(LEqual(Arg0, 0x03bc)) {
                            Store(0x00, PRIO)
                            Or(PRIO, 0x04, PRIO)
                        }
                    }
                    If(LEqual(Arg1, 0x03)) {
                        Or(FDCD, 0x01, FDCD)
                    }
                    If(LEqual(Arg1, 0x04)) {
                        Store(0x00, GAM1)
                        Store(0x00, GAM2)
                        If(LEqual(Arg0, 0x0201)) {
                            Or(GAM1, 0x02, GAM1)
                        }
                        If(LEqual(Arg0, 0x0209)) {
                            Or(GAM2, 0x02, GAM2)
                        }
                    }
                    If(LEqual(Arg1, 0x05)) {
                        Store(0x00, MIDD)
                        If(LEqual(Arg0, 0x0300)) {
                            Or(MIDD, 0x01, MIDD)
                        }
                        If(LEqual(Arg0, 0x0330)) {
                            Or(MIDD, 0x08, MIDD)
                        }
                    }
                }
                Method(SLDM, 2) {
                }
                Method(CLSU, 1) {
                    CreateWordField(Arg0, 0x02, UARO)
                    If(LEqual(UARO, 0x03f8)) {
                        And(UAIO, 0xfe, UAIO)
                    }
                    If(LEqual(UARO, 0x02f8)) {
                        And(UAIO, 0xfd, UAIO)
                    }
                    If(LEqual(UARO, 0x02e8)) {
                        And(UAIO, 0xbf, UAIO)
                    }
                    If(LEqual(UARO, 0x03e8)) {
                        And(UAIO, 0x7f, UAIO)
                    }
                }
            }
        }
        Device(USB0) {
            Name(_ADR, 0x00020000)
            Method(_S1D) {
                Return(0x01)
            }
            Method(_S3D) {
                If(LEqual(OSFL, 0x02)) {
                    Return(0x02)
                }
                Else {
                    Return(0x03)
                }
            }
            Name(_PRW, Package(0x02) {
                0x0d,
                0x04,
            })
        }
        Device(USB2) {
            Name(_ADR, 0x00020001)
            OperationRegion(P020, PCI_Config, 0x49, 0x01)
            Field(P020, AnyAcc, NoLock, Preserve) {
                U0WK,   1
            }
            Method(_PSW, 1) {
                If(Arg0) {
                    Store(0x01, U0WK)
                }
                Else {
                    Store(0x00, U0WK)
                }
            }
            Method(_S1D) {
                Return(0x01)
            }
            Method(_S3D) {
                Return(0x01)
            }
            Name(_PRW, Package(0x02) {
                0x05,
                0x04,
            })
        }
        Device(AZAD) {
            Name(_ADR, 0x00060001)
            Name(_PRW, Package(0x02) {
                0x15,
                0x05,
            })
        }
        Device(MMAC) {
            Name(_ADR, 0x00080000)
            Name(_PRW, Package(0x02) {
                0x0b,
                0x05,
            })
        }
        Device(NVRB) {
            Name(_HID, "NVRAIDBUS")
            OperationRegion(NVRD, SystemMemory, 0x000fff38, 0x03)
            Field(NVRD, ByteAcc, NoLock, Preserve) {
                R_ST,   1,
                ,       3,
                R_P0,   4,
                R_S0,   4,
                R_S1,   4,
                R_S2,   4
            }
            Name(FNVR, 0xff)
            Method(_DIS) {
                Store(0x00, FNVR)
            }
            Method(_STA) {
                If(LEqual(R_ST, 0x01)) {
                    If(LEqual(FNVR, 0xff)) {
                        Return(0x0f)
                    }
                    Else {
                        Return(0x0d)
                    }
                }
                Else {
                    Return(0x00)
                }
            }
            Name(_CRS, Buffer(0x0a) {0x47, 0x1, 0xd2, 0x4, 0xd2, 0x4, 0x1, 0x1, 
0x79, 0x0
            /* ResourceTemplate() {
             0x0000  IO(Decode16, 0x4d2, 0x4d2, 0x1, 0x1)
            } */
             })
            Method(_SRS, 1) {
                Store(0xff, FNVR)
            }
        }
        OperationRegion(SM00, SystemIO, \_SB.PCI0.SMB0.SMBB, 0x06)
        Field(SM00, ByteAcc, NoLock, Preserve) {
            CTLR,       8,
            HSTS,       8,
            ADDR,       8,
            CMDR,       8,
            DAT0,       8,
            DAT1,       8
        }
        OperationRegion(SM01, SystemIO, 0x1c40, 0x06)
        Field(SM01, ByteAcc, NoLock, Preserve) {
            CTL2,       8,
            HST2,       8,
            ADD2,       8,
            CMD2,       8,
            DAT2,       8,
            DAT3,       8
        }
        Method(SWF2) {
            And(HST2, 0x80, Local0)
            While(LEqual(Local0, Zero)) {
                Stall(0x01)
                And(HST2, 0x80, Local0)
            }
        }
        Method(SWFS) {
            And(HSTS, 0x80, Local0)
            While(LEqual(Local0, Zero)) {
                Stall(0x01)
                And(HSTS, 0x80, Local0)
            }
        }
        Method(SRBY, 2) {
            Store(Arg0, ADDR)
            Store(Arg1, CMDR)
            Store(0x04, CTLR)
            SWFS()
        }
        Method(WBYT, 3) {
            Store(Arg0, ADDR)
            Store(Arg1, CMDR)
            Store(Arg2, DAT0)
            Store(0x06, CTLR)
            SWFS()
        }
        Method(SMWW, 4) {
            Store(Arg0, ADDR)
            Store(Arg1, CMDR)
            Store(Arg2, DAT0)
            Store(Arg3, DAT1)
            Store(0x08, CTLR)
            SWFS()
        }
        Method(RBY2, 2) {
            Store(Arg0, ADD2)
            Store(Arg1, CMD2)
            Store(0x07, CTL2)
            SWF2()
            Return(DAT2)
        }
        Method(RBYT, 2) {
            Store(Arg0, ADDR)
            Store(Arg1, CMDR)
            Store(0x07, CTLR)
            SWFS()
            Return(DAT0)
        }
        Method(WBY2, 3) {
            Store(Arg0, ADD2)
            Store(Arg1, CMD2)
            Store(Arg2, DAT2)
            Store(0x06, CTL2)
            SWF2()
        }
        Method(SMRW, 2) {
            Store(Arg0, ADDR)
            Store(Arg1, CMDR)
            Store(0x09, CTLR)
            SWFS()
            Store(DAT0, Local0)
            ShiftLeft(DAT1, 0x08, Local1)
            Or(Local0, Local1, Local2)
            Return(Local2)
        }
        Device(ASOC) {
            Name(_HID, "ATK0110")
            Name(_UID, 0x01010110)
            Name(MBIF, Package(0x08) {
                0x01,
                "M2N\x2dE\x20",
                0x01010101,
                0x01010101,
                0xc0010002,
                0x01,
                0x00,
                0x00,
            })
            Name(VBUF, Package(0x05) {
                0x04,
                VCRE,
                V333,
                V500,
                V120,
            })
            Name(VCRE, Package(0x05) {
                0x06020000,
                "Vcore\x20Voltage",
                0x05aa,
                0x06d6,
                0x01,
            })
            Name(V333, Package(0x05) {
                0x06020001,
                "\x20\x2b3.3\x20Voltage",
                0x0bb8,
                0x0e10,
                0x01,
            })
            Name(V500, Package(0x05) {
                0x06020002,
                "\x20\x2b5.0\x20Voltage",
                0x1194,
                0x157c,
                0x01,
            })
            Name(V120, Package(0x05) {
                0x06020003,
                "\x2b12.0\x20Voltage",
                0x2bc0,
                0x3390,
                0x01,
            })
            Name(TBUF, Package(0x03) {
                0x02,
                CPUT,
                MBTP,
            })
            Name(CPUT, Package(0x05) {
                0x06030000,
                "CPU\x20Temperature",
                0x0384,
                0x04e2,
                0x00010001,
            })
            Name(MBTP, Package(0x05) {
                0x06030001,
                "MB\x20Temperature",
                0x01c2,
                0x0384,
                0x00010001,
            })
            Name(FBUF, Package(0x07) {
                0x06,
                CPUF,
                CHAF,
                PWRF,
                SF01,
                SF02,
                SF03,
            })
            Name(CPUF, Package(0x05) {
                0x06040000,
                "CPU\x20FAN\x20Speed",
                0x00,
                0x0708,
                0x00010001,
            })
            Name(CHAF, Package(0x05) {
                0x06040001,
                "CHASSIS\x20FAN\x20Speed",
                0x00,
                0x0708,
                0x01,
            })
            Name(PWRF, Package(0x05) {
                0x06040002,
                "POWER\x20FAN\x20Speed",
                0x00,
                0x0708,
                0x01,
            })
            Name(CHPF, Package(0x05) {
                0x06040005,
                "CHIPSET\x20FAN\x20Speed",
                0x00,
                0x0708,
                0x00,
            })
            Name(CH2F, Package(0x05) {
                0x06040006,
                "CHASSIS2\x20FAN\x20Speed",
                0x00,
                0x0708,
                0x00,
            })
            Name(SF01, Package(0x05) {
                0x06040021,
                "CHASSIS4\x20FAN\x20FAN\x20Speed",
                0x00,
                0x0708,
                0x01,
            })
            Name(SF02, Package(0x05) {
                0x06040022,
                "CHASSIS2\x20FAN\x20FAN\x20Speed",
                0x00,
                0x0708,
                0x01,
            })
            Name(SF03, Package(0x05) {
                0x06040023,
                "CHASSIS3\x20FAN\x20FAN\x20Speed",
                0x00,
                0x0708,
                0x01,
            })
            Name(QFAN, Package(0x05) {
                0x04060003,
                "CPU\x20Q\x2dFan\x20Control",
                0x00,
                0x01,
                0x01,
            })
            Name(QFRO, Package(0x05) {
                0x04050004,
                "CPU\x20Q\x2dFan\x20Ratio",
                0x3c,
                0x5a,
                0x00,
            })
            Name(QCFN, Package(0x05) {
                0x04060006,
                "Chassis\x20Q\x2dFan\x20Control",
                0x00,
                0x01,
                0x00,
            })
            Name(QFCR, Package(0x05) {
                0x04050007,
                "Chassis\x20Q\x2dFan\x20Ratio",
                0x38,
                0x64,
                0x00,
            })
            OperationRegion(HWRE, SystemIO, 0x0295, 0x02)
            Field(HWRE, ByteAcc, NoLock, Preserve) {
                HIDX,   8,
                HDAT,   8
            }
            IndexField(HIDX, HDAT, ByteAcc, NoLock, Preserve) {
                Offset(0xb),
                FD11,   3,
                FD12,   3,
                FD13,   1,
                Offset(0xc),
                Offset(0xd),
                FAN1,   8,
                FAN2,   8,
                FAN3,   8,
                Offset(0x18),
                FEN1,   8,
                FEN2,   8,
                FEN3,   8,
                Offset(0x20),
                VCOR,   8,
                V33V,   8,
                Offset(0x23),
                V50V,   8,
                V12V,   8,
                Offset(0x29),
                TSR1,   8,
                MBTE,   8
            }
            Method(ASIF) {
                Return(MBIF)
            }
            Method(VSIF) {
                Return(VBUF)
            }
            Method(RVLT, 1) {
                Store(DerefOf(Index(VCRE, 0x00, )), Local0)
                If(LEqual(Arg0, Local0)) {
                    Store(VCOR, Local0)
                    Store(0x00, Local1)
                    While(LEqual(Local0, 0xff)) {
                        Store(VCOR, Local0)
                        If(LEqual(Local1, 0x000186a0)) {
                            Break
                        }
                        Add(Local1, 0x01, Local1)
                    }
                    Multiply(Local0, 0x10, Local0)
                    Multiply(0x0f, 0x0a, Local1)
                    Add(Local1, Local0, Local0)
                    Return(Local0)
                }
                Store(DerefOf(Index(V333, 0x00, )), Local0)
                If(LEqual(Arg0, Local0)) {
                    Store(V33V, Local0)
                    Store(0x00, Local1)
                    While(LEqual(Local0, 0xff)) {
                        Store(V33V, Local0)
                        If(LEqual(Local1, 0x000186a0)) {
                            Break
                        }
                        Add(Local1, 0x01, Local1)
                    }
                    Multiply(Local0, 0x10, Local0)
                    Multiply(0x14, 0x0a, Local1)
                    Add(Local0, Local1, Local0)
                    Return(Local0)
                }
                Store(DerefOf(Index(V500, 0x00, )), Local0)
                If(LEqual(Arg0, Local0)) {
                    Store(V50V, Local0)
                    Store(0x00, Local1)
                    While(LEqual(Local0, 0xff)) {
                        Store(V50V, Local0)
                        If(LEqual(Local1, 0x000186a0)) {
                            Break
                        }
                        Add(Local1, 0x01, Local1)
                    }
                    Multiply(Local0, 0x10, Local0)
                    Store(0x22, Local1)
                    Store(0x32, Local2)
                    Add(Local1, Local2, Local1)
                    Multiply(Local0, Local1, Local0)
                    Divide(Local0, Local2, Local3, Local0)
                    Multiply(0x23, 0x0a, Local1)
                    Add(Local1, Local0, Local0)
                    Return(Local0)
                }
                Store(DerefOf(Index(V120, 0x00, )), Local0)
                If(LEqual(Arg0, Local0)) {
                    Store(V12V, Local0)
                    Store(0x00, Local1)
                    While(LEqual(Local0, 0xff)) {
                        Store(V12V, Local0)
                        If(LEqual(Local1, 0x000186a0)) {
                            Break
                        }
                        Add(Local1, 0x01, Local1)
                    }
                    Multiply(Local0, 0x10, Local0)
                    Store(0x1e, Local1)
                    Store(0x0a, Local2)
                    Add(Local1, Local2, Local1)
                    Multiply(Local0, Local1, Local0)
                    Divide(Local0, Local2, Local3, Local0)
                    Multiply(0x55, 0x0a, Local1)
                    Add(Local1, Local0, Local0)
                    Return(Local0)
                }
            }
            Method(SVLT, 1) {
                Store(DerefOf(Index(Arg0, 0x00, )), Local0)
                And(Local0, 0x0f, Local0)
                Store(DerefOf(Index(VBUF, 0x00, )), Local1)
                If(LNot(LLess(Local0, Local1))) {
                    Return(0x01)
                }
                Add(Local0, 0x01, Local0)
                Store(DerefOf(Index(Arg0, 0x01, )), Local1)
                Store(DerefOf(Index(Arg0, 0x02, )), Local2)
                Store(DerefOf(Index(Arg0, 0x03, )), Local3)
                Store(DerefOf(Index(Arg0, 0x04, )), Local4)
                Store(Local1, Index(DerefOf(Index(VBUF, Local0, )), 0x01, ))
                Store(Local2, Index(DerefOf(Index(VBUF, Local0, )), 0x02, ))
                Store(Local3, Index(DerefOf(Index(VBUF, Local0, )), 0x03, ))
                Store(Local4, Index(DerefOf(Index(VBUF, Local0, )), 0x04, ))
                Return(0x00)
            }
            Method(TSIF) {
                Return(TBUF)
            }
            Method(RTMP, 1) {
                Store(DerefOf(Index(CPUT, 0x00, )), Local0)
                If(LEqual(Arg0, Local0)) {
                    Store(TSR1, Local0)
                    Store(0x00, Local1)
                    While(LEqual(Local0, 0x80)) {
                        Store(TSR1, Local0)
                        If(LEqual(Local1, 0x000186a0)) {
                            Break
                        }
                        Add(Local1, 0x01, Local1)
                    }
                    Multiply(Local0, 0x0a, Local0)
                    Return(Local0)
                }
                Store(DerefOf(Index(MBTP, 0x00, )), Local0)
                If(LEqual(Arg0, Local0)) {
                    Store(MBTE, Local0)
                    Store(0x00, Local1)
                    While(LEqual(Local0, 0x80)) {
                        Store(MBTE, Local0)
                        If(LEqual(Local1, 0x000186a0)) {
                            Break
                        }
                        Add(Local1, 0x01, Local1)
                    }
                    Multiply(Local0, 0x0a, Local0)
                    Return(Local0)
                }
            }
            Method(STMP, 1) {
                Store(DerefOf(Index(Arg0, 0x00, )), Local0)
                And(Local0, 0x0f, Local0)
                Store(DerefOf(Index(TBUF, 0x00, )), Local1)
                If(LNot(LLess(Local0, Local1))) {
                    Return(0x01)
                }
                Add(Local0, 0x01, Local0)
                Store(DerefOf(Index(Arg0, 0x01, )), Local1)
                Store(DerefOf(Index(Arg0, 0x02, )), Local2)
                Store(DerefOf(Index(Arg0, 0x03, )), Local3)
                Store(DerefOf(Index(Arg0, 0x04, )), Local4)
                Store(Local1, Index(DerefOf(Index(TBUF, Local0, )), 0x01, ))
                Store(Local2, Index(DerefOf(Index(TBUF, Local0, )), 0x02, ))
                Store(Local3, Index(DerefOf(Index(TBUF, Local0, )), 0x03, ))
                Store(Local4, Index(DerefOf(Index(TBUF, Local0, )), 0x04, ))
                Return(0x00)
            }
            Method(FSIF) {
                Return(FBUF)
            }
            Method(RFAN, 1) {
                Store(0x00, Local0)
                Store(DerefOf(Index(CPUF, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    Store(FANC(FAN1, FEN1), Local0)
                }
                Store(DerefOf(Index(CHAF, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    Store(FANC(FAN2, FEN2), Local0)
                }
                Store(DerefOf(Index(PWRF, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    Store(FANC(FAN3, FEN3), Local0)
                }
                Store(SEFA(Arg0), Local1)
                If(LNot(LEqual(Local1, 0xffffffff))) {
                    Return(Local1)
                }
                Return(Local0)
            }
            Method(FANC, 2) {
                Store(Arg0, Local0)
                Store(Arg1, Local1)
                Multiply(Local1, 0x0100, Local1)
                Add(Local0, Local1, Local0)
                If(LAnd(LLess(Local0, 0xffff), LGreater(Local0, 0x0a))) {
                    Divide(0x000a4cb8, Local0, Local1, Local0)
                }
                Else {
                    Store(0x00, Local0)
                }
                Return(Local0)
            }
            Method(SFAN, 1) {
                Store(DerefOf(Index(Arg0, 0x00, )), Local0)
                And(Local0, 0x0f, Local0)
                Store(DerefOf(Index(FBUF, 0x00, )), Local1)
                If(LNot(LLess(Local0, Local1))) {
                    Return(0x00)
                }
                Else {
                    Add(Local0, 0x01, Local0)
                    Store(DerefOf(Index(Arg0, 0x01, )), Local1)
                    Store(DerefOf(Index(Arg0, 0x02, )), Local2)
                    Store(DerefOf(Index(Arg0, 0x03, )), Local3)
                    Store(DerefOf(Index(Arg0, 0x04, )), Local4)
                    Store(Local1, Index(DerefOf(Index(FBUF, Local0, )), 0x01, ))
                    Store(Local2, Index(DerefOf(Index(FBUF, Local0, )), 0x02, ))
                    Store(Local3, Index(DerefOf(Index(FBUF, Local0, )), 0x03, ))
                    Store(Local4, Index(DerefOf(Index(FBUF, Local0, )), 0x04, ))
                    Return(0x01)
                }
            }
            Method(SFAS, 1) {
                Store(DerefOf(Index(Arg0, 0x00, )), Local0)
                And(Local0, 0x0f, Local0)
                Store(DerefOf(Index(FBUF, 0x00, )), Local1)
                If(LNot(LLess(Local0, Local1))) {
                    Return(0x00)
                }
                Else {
                    Return(0x01)
                }
            }
            Method(OCIF) {
                If(LEqual(MMCM, 0x00)) {
                    Store(0x00, Index(CPUM, 0x03, ))
                }
                Else {
                    Store(MMCM, Index(OC02, 0x03, ))
                    Store(MMCM, Local0)
                    Store(DerefOf(Index(OC02, 0x02, )), Local1)
                    Subtract(Local0, Local1, Local0)
                    Multiply(Local0, 0x02, Local0)
                    If(LEqual(REVG, 0x01)) {
                        Divide(Local0, 0x0a, Local3, Local0)
                    }
                    Else {
                        Divide(Local0, 0x14, Local3, Local0)
                    }
                    Increment(Local0)
                    Store(Local0, Index(OC02, 0x04, ))
                }
                Return(OBUF)
            }
            Name(OC1F, 0x00)
            Name(OC2F, 0x00)
            Name(OC3F, 0x00)
            Name(OC4F, 0x00)
            Name(OC5F, 0x00)
            Name(OC6F, 0x00)
            Name(OC7F, 0x00)
            Name(OC8F, 0x00)
            Name(OC9F, 0x00)
            Name(OCAF, 0x00)
            Name(OCBF, 0x00)
            Name(OCCF, 0x00)
            Name(OCDF, 0x00)
            Name(OCEF, 0x00)
            Name(QFNF, 0x00)
            Name(QFPF, 0x00)
            Method(OCOP, 1) {
                Store(DerefOf(Index(OC01, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OC1F, 0x00)) {
                        Store(FSBF, Local0)
                        If(LLess(Local0, 0x64)) {
                            Add(Local0, 0xff, Local0)
                        }
                        Store(Local0, Local1)
                        Multiply(Local0, 0x64, Local0)
                        Store(Local0, Index(CPUO, 0x01, ))
                        Subtract(Local1, 0xc8, Local1)
                        Store(Local1, Index(CPUO, 0x02, ))
                        SPRE(Arg0, Local1)
                        Store(0x01, OC1F)
                    }
                    Return(CPUO)
                }
                Store(DerefOf(Index(OC02, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OC2F, 0x00)) {
                        Store(MULF, Local0)
                        Store(Local0, Index(CPUM, 0x01, ))
                        Store(Local0, Index(CPUM, 0x02, ))
                        SPRD(Arg0, MUCM)
                        SPRE(Arg0, Local0)
                        Store(0x01, OC2F)
                    }
                    Return(CPUM)
                }
                Store(DerefOf(Index(OC0F, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    Store(K8HT, Local0)
                    Store(0x04, Local1)
                    If(LEqual(Local0, 0x06)) {
                        Store(0x05, Local1)
                    }
                    If(LEqual(Local0, 0x05)) {
                        Store(0x04, Local1)
                    }
                    If(LEqual(Local0, 0x04)) {
                        Store(0x03, Local1)
                    }
                    If(LEqual(Local0, 0x02)) {
                        Store(0x02, Local1)
                    }
                    If(LEqual(Local0, 0x00)) {
                        Store(0x01, Local1)
                    }
                    Store(Local1, Index(HTFQ, 0x02, ))
                    Return(HTFQ)
                }
                Store(DerefOf(Index(OC03, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OC3F, 0x00)) {
                        Store(0x01, OC3F)
                    }
                    Return(MEMO)
                }
                Store(DerefOf(Index(OC04, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OC4F, 0x00)) {
                        Store(0x01, OC4F)
                    }
                    Return(PCIO)
                }
                Store(DerefOf(Index(OC05, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OC5F, 0x00)) {
                        Store(0x01, OC5F)
                    }
                    Return(OCPO)
                }
                Store(DerefOf(Index(OC06, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OC6F, 0x00)) {
                        Store(NOS1, Local0)
                        Store(Local0, Index(AOCO, 0x02, ))
                        SPRE(Arg0, Local0)
                        Store(0x01, OC6F)
                    }
                    Return(AOCO)
                }
                Store(DerefOf(Index(OC07, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OC7F, 0x00)) {
                        Store(NOS2, Local0)
                        Store(Local0, Index(ADCO, 0x02, ))
                        SPRE(Arg0, Local0)
                        Store(0x01, OC7F)
                    }
                    Return(ADCO)
                }
                Store(DerefOf(Index(OC08, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OC8F, 0x00)) {
                        Store(0x01, OC8F)
                    }
                    Return(FANB)
                }
                Store(DerefOf(Index(OC09, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OC9F, 0x00)) {
                        Store(VCRV, Local0)
                        Store(Local0, Index(CPUV, 0x02, ))
                        SPRD(Arg0, CVCM)
                        SPRE(Arg0, Local0)
                        Store(0x01, OC9F)
                    }
                    Return(CPUV)
                }
                Store(DerefOf(Index(OC0A, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OCAF, 0x00)) {
                        Store(DDRV, Local0)
                        Store(Local0, Index(RAMV, 0x02, ))
                        SPRD(Arg0, DRVC)
                        SPRE(Arg0, Local0)
                        Store(0x01, OCAF)
                    }
                    Return(RAMV)
                }
                Store(DerefOf(Index(OC0B, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OCBF, 0x00)) {
                        Store(0x01, OCBF)
                    }
                    Return(PCIV)
                }
                Store(DerefOf(Index(OC0C, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OCCF, 0x00)) {
                        Store(0x01, OCCF)
                    }
                    Return(PRHT)
                }
                Store(DerefOf(Index(OC0D, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(OCDF, 0x00)) {
                        Store(AITU, Index(AITM, 0x02, ))
                        SPRE(Arg0, AITU)
                        Store(0x01, OCDF)
                    }
                    Return(AITM)
                }
                Store(DerefOf(Index(QFAN, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    If(LEqual(QFNF, 0x00)) {
                        Store(QFNE, Index(CQFN, 0x02, ))
                        SPRE(Arg0, QFNE)
                        Store(0x01, QFNF)
                    }
                    Return(CQFN)
                }
                Store(DerefOf(Index(OC0G, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    Store(CNQC, Local0)
                    If(LEqual(Local0, 0x01)) {
                        Store(0x00, Index(CNQF, 0x02, ))
                    }
                    Else {
                        Store(0x01, Index(CNQF, 0x02, ))
                    }
                    Return(CNQF)
                }
            }
            Method(PROC, 3) {
                If(LEqual(Arg2, 0x00)) {
                    Return(0x01)
                }
                If(LEqual(Arg2, 0x01)) {
                    Store(DerefOf(Index(OC0D, 0x00, )), Local0)
                    If(LEqual(Arg0, Local0)) {
                        If(LEqual(Arg1, 0x00)) {
                            Store(0x00, Index(AITM, 0x02, ))
                        }
                        If(LEqual(Arg1, 0x01)) {
                            STDF(0x01)
                            Store(0x01, Index(AITM, 0x02, ))
                        }
                        If(LEqual(Arg1, 0x02)) {
                            STDF(0x02)
                            Store(0x02, Index(AITM, 0x02, ))
                        }
                        If(LEqual(Arg1, 0x03)) {
                            Store(0x03, Index(AITM, 0x02, ))
                        }
                        If(LEqual(Arg1, 0x04)) {
                            Store(0x04, Index(AITM, 0x02, ))
                        }
                    }
                    Store(DerefOf(Index(OC01, 0x00, )), Local0)
                    If(LEqual(Arg0, Local0)) {
                        Store(Arg1, AIP)
                        Store(Arg1, Index(CPUO, 0x02, ))
                        Store(0x03, AIP2)
                        Store(0xb0, SCP)
                    }
                    Store(DerefOf(Index(OC05, 0x00, )), Local0)
                    If(LEqual(Arg0, Local0)) {
                        Store(Arg1, AIP)
                        Store(Arg1, Index(OCPO, 0x02, ))
                        If(LEqual(Arg1, 0x00)) {
                            Store(0x06, Local1)
                        }
                        Else {
                            If(LEqual(Arg1, 0x01)) {
                                Store(0x0a, Local1)
                            }
                            Else {
                                If(LEqual(Arg1, 0x02)) {
                                    Store(0x10, Local1)
                                }
                                Else {
                                    If(LEqual(Arg1, 0x03)) {
                                        Store(0x14, Local1)
                                    }
                                    Else {
                                        Store(0x00, Local1)
                                    }
                                }
                            }
                        }
                        Store(Local1, Index(CPUO, 0x02, ))
                        Store(0x01, AIP2)
                        Store(0xb0, SCP)
                    }
                    Store(DerefOf(Index(OC06, 0x00, )), Local0)
                    If(LEqual(Arg0, Local0)) {
                        Store(0x00, AIP)
                        Store(0x03, AIP2)
                        Store(0xb0, SCP)
                        Store(0x00, Index(CPUO, 0x02, ))
                        Store(Arg1, AIP)
                        Store(Arg1, Index(AOCO, 0x02, ))
                        Store(0x02, AIP2)
                        Store(0xb0, SCP)
                    }
                    Store(DerefOf(Index(OC09, 0x00, )), Local0)
                    If(LEqual(Arg0, Local0)) {
                        If(LNot(LEqual(MVCM, 0x00))) {
                            Store(Arg1, AIP)
                            Store(Arg1, Index(CPUV, 0x02, ))
                            Store(0x04, AIP2)
                            Store(0xb0, SCP)
                        }
                    }
                    Store(DerefOf(Index(OC0A, 0x00, )), Local0)
                    If(LEqual(Arg0, Local0)) {
                        Store(Arg1, AIP)
                        Store(Arg1, Index(RAMV, 0x02, ))
                        Store(0x05, AIP2)
                        Store(0xb0, SCP)
                    }
                    Store(DerefOf(Index(OC02, 0x00, )), Local0)
                    If(LEqual(Arg0, Local0)) {
                        If(LNot(LEqual(MMCM, 0x00))) {
                            Store(Arg1, AIP)
                            Store(Arg1, Index(CPUM, 0x01, ))
                            Store(Arg1, Index(CPUM, 0x02, ))
                            Store(0x06, AIP2)
                            Store(0xb0, SCP)
                        }
                    }
                    Store(DerefOf(Index(QFAN, 0x00, )), Local0)
                    If(LEqual(Arg0, Local0)) {
                        Store(Arg1, AIP)
                        Store(Arg1, Index(CQFN, 0x02, ))
                        Store(0x07, AIP2)
                        Store(0xb0, SCP)
                    }
                    SPRE(Arg0, Arg1)
                    Return(0x01)
                }
                Else {
                    Return(0x00)
                }
            }
            Method(STDF, 1) {
                Store(0x00, AIP)
                Store(0x03, AIP2)
                Store(0xb0, SCP)
                Store(0x00, Index(CPUO, 0x02, ))
                If(LNot(LEqual(MVCM, 0x00))) {
                    Store(CVCM, AIP)
                    Store(0x04, AIP2)
                    Store(0xb0, SCP)
                    Store(CVCM, Index(CPUV, 0x02, ))
                }
                If(LNot(LEqual(MMCM, 0x00))) {
                    Store(MUCM, AIP)
                    Store(0x06, AIP2)
                    Store(0xb0, SCP)
                    Store(MUCM, Index(CPUM, 0x01, ))
                    Store(MUCM, Index(CPUM, 0x02, ))
                }
                Store(DRVC, AIP)
                Store(0x05, AIP2)
                Store(0xb0, SCP)
                Store(DRVC, Index(RAMV, 0x02, ))
                If(LEqual(Arg0, 0x01)) {
                    Store(0x01, AIP)
                    Store(0x09, AIP2)
                    Store(0xb0, SCP)
                }
                Else {
                    Store(0x02, AIP)
                    Store(0x0a, AIP2)
                    Store(0xb0, SCP)
                }
            }
            Method(SEFA, 1) {
                Store(DerefOf(Index(SF01, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    Store(RBY2(0x5c, 0x28), Local1)
                    Store(RBY2(0x5c, 0x29), Local2)
                    Multiply(Local2, 0x0100, Local2)
                    Add(Local2, Local1, Local2)
                    If(LEqual(Local2, 0xffff)) {
                        Store(0x00, Local0)
                        Return(Local0)
                    }
                    If(LEqual(Local2, 0x00)) {
                        Store(0x00, Local0)
                        Return(Local0)
                    }
                    Divide(0x005265c0, Local2, Local1, Local0)
                    Return(Local0)
                }
                Store(DerefOf(Index(SF02, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    Store(RBY2(0x5c, 0x2a), Local1)
                    Store(RBY2(0x5c, 0x2b), Local2)
                    Multiply(Local2, 0x0100, Local2)
                    Add(Local2, Local1, Local2)
                    If(LEqual(Local2, 0xffff)) {
                        Store(0x00, Local0)
                        Return(Local0)
                    }
                    If(LEqual(Local2, 0x00)) {
                        Store(0x00, Local0)
                        Return(Local0)
                    }
                    Divide(0x005265c0, Local2, Local1, Local0)
                    Return(Local0)
                }
                Store(DerefOf(Index(SF03, 0x00, )), Local1)
                If(LEqual(Arg0, Local1)) {
                    Store(RBY2(0x5c, 0x2c), Local1)
                    Store(RBY2(0x5c, 0x2d), Local2)
                    Multiply(Local2, 0x0100, Local2)
                    Add(Local2, Local1, Local2)
                    If(LEqual(Local2, 0xffff)) {
                        Store(0x00, Local0)
                        Return(Local0)
                    }
                    If(LEqual(Local2, 0x00)) {
                        Store(0x00, Local0)
                        Return(Local0)
                    }
                    Divide(0x005265c0, Local2, Local1, Local0)
                    Return(Local0)
                }
                Return(0xffffffff)
            }
            Name(CQFN, Package(0x06) {
                0x04060003,
                0x00,
                0x00,
                0x01,
                "Disabled",
                "Enabled",
            })
            Name(QFNR, Package(0x09) {
                0x04050004,
                0x5a,
                0x00,
                0x01,
                "Auto",
                "90\x25",
                "80\x25",
                "70\x25",
                "60\x25",
            })
            Name(QFNT, Package(0x0f) {
                0x04030005,
                0x42,
                0x05,
                0x01,
                "51",
                "54",
                "57",
                "60",
                "63",
                "66",
                "69",
                "72",
                "75",
                "78",
                "81",
            })
            Name(OC01, Package(0x06) {
                0x01010000,
                "CPU\x20FSB",
                0x4e20,
                0x9c40,
                0xc9,
                0x00010003,
            })
            Name(OC02, Package(0x06) {
                0x01060001,
                "CPU\x20Multiplier",
                0x32,
                0x14,
                0x10,
                0x00010007,
            })
            Name(OC0F, Package(0x06) {
                0x01060002,
                "Hyper\x20Transport\x20Freq",
                0x01,
                0x05,
                0x05,
                0x00010003,
            })
            Name(OC03, Package(0x06) {
                0x02010002,
                "Memory\x20Freq",
                0x00,
                0x00,
                0x04,
                0x00010003,
            })
            Name(OC04, Package(0x06) {
                0x07010003,
                "PCI\x20Express",
                0x2710,
                0x332c,
                0x20,
                0x00,
            })
            Name(OC05, Package(0x06) {
                0x05050004,
                "OC\x20Profile",
                0x69,
                0x82,
                0x05,
                0x00010003,
            })
            Name(OC06, Package(0x06) {
                0x08050005,
                "Turbo\x20N.O.S.",
                0x67,
                0x6e,
                0x04,
                0x00010003,
            })
            Name(OC07, Package(0x06) {
                0x08050006,
                "Twin\x20Turbo\x20N.O.S.",
                0x00,
                0x01,
                0x02,
                0x00,
            })
            Name(OC08, Package(0x06) {
                0x04040007,
                "FAN\x2dBoost",
                0x2ee0,
                0x36b0,
                0x02,
                0x00010001,
            })
            Name(OC09, Package(0x06) {
                0x01020008,
                "CPU\x20Voltage",
                0x1f40,
                0x3d09,
                0x3d,
                0x00,
            })
            Name(OC0A, Package(0x06) {
                0x02020009,
                "DRAM\x20Voltage",
                0x0708,
                0x09c4,
                0x0f,
                0x00,
            })
            Name(OC0B, Package(0x06) {
                0x0702000a,
                "PCIE\x20Voltage",
                0x0d05,
                0x115c,
                0x03,
                0x00,
            })
            Name(OC0C, Package(0x06) {
                0x0106000b,
                "CPU\x20HT",
                0x00,
                0x01,
                0x02,
                0x00010002,
            })
            Name(OC0G, Package(0x06) {
                0x0106000c,
                "CoolnQuietFlag",
                0x00,
                0x01,
                0x02,
                0x00010001,
            })
            Name(OC0D, Package(0x06) {
                0x0906000c,
                "AI\x20Overclock\x20Tuner",
                0x00,
                0x04,
                0x05,
                0x00010003,
            })
            Name(OBUF, Package(0x0d) {
                OC01,
                OC02,
                OC03,
                OC04,
                OC05,
                OC06,
                OC07,
                OC08,
                OC09,
                OC0A,
                OC0B,
                OC0C,
                OC0D,
            })
            Name(CPUO, Package(0x04) {
                0x01010000,
                0x4e20,
                0x64,
                0x01,
            })
            Name(CPUM, Package(0x04) {
                0x01060001,
                0x0e,
                0x00,
                0x01,
            })
            Name(HTFQ, Package(0x04) {
                0x01060002,
                0x04,
                0x03,
                0x01,
            })
            Name(MEMO, Package(0x09) {
                0x02010002,
                0xd034,
                0x04,
                0x01,
                "Auto",
                "1\x3a3",
                "1\x3a4",
                "1\x3a2",
                "3\x3a8",
            })
            Name(PCIO, Package(0x04) {
                0x07010003,
                0x2710,
                0x00,
                0x01,
            })
            Name(OCPO, Package(0x08) {
                0x05050004,
                0x64,
                0x00,
                0x01,
                "103\x25",
                "105\x25",
                "108\x25",
                "110\x25",
            })
            Name(AOCO, Package(0x09) {
                0x08050005,
                0x64,
                0x00,
                0x01,
                "Disabled",
                "103\x25",
                "105\x25",
                "108\x25",
                "110\x25",
            })
            Name(ADCO, Package(0x06) {
                0x08050006,
                0x00,
                0x00,
                0x00,
                "Disabled",
                "Enabled",
            })
            Name(FANB, Package(0x06) {
                0x04040007,
                0x00,
                0x00,
                0x00,
                "Disabled",
                "Enabled",
            })
            Name(CPUV, Package(0x04) {
                0x01020008,
                0x073a,
                0x01,
                0x01,
            })
            Name(RAMV, Package(0x04) {
                0x02020009,
                0x0a8c,
                0x01,
                0x01,
            })
            Name(PCIV, Package(0x04) {
                0x0702000a,
                0x0640,
                0x00,
                0x00,
            })
            Name(PRHT, Package(0x04) {
                0x0106000b,
                0x01,
                0x00,
                0x00,
            })
            Name(CNQF, Package(0x04) {
                0x0106000c,
                0x00,
                0x00,
                0x01,
            })
            Name(AITM, Package(0x09) {
                0x0906000c,
                0x00,
                0x00,
                0x01,
                "Manual",
                "Auto",
                "Standard",
                "OC\x20Profile",
                "AI\x20NOS",
            })
            Name(PREB, Package(0x1c) {
                0x02010002,
                0x00,
                0x07010003,
                0x00,
                0x08050005,
                0x00,
                0x08050006,
                0x00,
                0x04040007,
                0x00,
                0x01020008,
                0x00,
                0x02020009,
                0x00,
                0x0702000a,
                0x00,
                0x0106000b,
                0x00,
                0x0906000c,
                0x00,
                0x04060003,
                0x00,
                0x04030005,
                0x00,
                0x01010000,
                0x00,
                0x01060001,
                0x00,
            })
            Name(PRED, Package(0x0a) {
                0x01010000,
                0x00,
                0x01060001,
                0x00,
                0x01020008,
                0x00,
                0x02020009,
                0x00,
                0x0702000a,
                0x00,
            })
            Name(ASBF, Buffer(0x08) {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0 })
            CreateDWordField(ASBF, 0x00, ASB0)
            CreateDWordField(ASBF, 0x04, ASB1)
            Name(GAT1, Package(0x04) {
                0x0a070001,
                "Music\x20Alarm",
                0x00,
                0x01,
            })
            Name(GAT2, Package(0x04) {
                0x0a070002,
                "Sunday",
                0x00,
                0x01,
            })
            Name(GAT3, Package(0x04) {
                0x0a070003,
                "Monday",
                0x00,
                0x01,
            })
            Name(GAT4, Package(0x04) {
                0x0a070004,
                "Tuesday",
                0x00,
                0x01,
            })
            Name(GAT5, Package(0x04) {
                0x0a070005,
                "Wednesday",
                0x00,
                0x01,
            })
            Name(GAT6, Package(0x04) {
                0x0a070006,
                "Thursday",
                0x00,
                0x01,
            })
            Name(GAT7, Package(0x04) {
                0x0a070007,
                "Friday",
                0x00,
                0x01,
            })
            Name(GAT8, Package(0x04) {
                0x0a070008,
                "Saturday",
                0x00,
                0x01,
            })
            Name(GAT9, Package(0x07) {
                0x0a060009,
                "Alarm\x20Hour",
                0x00,
                0x0c,
                0x00,
                0x01,
                0x18,
            })
            Name(GATA, Package(0x07) {
                0x0a06000a,
                "Alarm\x20Mins",
                0x00,
                0x00,
                0x00,
                0x01,
                0x3c,
            })
            Name(GATB, Package(0x09) {
                0x0a08000b,
                "Music\x20Alarm\x20Drive",
                0x00,
                0x01,
                0x04,
                "Primary\x20IDE\x20Master",
                "Primary\x20IDE\x20Slave",
                "Secondary\x20IDE\x20Master",
                "Secondary\x20IDE\x20Slave",
            })
            Name(GATC, Package(0x07) {
                0x0a06000c,
                "Starting\x20Track",
                0x00,
                0x10,
                0x01,
                0x01,
                0x20,
            })
            Name(GATD, Package(0x08) {
                0x0a08000d,
                "Repeat",
                0x00,
                0x01,
                0x03,
                "Disabled",
                "Single",
                "All",
            })
            Name(GATE, Package(0x09) {
                0x0a08000e,
                "Length",
                0x00,
                0x01,
                0x04,
                "10\x20mins",
                "20\x20mins",
                "30\x20mins",
                "1\x20hour",
            })
            Name(GATF, Package(0x07) {
                0x0a06000f,
                "Volume",
                0x00,
                0x0f,
                0x00,
                0x01,
                0x20,
            })
            Name(GRPA, Package(0x0f) {
                GAT1,
                GAT2,
                GAT3,
                GAT4,
                GAT5,
                GAT6,
                GAT7,
                GAT8,
                GAT9,
                GATA,
                GATB,
                GATC,
                GATD,
                GATE,
                GATF,
            })
            Method(GGRP, 1) {
                If(LEqual(Arg0, 0xff)) {
                    Return(0x00)
                }
                If(LEqual(Arg0, 0x0a)) {
                    Return(GRPA)
                }
                Else {
                    Return(0x00)
                }
            }
            Method(GITM, 1) {
                CreateDWordField(Arg0, 0x00, PRM0)
                ShiftRight(PRM0, 0x18, Local0)
                Store(0x01, ASB0)
                If(LEqual(Local0, 0xff)) {
                    Return(0x00)
                }
                If(LEqual(Local0, 0x0a)) {
                    If(LEqual(And(PRM0, 0xff, ), 0x01)) {
                        Store(ShiftRight(And(MA18, 0x01, ), 0x00, ), ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x02)) {
                        Store(ShiftRight(And(MA18, 0x02, ), 0x01, ), ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x03)) {
                        Store(ShiftRight(And(MA18, 0x04, ), 0x02, ), ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x04)) {
                        Store(ShiftRight(And(MA18, 0x08, ), 0x03, ), ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x05)) {
                        Store(ShiftRight(And(MA18, 0x10, ), 0x04, ), ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x06)) {
                        Store(ShiftRight(And(MA18, 0x20, ), 0x05, ), ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x07)) {
                        Store(ShiftRight(And(MA18, 0x40, ), 0x06, ), ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x08)) {
                        Store(ShiftRight(And(MA18, 0x80, ), 0x07, ), ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x09)) {
                        Store(MA09, ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0a)) {
                        Store(MA0A, ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0b)) {
                        Store(MA0B, ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0c)) {
                        Store(MA0C, ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0d)) {
                        Store(MA0D, ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0e)) {
                        Store(MA0E, ASB1)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0f)) {
                        Store(MA0F, ASB1)
                    }
                    Return(ASBF)
                }
                Else {
                    Return(0x00)
                }
            }
            Method(SITM, 1) {
                CreateDWordField(Arg0, 0x00, PRM0)
                CreateDWordField(Arg0, 0x04, PRM1)
                CreateDWordField(Arg0, 0x08, PRM2)
                ShiftRight(PRM0, 0x18, Local0)
                Store(0x01, ASB0)
                If(LEqual(Local0, 0xff)) {
                    Return(0x00)
                }
                If(LEqual(Local0, 0x0a)) {
                    If(LEqual(And(PRM0, 0xff, ), 0x01)) {
                        And(MA18, 0xfe, MA18)
                        Or(MA18, ShiftLeft(And(PRM1, 0x01, ), 0x00, ), MA18)
                        Store(0x32, AIP2)
                        Store(0xb0, SCP)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x02)) {
                        And(MA18, 0xfd, MA18)
                        Or(MA18, ShiftLeft(And(PRM1, 0x01, ), 0x01, ), MA18)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x03)) {
                        And(MA18, 0xfb, MA18)
                        Or(MA18, ShiftLeft(And(PRM1, 0x01, ), 0x02, ), MA18)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x04)) {
                        And(MA18, 0xf7, MA18)
                        Or(MA18, ShiftLeft(And(PRM1, 0x01, ), 0x03, ), MA18)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x05)) {
                        And(MA18, 0xef, MA18)
                        Or(MA18, ShiftLeft(And(PRM1, 0x01, ), 0x04, ), MA18)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x06)) {
                        And(MA18, 0xdf, MA18)
                        Or(MA18, ShiftLeft(And(PRM1, 0x01, ), 0x05, ), MA18)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x07)) {
                        And(MA18, 0xbf, MA18)
                        Or(MA18, ShiftLeft(And(PRM1, 0x01, ), 0x06, ), MA18)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x08)) {
                        And(MA18, 0x7f, MA18)
                        Or(MA18, ShiftLeft(And(PRM1, 0x01, ), 0x07, ), MA18)
                        Store(0x32, AIP2)
                        Store(0xb0, SCP)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x09)) {
                        Store(And(PRM1, 0xff, ), MA09)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0a)) {
                        Store(And(PRM1, 0xff, ), MA0A)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0b)) {
                        Store(And(PRM1, 0xff, ), MA0B)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0c)) {
                        Store(And(PRM1, 0xff, ), MA0C)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0d)) {
                        Store(And(PRM1, 0xff, ), MA0D)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0e)) {
                        Store(And(PRM1, 0xff, ), MA0E)
                    }
                    If(LEqual(And(PRM0, 0xff, ), 0x0f)) {
                        Store(And(PRM1, 0xff, ), MA0F)
                        Store(0x33, AIP2)
                        Store(0xb0, SCP)
                    }
                    Return(ASBF)
                }
                If(LEqual(Local0, 0x0b)) {
                    Store(And(PRM1, 0xff, ), AIP)
                    Store(0x0b, AIP2)
                    Store(0xb0, SCP)
                    Return(0x00)
                }
                Else {
                    Return(0x00)
                }
            }
            Method(SPRD, 2) {
                Store(0x00, Local0)
                Store(0x01, Local2)
                While(Local2) {
                    Multiply(Local0, 0x02, Local1)
                    If(LEqual(DerefOf(Index(PRED, Local1, )), Arg0)) {
                        Add(Local1, 0x01, Local1)
                        Store(Arg1, Index(PRED, Local1, ))
                        Store(0x00, Local2)
                    }
                    Increment(Local0)
                    If(LEqual(Local0, 0x10)) {
                        Store(0x00, Local2)
                    }
                }
            }
            Method(GPRE, 1) {
                If(Arg0) {
                    Return(PREB)
                }
                Else {
                    Return(PRED)
                }
            }
            Method(SPRE, 2) {
                Store(0x00, Local0)
                Store(0x01, Local2)
                While(Local2) {
                    Multiply(Local0, 0x02, Local1)
                    If(LEqual(DerefOf(Index(PREB, Local1, )), Arg0)) {
                        Add(Local1, 0x01, Local1)
                        Store(Arg1, Index(PREB, Local1, ))
                        Store(0x00, Local2)
                    }
                    Increment(Local0)
                    If(LEqual(Local0, 0x10)) {
                        Store(0x00, Local2)
                    }
                }
            }
            Method(GCQV, 1) {
                If(LEqual(Arg0, 0x00)) {
                    Store(K8VL, Local0)
                    Return(Local0)
                }
                Else {
                    If(LEqual(Arg0, 0x01)) {
                        Store(K8VH, Local0)
                        Return(Local0)
                    }
                    Else {
                        If(LEqual(Arg0, 0x02)) {
                            If(LEqual(CNQC, 0x00)) {
                                Store(0x01, Local0)
                            }
                            Else {
                                Store(0x00, Local0)
                            }
                            Return(Local0)
                        }
                    }
                }
            }
            Method(SPLV, 1, Serialized) {
                If(LEqual(Arg0, 0x00)) {
                    SCTC(0x00)
                }
                Else {
                    ENGR(Arg0)
                }
                If(LNot(LEqual(And(Arg0, 0xff, ), 0xff))) {
                    Store(Arg0, GELF)
                    Store(Arg0, AIP)
                    Store(0x0e, AIP2)
                    Store(0xb0, SCP)
                }
                Else {
                    Store(Arg0, AIP)
                    Store(0x0b, AIP2)
                    Store(0xb0, SCP)
                }
                Return(Arg0)
            }
            Method(GPLV, 0, Serialized) {
                Return(GELF)
            }
            Method(ENGR, 1) {
                If(LEqual(Arg0, 0x01)) {
                    SCTC(0x01)
                }
                If(LEqual(Arg0, 0x02)) {
                    SCTC(0x04)
                }
                If(LEqual(Arg0, 0x03)) {
                    SCTC(0x06)
                }
                If(LEqual(Arg0, 0x7fff)) {
                    SCTC(0x01)
                }
            }
        }
        Name(BUFA, Buffer(0x06) {0x23, 0xa0, 0xce, 0x18, 0x79, 0x0
        /* ResourceTemplate() {
         0x0000  IRQ(Level, ActiveLow, Shared) {5, 7, 9, 10, 11, 14, 15}
        } */
         })
        Name(BUFB, Buffer(0x06) {0x23, 0x0, 0x0, 0x18, 0x79, 0x0
        /* ResourceTemplate() {
         0x0000  IRQ(Level, ActiveLow, Shared)
        } */
         })
        CreateWordField(BUFB, 0x01, IRQV)
        Method(CRS, 1) {
            If(Arg0) {
                ShiftLeft(0x01, Arg0, IRQV)
            }
            Else {
                Store(Zero, IRQV)
            }
            Return(BUFB)
        }
        Method(SRS, 1) {
            CreateWordField(Arg0, 0x01, IRQ0)
            FindSetRightBit(IRQ0, Local0)
            Decrement(Local0)
            Return(Local0)
        }
        Method(CRSA, 1, Serialized) {
            Store(Arg0, Local0)
            If(LEqual(Arg0, 0x01)) {
                Store(0x17, Local0)
            }
            If(LEqual(Arg0, 0x02)) {
                Store(0x16, Local0)
            }
            If(LEqual(Arg0, 0x03)) {
                Store(0x10, Local0)
            }
            If(LEqual(Arg0, 0x04)) {
                Store(0x11, Local0)
            }
            If(LEqual(Arg0, 0x06)) {
                Store(0x12, Local0)
            }
            If(LEqual(Arg0, 0x08)) {
                Store(0x14, Local0)
            }
            If(LEqual(Arg0, 0x0c)) {
                Store(0x13, Local0)
            }
            If(LEqual(Arg0, 0x0d)) {
                Store(0x15, Local0)
            }
            Name(IRZ5, Buffer(0x0b) {0x89, 0x6, 0x0, 0xd, 0x1, 0x7, 0x0, 0x0, 
0x0, 0x79, 0x0
            /* ResourceTemplate() {
             0x0000  Interrupt(ResourceProducer, Level, ActiveLow, Shared, 0, ) 
{7}
            } */
             })
            CreateWordField(IRZ5, 0x05, INZ5)
            Store(Local0, INZ5)
            Return(IRZ5)
        }
        Method(SRSA, 1, Serialized) {
            CreateWordField(Arg0, 0x05, INZ6)
            Store(0x08, Local0)
            If(LEqual(INZ6, 0x10)) {
                Store(0x03, Local0)
            }
            If(LEqual(INZ6, 0x11)) {
                Store(0x04, Local0)
            }
            If(LEqual(INZ6, 0x12)) {
                Store(0x06, Local0)
            }
            If(LEqual(INZ6, 0x13)) {
                Store(0x0c, Local0)
            }
            If(LEqual(INZ6, 0x14)) {
                Store(0x08, Local0)
            }
            If(LEqual(INZ6, 0x15)) {
                Store(0x0d, Local0)
            }
            If(LEqual(INZ6, 0x16)) {
                Store(0x02, Local0)
            }
            If(LEqual(INZ6, 0x17)) {
                Store(0x01, Local0)
            }
            Return(Local0)
        }
        Device(LNK1) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x01)
            Method(_STA) {
                If(INTA) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTA)
            }
            Method(_CRS) {
                Return(CRS(INTA))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTA)
            }
        }
        Device(LNK2) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x02)
            Method(_STA) {
                If(INTB) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTB)
            }
            Method(_CRS) {
                Return(CRS(INTB))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTB)
            }
        }
        Device(LNK3) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x03)
            Method(_STA) {
                If(INTC) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTC)
            }
            Method(_CRS) {
                Return(CRS(INTC))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTC)
            }
        }
        Device(LNK4) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x04)
            Method(_STA) {
                If(INTD) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTD)
            }
            Method(_CRS) {
                Return(CRS(INTD))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTD)
            }
        }
        Device(LNK5) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x05)
            Method(_STA) {
                If(PCEA) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, PCEA)
            }
            Method(_CRS) {
                Return(CRS(PCEA))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), PCEA)
            }
        }
        Device(LNK6) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x06)
            Method(_STA) {
                If(PCEB) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, PCEB)
            }
            Method(_CRS) {
                Return(CRS(PCEB))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), PCEB)
            }
        }
        Device(LNK7) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x07)
            Method(_STA) {
                If(PCEC) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, PCEC)
            }
            Method(_CRS) {
                Return(CRS(PCEC))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), PCEC)
            }
        }
        Device(LNK8) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x08)
            Method(_STA) {
                If(PCED) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, PCED)
            }
            Method(_CRS) {
                Return(CRS(PCED))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), PCED)
            }
        }
        Device(LP2P) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x09)
            Method(_STA) {
                If(INTU) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTU)
            }
            Method(_CRS) {
                Return(CRS(INTU))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTU)
            }
        }
        Device(LUBA) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x0a)
            Method(_STA) {
                If(INTG) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTG)
            }
            Method(_CRS) {
                Return(CRS(INTG))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTG)
            }
        }
        Device(LMAC) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x0b)
            Method(_STA) {
                If(INTJ) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTJ)
            }
            Method(_CRS) {
                Return(CRS(INTJ))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTJ)
            }
        }
        Device(LAZA) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x0d)
            Method(_STA) {
                If(INTK) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTK)
            }
            Method(_CRS) {
                Return(CRS(INTK))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTK)
            }
        }
        Device(LPMU) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x0e)
            Method(_STA) {
                If(INTS) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTS)
            }
            Method(_CRS) {
                Return(CRS(INTS))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTS)
            }
        }
        Device(LSMB) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x0f)
            Method(_STA) {
                If(INTF) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTF)
            }
            Method(_CRS) {
                Return(CRS(INTF))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTF)
            }
        }
        Device(LUB2) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x10)
            Method(_STA) {
                If(INTQ) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTQ)
            }
            Method(_CRS) {
                Return(CRS(INTQ))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTQ)
            }
        }
        Device(LIDE) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x11)
            Method(_STA) {
                If(INTN) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, INTN)
            }
            Method(_CRS) {
                Return(CRS(INTN))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), INTN)
            }
        }
        Device(LSID) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x12)
            Method(_STA) {
                If(ITID) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, ITID)
            }
            Method(_CRS) {
                Return(CRS(ITID))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), ITID)
            }
        }
        Device(LFID) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x13)
            Method(_STA) {
                If(IS0P) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, IS0P)
            }
            Method(_CRS) {
                Return(CRS(IS0P))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), IS0P)
            }
        }
        Device(LSA2) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x14)
            Method(_STA) {
                If(ISA2) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFA)
            }
            Method(_DIS) {
                Store(0x00, ISA2)
            }
            Method(_CRS) {
                Return(CRS(ISA2))
            }
            Method(_SRS, 1) {
                Store(SRS(Arg0), ISA2)
            }
        }
        Name(BUF1, Buffer(0x0b) {0x89, 0x6, 0x0, 0xd, 0x1, 0x10, 0x0, 0x0, 0x0, 
0x79, 0x0
        /* ResourceTemplate() {
         0x0000  Interrupt(ResourceProducer, Level, ActiveLow, Shared, 0, ) {16}
        } */
         })
        Name(BUF2, Buffer(0x0b) {0x89, 0x6, 0x0, 0xd, 0x1, 0x11, 0x0, 0x0, 0x0, 
0x79, 0x0
        /* ResourceTemplate() {
         0x0000  Interrupt(ResourceProducer, Level, ActiveLow, Shared, 0, ) {17}
        } */
         })
        Name(BUF3, Buffer(0x0b) {0x89, 0x6, 0x0, 0xd, 0x1, 0x12, 0x0, 0x0, 0x0, 
0x79, 0x0
        /* ResourceTemplate() {
         0x0000  Interrupt(ResourceProducer, Level, ActiveLow, Shared, 0, ) {18}
        } */
         })
        Name(BUF4, Buffer(0x0b) {0x89, 0x6, 0x0, 0xd, 0x1, 0x13, 0x0, 0x0, 0x0, 
0x79, 0x0
        /* ResourceTemplate() {
         0x0000  Interrupt(ResourceProducer, Level, ActiveLow, Shared, 0, ) {19}
        } */
         })
        Name(BUFF, Buffer(0x17) {0x89, 0x12, 0x0, 0xd, 0x4, 0x14, 0x0, 0x0, 
0x0, 0x15, 0x0, 0x0, 0x0, 0x16, 0x0, 0x0, 0x0, 0x17, 0x0, 0x0, 0x0, 0x79, 0x0
        /* ResourceTemplate() {
         0x0000  Interrupt(ResourceProducer, Level, ActiveLow, Shared, 0, ) 
{20, 21, 22, 23}
        } */
         })
        Name(BUFH, Buffer(0x0b) {0x89, 0x6, 0x0, 0xd, 0x1, 0xb, 0x0, 0x0, 0x0, 
0x79, 0x0
        /* ResourceTemplate() {
         0x0000  Interrupt(ResourceProducer, Level, ActiveLow, Shared, 0, ) {11}
        } */
         })
        Name(BUFI, Buffer(0x0b) {0x89, 0x6, 0x0, 0xd, 0x1, 0x17, 0x0, 0x0, 0x0, 
0x79, 0x0
        /* ResourceTemplate() {
         0x0000  Interrupt(ResourceProducer, Level, ActiveLow, Shared, 0, ) {23}
        } */
         })
        Name(IRZ1, Buffer(0x0b) {0x89, 0x6, 0x0, 0xd, 0x1, 0x7, 0x0, 0x0, 0x0, 
0x79, 0x0
        /* ResourceTemplate() {
         0x0000  Interrupt(ResourceProducer, Level, ActiveLow, Shared, 0, ) {7}
        } */
         })
        Device(APC1) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x15)
            Method(_STA) {
                If(LAnd(INTA, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUF1)
            }
            Method(_DIS) {
                Store(0x00, INTA)
            }
            Method(_CRS) {
                Return(CRSA(INTA))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTA)
            }
        }
        Device(APC2) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x16)
            Method(_STA) {
                If(LAnd(INTB, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUF2)
            }
            Method(_DIS) {
                Store(0x00, INTB)
            }
            Method(_CRS) {
                Return(CRSA(INTB))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTB)
            }
        }
        Device(APC3) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x17)
            Method(_STA) {
                If(LAnd(INTC, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUF3)
            }
            Method(_DIS) {
                Store(0x00, INTC)
            }
            Method(_CRS) {
                Return(CRSA(INTC))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTC)
            }
        }
        Device(APC4) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x18)
            Method(_STA) {
                If(LAnd(INTD, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUF4)
            }
            Method(_DIS) {
                Store(0x00, INTD)
            }
            Method(_CRS) {
                Return(CRSA(INTD))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTD)
            }
        }
        Device(APC5) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x19)
            Method(_STA) {
                If(LAnd(PCEA, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUF1)
            }
            Method(_DIS) {
                Store(0x00, PCEA)
            }
            Method(_CRS) {
                Return(CRSA(PCEA))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), PCEA)
            }
        }
        Device(APC6) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x1a)
            Method(_STA) {
                If(LAnd(PCEB, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUF1)
            }
            Method(_DIS) {
                Store(0x00, PCEB)
            }
            Method(_CRS) {
                Return(CRSA(PCEB))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), PCEB)
            }
        }
        Device(APC7) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x1b)
            Method(_STA) {
                If(LAnd(PCEC, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUF1)
            }
            Method(_DIS) {
                Store(0x00, PCEC)
            }
            Method(_CRS) {
                Return(CRSA(PCEC))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), PCEC)
            }
        }
        Device(APC8) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x1c)
            Method(_STA) {
                If(LAnd(PCED, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUF1)
            }
            Method(_DIS) {
                Store(0x00, PCED)
            }
            Method(_CRS) {
                Return(CRSA(PCED))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), PCED)
            }
        }
        Device(APCF) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x1d)
            Method(_STA) {
                If(LAnd(INTG, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFF)
            }
            Method(_DIS) {
                Store(0x00, INTG)
            }
            Method(_CRS) {
                Return(CRSA(INTG))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTG)
            }
        }
        Device(APCH) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x1e)
            Method(_STA) {
                If(LAnd(INTJ, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFF)
            }
            Method(_DIS) {
                Store(0x00, INTJ)
            }
            Method(_CRS) {
                Return(CRSA(INTJ))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTJ)
            }
        }
        Device(APMU) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x20)
            Method(_STA) {
                If(LAnd(INTS, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFF)
            }
            Method(_DIS) {
                Store(0x00, INTS)
            }
            Method(_CRS) {
                Return(CRSA(INTS))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTS)
            }
        }
        Device(AAZA) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x21)
            Method(_STA) {
                If(LAnd(INTK, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFF)
            }
            Method(_DIS) {
                Store(0x00, INTK)
            }
            Method(_CRS) {
                Return(CRSA(INTK))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTK)
            }
        }
        Device(APCS) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x22)
            Method(_STA) {
                If(LAnd(INTF, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFF)
            }
            Method(_DIS) {
                Store(0x00, INTF)
            }
            Method(_CRS) {
                Return(CRSA(INTF))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTF)
            }
        }
        Device(APCL) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x23)
            Method(_STA) {
                If(LAnd(INTQ, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFF)
            }
            Method(_DIS) {
                Store(0x00, INTQ)
            }
            Method(_CRS) {
                Return(CRSA(INTQ))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTQ)
            }
        }
        Device(APCM) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x24)
            Method(_STA) {
                If(LAnd(INTU, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFF)
            }
            Method(_DIS) {
                Store(0x00, INTU)
            }
            Method(_CRS) {
                Return(CRSA(INTU))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTU)
            }
        }
        Device(APCZ) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x25)
            Method(_STA) {
                If(LAnd(INTN, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_PRS) {
                Return(BUFF)
            }
            Method(_DIS) {
                Store(0x00, INTN)
            }
            Method(_CRS) {
                Return(CRSA(INTN))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), INTN)
            }
        }
        Device(APSI) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x26)
            Method(_STA) {
                If(LAnd(ITID, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_DIS) {
                Store(0x00, ITID)
            }
            Method(_PRS) {
                Return(BUFF)
            }
            Method(_CRS) {
                Return(CRSA(ITID))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), ITID)
            }
        }
        Device(APSJ) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x27)
            Method(_STA) {
                If(LAnd(IS0P, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_DIS) {
                Store(0x00, IS0P)
            }
            Method(_PRS) {
                Return(BUFF)
            }
            Method(_CRS) {
                Return(CRSA(IS0P))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), IS0P)
            }
        }
        Device(ASA2) {
            Name(_HID, 0x0f0cd041)
            Name(_UID, 0x28)
            Method(_STA) {
                If(LAnd(ISA2, PICF)) {
                    Return(0x0b)
                }
                Else {
                    Return(0x09)
                }
            }
            Method(_DIS) {
                Store(0x00, ISA2)
            }
            Method(_PRS) {
                Return(BUFF)
            }
            Method(_CRS) {
                Return(CRSA(ISA2))
            }
            Method(_SRS, 1) {
                Store(SRSA(Arg0), ISA2)
            }
        }
    }
    OperationRegion(ACPM, SystemMemory, 0xbfee2c00, 0x0400)
    Field(ACPM, ByteAcc, NoLock, Preserve) {
        FSBF,   16,
        MULF,   8,
        NOS1,   8,
        NOS2,   8,
        AITU,   8,
        NOSM,   8,
        VCRV,   8,
        DDRV,   8,
        QFNE,   8,
        QFTE,   8,
        CNQC,   8,
        K8VH,   16,
        K8VL,   16,
        K8HT,   8,
        REVG,   8,
        MMCM,   8,
        MUCM,   8,
        DRVC,   8,
        CVCM,   8,
        MVCM,   16,
        FIDC,   8,
        AIBC,   8,
        AIP,    8,
        AIP2,   8,
        PM01,   8,
        PM02,   8,
        PM03,   8,
        PM04,   8,
        PM05,   8,
        PM06,   8,
        PM07,   8,
        PM08,   8,
        PM09,   8,
        PM0A,   8,
        PM0B,   8,
        PM0C,   8,
        GELF,   16,
        MA18,   8,
        MA09,   8,
        MA0A,   8,
        MA0B,   8,
        MA0C,   8,
        MA0D,   8,
        MA0E,   8,
        MA0F,   8,
        WAKF,   8
    }
    Device(MEM) {
        Name(_HID, 0x010cd041)
        Method(_CRS) {
            Name(BUF0, Buffer(0xb6) {0x86, 0x9, 0x0, 0x1, 0x0, 0x0, 0xf, 0x0, 
0x0, 0x40, 0x0, 0x0, 0x86, 0x9, 0x0, 0x1, 0x0, 0x40, 0xf, 0x0, 0x0, 0x40, 0x0, 
0x0, 0x86, 0x9, 0x0, 0x1, 0x0, 0x80, 0xf, 0x0, 0x0, 0x40, 0x0, 0x0, 0x86, 0x9, 
0x0, 0x1, 0x0, 0xc0, 0xf, 0x0, 0x0, 0x40, 0x0, 0x0, 0x86, 0x9, 0x0, 0x1, 0x0, 
0xf0, 0xff, 0xfe, 0x0, 0x1, 0x0, 0x0, 0x86, 0x9, 0x0, 0x1, 0x0, 0x0, 0x0, 0x0, 
0x0, 0x0, 0x1, 0x0, 0x86, 0x9, 0x0, 0x1, 0x0, 0x0, 0xff, 0xff, 0x0, 0x0, 0x1, 
0x0, 0x86, 0x9, 0x0, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xa, 0x0, 0x86, 0x9, 
0x0, 0x1, 0x0, 0x0, 0x10, 0x0, 0x0, 0x0, 0x0, 0x0, 0x86, 0x9, 0x0, 0x1, 0x0, 
0x0, 0xc0, 0xfe, 0x0, 0x10, 0x0, 0x0, 0x86, 0x9, 0x0, 0x1, 0x0, 0x0, 0xe0, 
0xfe, 0x0, 0x0, 0x10, 0x0, 0x86, 0x9, 0x0, 0x1, 0x0, 0xf0, 0xff, 0xfe, 0x0, 
0x10, 0x0, 0x0, 0x86, 0x9, 0x0, 0x1, 0x0, 0x0, 0xf8, 0xff, 0x0, 0x10, 0x0, 0x0, 
0x86, 0x9, 0x0, 0x1, 0x0, 0x0, 0xf9, 0xff, 0x0, 0x0, 0x3, 0x0, 0x86, 0x9, 0x0, 
0x1, 0x0, 0xd0, 0xfe, 0xff, 0x0, 0x30, 0x0, 0x0, 0x79, 0x0
            /* ResourceTemplate() {
             0x0000  Memory32Fixed(ReadWrite, 0x000f0000, 0x4000)
             0x000c  Memory32Fixed(ReadWrite, 0x000f4000, 0x4000)
             0x0018  Memory32Fixed(ReadWrite, 0x000f8000, 0x4000)
             0x0024  Memory32Fixed(ReadWrite, 0x000fc000, 0x4000)
             0x0030  Memory32Fixed(ReadWrite, 0xfefff000, 0x100)
             0x003c  Memory32Fixed(ReadWrite, 0x00000000, 0x10000)
             0x0048  Memory32Fixed(ReadWrite, 0xffff0000, 0x10000)
             0x0054  Memory32Fixed(ReadWrite, 0x00000000, 0xa0000)
             0x0060  Memory32Fixed(ReadWrite, 0x00100000, 0x0)
             0x006c  Memory32Fixed(ReadWrite, 0xfec00000, 0x1000)
             0x0078  Memory32Fixed(ReadWrite, 0xfee00000, 0x100000)
             0x0084  Memory32Fixed(ReadWrite, 0xfefff000, 0x1000)
             0x0090  Memory32Fixed(ReadWrite, 0xfff80000, 0x1000)
             0x009c  Memory32Fixed(ReadWrite, 0xfff90000, 0x30000)
             0x00a8  Memory32Fixed(ReadWrite, 0xfffed000, 0x3000)
            } */
             })
            CreateDWordField(BUF0, 0x40, ACMM)
            CreateDWordField(BUF0, 0x44, ASSM)
            CreateDWordField(BUF0, 0x04, RMA1)
            CreateDWordField(BUF0, 0x08, RSS1)
            CreateDWordField(BUF0, 0x10, RMA2)
            CreateDWordField(BUF0, 0x14, RSS2)
            CreateDWordField(BUF0, 0x1c, RMA3)
            CreateDWordField(BUF0, 0x20, RSS3)
            CreateDWordField(BUF0, 0x28, RMA4)
            CreateDWordField(BUF0, 0x2c, RSS4)
            CreateDWordField(BUF0, 0x68, EXTM)
            Subtract(AMEM, 0x00100000, EXTM)
            If(LNot(LEqual(ROM1, Zero))) {
                Store(RMA1, RMA2)
                ShiftLeft(ROM1, 0x08, Local0)
                Store(Local0, RMA1)
                ShiftLeft(RMS1, 0x08, Local0)
                Store(Local0, RSS1)
                Store(0x8000, RSS2)
            }
            If(LNot(LEqual(ROM2, Zero))) {
                Store(RMA2, RMA3)
                ShiftLeft(ROM2, 0x08, Local0)
                Store(Local0, RMA2)
                ShiftLeft(RMS2, 0x08, Local0)
                Store(Local0, RSS2)
                Store(0xc000, RSS3)
            }
            If(LNot(LEqual(ROM3, Zero))) {
                Store(RMA3, RMA4)
                ShiftLeft(ROM3, 0x08, Local0)
                Store(Local0, RMA3)
                ShiftLeft(RMS3, 0x08, Local0)
                Store(Local0, RSS3)
                Store(0x00010000, RSS4)
            }
            Store(AMEM, ACMM)
            And(AMEM, 0x000fffff, Local0)
            Subtract(0x00100000, Local0, ASSM)
            Return(BUF0)
        }
    }
    Device(\_SB.PCI0.EXPL) {
        Name(_HID, 0x020cd041)
        Name(_UID, 0x04)
        Method(_CRS) {
            Name(BUF0, Buffer(0x0e) {0x86, 0x9, 0x0, 0x1, 0x0, 0x0, 0x0, 0xf0, 
0x0, 0x0, 0x0, 0x4, 0x79, 0x0
            /* ResourceTemplate() {
             0x0000  Memory32Fixed(ReadWrite, 0xf0000000, 0x4000000)
            } */
             })
            Return(BUF0)
        }
    }
}
OperationRegion(TEMM, SystemMemory, 0x000ff810, 0x0c)
Field(TEMM, WordAcc, NoLock, Preserve) {
    TP1H,       16,
    TP1L,       16,
    TP2H,       16,
    TP2L,       16,
    TRPC,       16,
    SENF,       16
}
Name(TVAR, Buffer(0x05) {0x0, 0x0, 0x0, 0x0, 0x0 })
CreateByteField(TVAR, 0x00, PLCY)
CreateWordField(TVAR, 0x01, CTOS)
CreateWordField(TVAR, 0x03, CTHY)
Name(TBUF, Buffer(0x04) {0x0, 0x0, 0x0, 0x0 })
CreateByteField(TBUF, 0x00, DB00)
CreateByteField(TBUF, 0x01, DB01)
CreateWordField(TBUF, 0x00, DW00)
CreateWordField(TBUF, 0x02, DW01)
CreateDWordField(TBUF, 0x00, DATD)
OperationRegion(IP, SystemIO, 0x0295, 0x02)
Field(IP, ByteAcc, NoLock, Preserve) {
    INDX,       8,
    DAT0,       8
}
Method(SCFG, 1) {
    SBYT(0x40, Arg0)
}
Method(STOS, 3) {
    Divide(Arg2, 0x0a, Local0, )
    If(LGreater(Local0, 0x0111)) {
        Subtract(Local0, 0x0111, Local0)
    }
    Else {
        Subtract(0x0111, Local0, Local0)
        Or(Local0, 0x80, Local0)
    }
    SBYT(0x40, Local0)
}
Method(STHY, 3) {
    Divide(Arg2, 0x0a, Local0, )
    If(LGreater(Local0, 0x0111)) {
        Subtract(Local0, 0x0111, Local0)
    }
    Else {
        Subtract(0x0111, Local0, Local0)
        Or(Local0, 0x80, Local0)
    }
    SBYT(0x41, Local0)
}
Method(RTMP) {
    Store(GBYT(0x29), Local0)
    FindSetLeftBit(Local0, Local1)
    If(LEqual(Local1, 0x08)) {
        And(Local0, 0x7f, Local0)
        Multiply(Local0, 0x0a, Local0)
        Subtract(0x0aac, Local0, Local0)
    }
    Else {
        Multiply(Local0, 0x0a, Local0)
        Add(0x0aac, Local0, Local0)
    }
    If(LEqual(SSHU, 0x01)) {
        Return(0x0c3c)
    }
    Else {
        Return(Local0)
    }
}
Method(SBYT, 2) {
    Store(Arg0, INDX)
    Store(Arg1, DAT0)
}
Method(GBYT, 1) {
    Store(Arg0, INDX)
    Store(DAT0, Local0)
    Return(Local0)
}
Method(SFAN, 1) {
    And(SENF, 0x02, Local0)
    If(LEqual(Local0, Zero)) {
        If(LEqual(Arg0, Zero)) {
            FOFF()
        }
        Else {
            FON()
        }
    }
}
Method(FON) {
    SBYT(0x14, 0x00)
}
Method(FOFF) {
    XOr(0x00, 0x07, Local0)
    SBYT(0x14, Local0)
}
Scope(\_TZ) {
    Device(FAN) {
        Name(_HID, 0x0b0cd041)
        Method(_INI) {
            Store(TP1H, CTOS)
            Store(TP1L, CTHY)
        }
    }
    ThermalZone(THRM) {
        Name(_AL0, Package(0x01) {
            FAN,
        })
        Method(_INI) {
        }
        Method(_AC0) {
            If(Or(PLCY, PLCY, Local7)) {
                Return(KELA(TP2H))
            }
            Else {
                Return(KELA(TP1H))
            }
        }
        Name(_PSL, Package(0x01) {
            \_PR.CPU0,
        })
        Name(_TSP, 0x3c)
        Name(_TC1, 0x04)
        Name(_TC2, 0x03)
        Method(_PSV) {
            If(Or(PLCY, PLCY, Local7)) {
                Return(KELA(TP1H))
            }
            Else {
                Return(KELA(TP2H))
            }
        }
        Method(KELA, 1) {
            If(LGreater(Arg0, 0x01f4)) {
                Return(Arg0)
            }
            Else {
                Store(Arg0, Local1)
                Multiply(Local1, 0x0a, Local1)
                Add(Local1, 0x0aac, Local1)
                Return(Local1)
            }
        }
        Method(_CRT) {
            Return(TRPC)
        }
        Method(_TMP) {
            And(SENF, 0x01, Local6)
            If(LEqual(Local6, 0x01)) {
                Return(KELA(RTMP()))
            }
            Else {
                Return(0x0b86)
            }
        }
        Method(_SCP, 1) {
            If(Arg0) {
                Store(One, PLCY)
            }
            Else {
                Store(Zero, PLCY)
            }
            Notify(\_TZ.THRM, 0x81)
        }
        Method(STMP, 2) {
            Store(Arg1, DW00)
            If(Arg0) {
                STHY(DB00, DB01, DW00)
            }
            Else {
                STOS(DB00, DB01, DW00)
            }
        }
    }
}

}
/*
HPET: Length=56, Revision=1, Checksum=243,
        OEMID=Nvidia, OEM Table ID=ASUSACPI, OEM Revision=0x42302e31,
        Creator ID=AWRD, Creator Revision=0x98
 */
/*
MCFG: Length=60, Revision=1, Checksum=196,
        OEMID=Nvidia, OEM Table ID=ASUSACPI, OEM Revision=0x42302e31,
        Creator ID=AWRD, Creator Revision=0x0
 */
/*
APIC: Length=152, Revision=1, Checksum=222,
        OEMID=Nvidia, OEM Table ID=ASUSACPI, OEM Revision=0x42302e31,
        Creator ID=AWRD, Creator Revision=0x0
 */


Home | Main Index | Thread Index | Old Index