Contribute
Register

Need help with Laptop DSDT Edit, I Don't understand the guide..

Status
Not open for further replies.
I Am working on the fields FWBT, SMDA, BMN0, and BDN0, but how would i find the offsets of those?

The offset of any field is the offset of the prior field plus the prior field's size, plus the offset of the EC region.

Remember: Offsets are in bytes. Sizes are in bits.

For example:
Code:
            OperationRegion (ERAM, EmbeddedControl, [B]Zero[/B], 0xFF)
            Field (ERAM, ByteAcc, Lock, Preserve)
            {
...
                Offset ([B]0x12[/B]), 
                FUSL,   8, 
                FUSH,   8, 
                FWBT,   64,

The starting offset for the EC region is Zero (most are, but it is not always zero).

The Offset(0x12) makes FUSL at offset 0x12.

So, Zero+0x12+1+1 = 0x14.

FWBT is at offset 0x14 (decimal 20).
 
So , as a example, what is the math for :
Offset (0x12), FUSL, 8,
FUSH, 8,
FWB1,64,//FWBT,64,
Edit: Nevermind, just saw your post. lolz forgot to refresh page.
 
so to patch the object does not exist, i would use the patch, as a example:
into method label MHIF code_regex \(FWBT, replaceall_matched begin (RECB(0x14,64), end; ??
 
so to patch the object does not exist, i would use the patch, as a example:

Yes.

It doesn't exist because we renamed it. We renamed it just so we could have the compiler point out all the code that needs patching.
 
What would i do if the starting offset was something like 0x5D?
I can't figure out this one:
Offset (0x5D), EXSI, 8,
EXSB, 8,
EXND, 8,
SMPR, 8,
SMST, 8,
SMAD, 8,
SMCM, 8,
SMD1,256,//SMDA,256,
BCNT, 8,
SMAA, 8,
SAD0, 8,
SAD1, 8,
 
What would i do if the starting offset was something like 0x5D?
I can't figure out this one:

It is just counting:

Offset (0x5D),
EXSI, 8, //0x5d
EXSB, 8, //0x5e
EXND, 8, //0x5f
SMPR, 8, //0x60
SMST, 8, //0x61
SMAD, 8, //0x62
SMCM, 8, //0x63
SMD1,256,//0x64 //SMDA,256,
...

Or as we know from the previous example:
Zero+0x5d+7=0x64
 
THANK BOB! i finished! lolz. thanks for the help!
 
THANK BOB! i finished! lolz. thanks for the help!

If you have completed a patch for your laptop, please submit it in the battery patching thread.
 
Hate to ask, but how would i submit it? would i submit the whole dsdt? or if not, how would i just extract the patch from the dsdt?
 
Status
Not open for further replies.
Back
Top