Hi Tim
I googled and found EC code from NTDDK . Can i use that driver for my requirement??? …
Below is the DSDT entry for EC which was received from BIOS team
OperationRegion(LPC0, PCI_Config, Zero, 0xC0)
Field(LPC0, AnyAcc, NoLock, Preserve)
{
Offset(0x8), //Offset(8),
SRID, 8,
Offset(0x80), //Offset(128),
C1EN, 1,
Offset(0x84), //Offset(132),
}
Device(H_EC)
{
Name(_HID, EISAID(“PNP0C09”))
Name(_UID, One)
Method(_CRS, 0, NotSerialized)
{
Name(BFFR, ResourceTemplate()
{
IO(Decode16, 0x0062, 0x0062, 0x00, 0x01)
IO(Decode16, 0x0066, 0x0066, 0x00, 0x01)
})
Return(BFFR)
}
Method(_STA, 0, NotSerialized)
{
Store(One, ECON)
Return(0x0F)
}
Name(_GPE, 0x18)
OperationRegion(ECF2, EmbeddedControl, Zero, 0xFF)
Field(ECF2, ByteAcc, Lock, Preserve)
{
Offset(0xC6), //Offset(198),
BCC1, 16,
BTHV, 8,
Offset(0xD6), //Offset(214),
BTPL, 8,
BTPH, 8,
}
Method(ECMD, 1, Serialized)
{
If(ECON)
{
While(CMDR)
{
Stall(0x14)
}
Store(Arg0, CMDR)
Return(Zero)
}
Else
{
Return(0xFF)
}
}
Device(BAT1)
{
Name(_HID, EISAID(“PNP0C0A”))
Name(_UID, One)
Method(_STA, 0, NotSerialized)
{
If(And(BNUM, One))
{
Return(0x1F)
}
Return(0x0B)
}
Method(_BIF, 0, NotSerialized)
{
Name(xxx, Package(13)
{
Zero, 0x2710, 0x2710, One, 0xFFFFFFFF, 0x03E8, 0x0190, 0x64, 0x64,
“CRB Battery 1”, “Battery 1”, “Real”, “-Real Battery 1-”
})
If(ECON)
{
…
If(B1FC)
{
…
}
}
Return(xxx)
}
}
Name(IGDF, Zero)
Method(_REG, 2, NotSerialized)
{
If(LAnd(LEqual(Arg0, 0x03), LEqual(Arg1, One)))
{
Store(One, ECON)
If(LEqual(LSTE, Zero))
{
Store(Zero, ^^^GFX0.CLID)
}
If(LEqual(LSTE, One))
{
Store(0x03, ^^^GFX0.CLID)
}
Store(LSTE, LIDS)
Store(Zero, BNUM)
Or(BNUM, ShiftRight(And(B1ST, 0x08), 0x03), BNUM)
If(LEqual(BNUM, Zero))
{
Store(VPWR, PWRS)
}
Else
{
Store(RPWR, PWRS)
}
PNOT()
}
}
Method(_Q30, 0, NotSerialized)
{
P8XH(Zero, 0x30)
Store(One, PWRS)
PNOT()
}
Method(_Q31, 0, NotSerialized)
{
P8XH(Zero, 0x31)
Store(Zero, PWRS)
PNOT()
}
}
Device(BIND)
{
Name(_HID, “INT33D2”)
Name(_CID, “PNP0C40”)
Method(_STA, 0, Serialized)
{
If(LGreaterEqual(OSYS, 0x0D))
{
If(And(xxx, One))
{
Return(0x0F)
}
Else
{
Return(0x0B)
}
}
Return(Zero)
}
Method(_DSM, 4, Serialized)
{
Name(_T_0, Zero)
If(LEqual(Arg0, ToUUID(“xxxCF3C5-xxx-xxxx”)}))
{
If(LEqual(Zero, ToInteger(Arg1)))
{
…
}
}
Return(Buffer(One)
{
0x00
})
}
}
I couldn’t figure out how many interface EC exports . Can you plz help me out