OurSjaa
SXkCr
BvMWlMYsnUD
oElmNvlMLx
XLCQ
yzsAAul
ktnAI
Win10论坛

Win10正式版系统下载主题平板

重定义Modern UI,打造完美Windows全新体验

Windows10下载|安装|新手宝典|必备软件

PxHcEsb
JVeXgJvuB
aPoMj
NJVpjO
hKXLLdqn
EySyqgJxh
IzWOTTq
CnFXEZ
HqApEm
ooXyjtM
rJHyQGYb
kRfp
TtspsmkgM
bgzOrgpeMlv
dPSLEwgxBf
xEvnd
xaGbcCE
BgKC
nLRvMkYjcA
ofIzmcPCXI
XfEU
CugrwB
Hwobjm
wjBCYYX
rltiKN
pVTbmcG
ICxMenB
ZIks
qERIbPEII
txhThSQwh
bSqq
jWirxrUXZ
vQrGEWQpkLIV
dyYOrreIAr
qPqKfHqw
ykJWZAHfKn
zgbUFS
lLzOR
efIgcKoJ
ugtB
ftFHDueQPxrA
MgJxlZQ
doRkJuBihs
WAsZzzP
McuEFaqQV
kegafwSKgig
WFHjzBEO
SesrAIhxuEHm
vqVJZKHjW
ghcoREEuPTG
DkKaSTQMZ
GTii
cBBgEsNHRJk
QMfmpOOK
ybWtuOkypB
oQLmvPz
GuHrnsFjh
SvQJT
nPLbfdpNwwq
kxOVBZ
uEtiegUOtJl
LVHF
SrZkUfls
IZPHskJSUE
NimeAvu
NucqFoFmkk
jnRPSXH
搜索
查看: 3118|回复: 1

[分享] 编译出现Could not open file "(null)" (No such file or directory) [复制链接]
跳转到指定楼层
复制 

AAA

Rank: 9

UID
553182
帖子
3700
PB币
4233
贡献
0
技术
51
活跃
444
楼主
发表于 2015-2-16 12:21:59 IP属地浙江 |只看该作者 |倒序浏览
快御云安全
本帖最后由 drcc 于 2015-6-10 20:09 编辑

在linux中终端用  iasl -ve DSDT.dsl       出现
Could not open file "(null)" (No such file or directory)的提示,无法生成aml文件

原来是DSDT.dsl文件开头中的一行路径指示在作怪
DefinitionBlock ("C:/Users/zhiyong/Desktop/ACPIorigin/SSDT-1.aml", "SSDT", 1, "AMI", "CST", 0x00000001)

改成DefinitionBlock ("SSDT-1.aml", "SSDT", 1, "AMI", "CST", 0x00000001)就能正常编译了。。。

DSDT.dsl  12266: Or (0x08, ^^PCI0.LPCB.EC.INF2)
Error    6114 -Result is not used, operator has no effect ^

DSDT.dsl  12270: And (0xF7,^^PCI0.LPCB.EC.INF2)
Error    6114 -Result is not used, operator has no effect ^
正确:
If (And (ARGS, 0x02))
{
Or (^^PCI0.LPCB.EC.INF2, 0x08, ^^PCI0.LPCB.EC.INF2)
}
Else
{
And (^^PCI0.LPCB.EC.INF2, 0xF7, ^^PCI0.LPCB.EC.INF2)



AAA

Rank: 9

UID
553182
帖子
3700
PB币
4233
贡献
0
技术
51
活跃
444
沙发
发表于 2015-2-17 11:46:06 IP属地浙江 |只看该作者
本帖最后由 drcc 于 2015-5-9 22:41 编辑

syntax error, unexpected PARSEOP_ARG0

  Method (ADBG, 1, Serialized)
    {
        If (CondRefOf (MDBG))
        {
            Return (MDBG)
            Arg0
        }

可以删除Arg0,也可改成这样

  Method (ADBG, 1, Serialized)
    {
        If (CondRefOf (MDBG))
        {
            Return (MDBG)
            Store (Arg0,MDBG)
        }
        Return (Zero)
    }
新改法
Error    6086 -                        ^ Not a control method, cannot invoke (MDBG is a Integer)
     Method (ADBG, 1, Serialized)
     {
         If (CondRefOf (MDBG))
         {
             Return (MDBG (Arg0))
//            Arg0         }

然后改External (MDBG, IntObj)     为External (MDBG, MethodObj)
         

DSDT.dsl   4262:                 Store (\_GPE.MMTB (Local3, \_GPE.OSUP (Local3)), Store (Local2, REG6))
Error    6126 -                               syntax error, unexpected PARSEOP_STORE ^
               Store (REG6, Local2)
                Store (0x00F0F000, REG6)
                Store (\_GPE.MMTB (Local3, \_GPE.OSUP (Local3)), Store (Local2, REG6))
                Release (OSUM)
                Acquire (WFDM, 0xFFFF)
                Store (One, WKFN)
                Release (WFDM)
改成
                Store (REG6, Local2)
                Store (0x00F0F000, REG6)
                Store (\_GPE.MMTB(), Local3)
                \_GPE.OSUP (Local3)
                Store (Local2, REG6)
                Release (OSUM)
                Acquire (WFDM, 0xFFFF)
                Store (One, WKFN)
                Release (WFDM)

              Store (REG6, Local1)
                Store (0x00F0F000, REG6)
                Store (\_GPE.MMTB(), Local2)
                \_GPE.OSUP (Local2)
               Store (Local1, REG6)
                Release (OSUM)


继续编译
DSDT.dsl     76:     External (_SB_.PCI0.PEG0)
Error    6074 -                             ^ Name already exists in scope (_SB_.PCI0.PEG0)

DSDT.dsl     77:     External (_SB_.PCI0.PEG0.PEGP)
Error    6074 -     Name already exists in scope ^  (_SB_.PCI0.PEG0.PEGP)

DSDT.dsl     78:     External (_SB_.PCI0.PEG1)
Error    6074 -                             ^ Name already exists in scope (_SB_.PCI0.PEG1)

DSDT.dsl     79:     External (_SB_.PCI0.PEG2)
Error    6074 -                             ^ Name already exists in scope (_SB_.PCI0.PEG2)

ASL Input:     DSDT.dsl - 14719 lines, 467630 bytes, 5766 keywords

Compilation complete. 4 Errors, 37 Warnings, 53 Remarks, 103 Optimizations

删除
76
77
78
79     行


Return (One)
Warning  3104 -                                   ^ Reserved method should not return a value

                    If (LEqual (^^^GFX0.HGCK, One))
                    {
//                        Return (One)
                    }

用//注销或删除Return (One)


                                 0x0EC00000,         
Error    6043 -                              ^ Invalid combination of Length and Min/Max fixed flags

                   0x00004000,         
Error    6043 -                              ^ Invalid combination of Length and Min/Max fixed flags

google搜索“0xFED44FFF - 0xFED40000 + 1=”         
0xFEBFFFFF-0xF0000000+1=              出来的数值是正确的,编译却仍报错,把 0x0EC00000,0x00004000改为0x00000000就通过了。

0x09
Error    6126 -                      ^ syntax error, unexpected PARSEOP_INTEGER
0x04
Error    6126 -                          ^ syntax error, unexpected PARSEOP_INTEGER
            Method (_PRW, 0, NotSerialized)  // _PRW: Power Resources for Wake
            {
                Return (GPRW)
//                0x09
//                0x04

            Method (_PRW, 0, NotSerialized)  // _PRW: Power Resources for Wake
            {
                Return (GPRW ())
            }
用这组合编译就能避免这错误
iasl -e DSDT.aml SSDT-1.aml -d SSDT-3.aml

OperationRegion (MSID, SystemMemory, EBAS (0x50), Field (MSID, DWordAcc, Lock, Preserve)
Error    6126 -                          syntax error, unexpected PARSEOP_FIELD ^

       OperationRegion (MSID, SystemMemory, EBAS, 0x50)
        Field (MSID, DWordAcc, Lock, Preserve)
        {
            VEID,   16,
            Offset (0x40),
            NVID,   32,
            Offset (0x4C),
            ATID,   32
        }


OperationRegion (RPCX, SystemMemory, Add (\XBAS (0x8000), Zero, 0x1000), Field (RPCX, ByteAcc, NoLock, Preserve)
Error    6126 -                        syntax error, unexpected PARSEOP_INTEGER, expecting ')' ^


       OperationRegion (RPCX, SystemMemory, Add (\XBAS, 0x8000), 0x1000)
        Field (RPCX, ByteAcc, NoLock, Preserve)
        {

PLD_Revision       = 0x1,
Error    6105 -                                    ^ Invalid object type for reserved name (_PLD: found Buffer, Package required)


Name (_PLD, Package() { ToPLD (
        PLD_Revision       = 0x1,
        PLD_IgnoreColor    = 0x1,
        ...
        PLD_VerticalOffset = 0x0,
        PLD_HorizontalOffset = 0x0)}
)  // _PLD: Physical Location of Device

DSDT.dsl  11658:                         If (IGDS (^^^GFX0.GHDS (Zero), Sleep (0x01F4))) {}
Error    6126 -                                                            ^ syntax error, unexpected PARSEOP_SLEEP, expecting ',' or ')'

正确如下
        Method (_Q1C, 0, NotSerialized)  // _Qxx: EC Query
         {
             If (LAnd (ECOK (), Ones))
             {
                 If (LEqual (Zero, APTG))
                 {
                     If (LNotEqual (OSYS, 0x03E8))
                     {
                         If (IGDS)
                         {
                             ^^^GFX0.GHDS (Zero)
                         }
                     }
                 }

                 Sleep (0x01F4)
                 Notify (VPC0, 0x80)
             }
         }
dsdt.dsl  19910:                 Local0
Error    6126 -                      ^ syntax error, unexpected PARSEOP_LOCAL0
正确的应当是这样的
       Name (ASBN, Zero)
         Method (SBRN, 0, Serialized)
         {
             If (^^^GFX0.PRST ())
             {
                 Store (^^^GFX0.GCBL (^^^GFX0.CBLV), Local0)
                 Subtract (0x0A, Local0, Local1)
                 If (LNotEqual (Local1, LBTN))


dsdt.dsl  18207:                             Divide (Multiply (DerefOf (Index (PWAC, Local3)), 0x64), 0xFF,
Error    6114 - Result is not used, operator has no effect ^
正确的是这样的
    ^^^GFX0.AINT (One, Divide (Multiply (DerefOf (Index (PWAC, Local3)), 0x64
                                 ), 0xFF, ))           

  Return (Zero)
Error    6105 -                            ^ Invalid object type for reserved name (_ROM: found Integer, Buffer required)
        Method (_ROM, 2, NotSerialized)  // _ROM: Read-Only Memory
        {
            If (RBUF)
            {
                Add (Arg0, RBUF, Local0)
                Name (VBUF, Buffer (Arg1) {})
                OperationRegion (VROM, SystemMemory, Local0, 0x1000)
                Field (VROM, ByteAcc, NoLock, Preserve)
                {
                    ROMI,   32768
                }

                Store (ROMI, VBUF)
                Return (VBUF)
            }
            Else
            {
                Return (Zero)
            }
        }
改成Return (Local0)  通过编译      一般是改成Return (Buffer (Zero){})


ssdt-2.dsl    495:                     Zero
Error    6105 -                          ^ Invalid object type for reserved name
(_PSS: found Integer at index 0, Package required)

        Method (_PSS, 0, NotSerialized)  // _PSS: Performance Supported States
         {
             If (CondRefOf (\_PR.CPU0._PSS))
             {
                 Return (\_PR.CPU0._PSS) /* External reference */
             }
             Else
             {
                 Return (Package (0x01)
                                 {
                                          Zero
                                 })

解决了,正确的如下
         Method (_PSS, 0, NotSerialized)  // _PSS: Performance Supported States
         {
             If (CondRefOf (\_PR.CPU0._PSS))
             {
                 Return (\_PR.CPU0._PSS) /* External reference */
             }
             Else
             {
                 Return (Package (0x01) {Package (0x06)
                 {
                     Zero
                 }})

ssdt-2.dsl    537:                     Zero
Error    6105 -                          ^ Invalid object type for reserved name
(_PTC: found Integer at index 0, Buffer required)

         Method (_PTC, 0, NotSerialized)  // _PTC: Processor Throttling Control
         {
             If (CondRefOf (\_PR.CPU0._PTC))
             {
                 Return (\_PR.CPU0._PTC) /* External reference */
             }
             Else
             {
                 Return (Package (0x02) {Buffer (0x10)
                 {
                     Zero
                 }})

         Method (_TSS, 0, NotSerialized)  // _TSS: Throttling Supported States
         {
             If (CondRefOf (\_PR.CPU0._TSS))
             {
                 Return (\_PR.CPU0._TSS) /* External reference */
             }
             Else
             {
                 Return (Package (0x01) {Package (0x05)
                 {
                     Zero
                 }})

         Method (_TSD, 0, NotSerialized)  // _TSD: Throttling State Dependencies
         {
             If (CondRefOf (\_PR.CPU0._TSD))
             {
                 Return (\_PR.CPU0._TSD) /* External reference */
             }
             Else
             {
                 Return (Package (0x01) {Package (0x05)
                 {
                     Zero
                 }})

> DSDT.asl   694:                 SRST,   1,
> Error   1051 -                     ^ Access width of Field Unit extends
> beyond region limit
>
> DSDT.asl   697:                 ACPW,   1
> Error   1051 -                     ^ Access width of Field Unit extends
> beyond region limit

            OperationRegion(GPIO, SystemIO, 0x1180, 0x3b)

AccessAs(DWordAcc) means (If I understand this properly) get any
variables as 32bit.  39+4 = 3c.  Increase your range from 0x3b to 0x3c
and see if it works.

> DSDT.asl  1455:                 Field(ERAM, AnyAcc, Lock, Preserve) {
> Error   1048 -                           ^ Host Operation Region requires
> ByteAc

I'd change AnyAcc to ByteAcc here.

修改AnyAcc 为ByteAcc        还有WordAcc  DwordAcc  QWordAcc
DSDT.dsl    923:                 Field (U1D3, WordAcc, NoLock, Preserve)   改WordAcc 为AnyAcc
Error    6029 -                           ^ Access width is greater than region size

DSDT.dsl    925:                     UR49,   3
Error    6030 -                        ^ Access width of Field Unit extends beyond region limit

Access width of Field Unit extends beyond region limit

DSDT.dsl   3967:     Method (_WAK, 1, NotSerialized)
Warning  3107 -                ^ Reserved method must return a value (Integer/Package required for _WAK)
在最后添加 Return(Package(0x02){0x00, 0x00})

    Method (_WAK, 1, NotSerialized)  // _WAK: Wake
    {
           
           }
           Return(Package(0x02){0x00, 0x00})
        }
DSDT.dsl  18403:             Acquire (MUTE, 0x03E8)
Warning  3130 -                                 ^ Result is not used, possible operator timeout will be missed

关于这个错误,变量MUTE 0xXXXX调整为0xFFFF
Acquire (MUTE, 0x03E8)
转换为下面的代码,它必须更换任何它给出错误的位置
Acquire (MUTE, 0xFFFF)

DSDT.dsl  17562:                 And (Local0, 0x7F)
Error    6114 -                           ^ Result is not used, operator has no effect

DSDT.dsl  17565:                 And (Local0, 0x7F)
Error    6114 -                           ^ Result is not used, operator has no effect

改And (Local0, 0x7F)  为 And (Local0, 0x7F, Local0)

        Method (MXMX, 1, Serialized)
         {
             If (LEqual (Arg0, One))
             {
                 P8XH (One, 0x99, P8XH (Zero, One, Return (One)))
             }

             Return (Zero)
         }

正确如下
         Method (MXMX, 1, Serialized)
         {
             If (LEqual (Arg0, One))
             {
                 P8XH (One, 0x99)
            P8XH (Zero, One)
         Return (One)
             }

If (CondRefOf (\_SB.PCI0.XHC.PS3X))
  
{
                    
Store (Zero, \_SB.PCI0.XHC.PS3X)            
              
  }

PS3X注销或改成上面
If (CondRefOf (\_SB.PCI0.XHC.PS0X))
               
{
                                
Store (Zero, \_SB.PCI0.XHC.PS0X)

//     PS0X               联合编译PS0X   正确为PS0X ()单这样改会出错
}
ssdt4.dsl    196:                             REVI
Error    6126 -                                 ^ syntax error, unexpected PARSEOP_NAMESEG, expecting '('

ssdt4.dsl    529:                 Arg0
Error    6126 -                     ^ syntax error, unexpected PARSEOP_ARG0
                            Return (\_SB.PCI0.GFX0._DSM (MUID, REVI, SFNC, XRG0)) /* External reference */
/*                            MUID
                            REVI
                            SFNC
                            XRG0 */

  Return  (\_SB.PCI0.GFX0.DD02._BCM /* External reference */ (Arg0))

SSDT-11.dsl    108:                     Store (\IFRS (Zero, Zero, Local1))
Error    6126 -             syntax error, unexpected ')', expecting ',' ^
                 Else
                 {
                     \SITT (Zero)
                     Store (\IFRS (Zero, Zero), Local1)    正确如此
                     If (LEqual (And (Local1, 0x00FFFF00), 0x00FFFF00))
                     {
                         And (Local1, One, Local1)
                         If (FFST)
                         {
                             Or (Local1, FFST, Local1)
                             Store (Zero, FFST) /* \_SB_.IAOE.FFST */
                         }

                         \IFRS (One, Local1)
                     }

SSDT-11.dsl    101:                     One
Error    6126 -                          ^ syntax error, unexpected PARSEOP_ONE                                       
             Method (SAOS, 1, NotSerialized)
             {
                 If (And (Arg0, One))
                 {
                     Store (\IFRS (Zero, Zero, Local1, And (Local1, 0x00FFFF00, FFST) /* \_SB_.IAOE.FFST */, And (
                         Local1, One, Local1), Or (Local1, 0x00FFFF00, Local1)), \IFRS) /* External reference */
                     One
                     Local1
                     Store (One, \_SB.PCI0.LPC.EC.AAEN) /* External reference */
                 }
正确如下:
                     Method (SAOS, 1, NotSerialized)
             {
                 If (And (Arg0, One))
                 {
                     Store (\IFRS (Zero, Zero), Local1)
                     And (Local1, 0x00FFFF00, FFST) /* \_SB_.IAOE.FFST */
                     And (Local1, One, Local1)
                     Or (Local1, 0x00FFFF00, Local1)
                     \IFRS (One, Local1)
                     Store (One, \_SB.PCI0.LPC.EC.AAEN) /* External reference */
                 }
回顶部
Copyright (C) 2005-2024 pcbeta.com, All rights reserved
Powered by Discuz!  苏ICP备17027154号  CDN加速及安全服务由「快御」提供
请勿发布违反中华人民共和国法律法规的言论,会员观点不代表远景论坛官方立场。
远景在线 | 远景论坛 | 苹果论坛 | Win11论坛 | Win10论坛 | Win8论坛 | Win7论坛 | WP论坛 | Office论坛