Contribute
Register

[Guide] How to patch DSDT for working battery status

Sorry for the long message. In short this is what I meant
I didn't find a patch applicable to my laptop model (hp envy 4 - 1025tx) for working battery status - in your Laptop DSDT repo.
Based on your guide, example, patching for other models I was able to arrive to a working patch that worked for my model.

I really meant you to look into the patch that I have created and attached with the previous post for any improvements and for inclusion to your patch repository
 
Sorry for the long message. In short this is what I meant
I didn't find a patch applicable to my laptop model (hp envy 4 - 1025tx) for working battery status - in your Laptop DSDT repo.
Based on your guide, example, patching for other models I was able to arrive to a working patch that worked for my model.

I really meant you to look into the patch that I have created and attached with the previous post for any improvements and for inclusion to your patch repository

If you have a completed patch, you can submit it (patch + native DSDT).

Refer to other patches in the repo for how to deal with Store to >32 bit EC fields.

I will not accept incomplete patches to the repo and I won't be finishing it for you...
 
Can't thank you enough for your help, RehabMan. All the info you have in this forum and your github repo has really helped me learn a thing or two. Anywho, I have a couple battery patch submissions for you if they pass muster.

Microsoft Surface Pro 4 (Core i5-6300U / 8GB / 256GB)

Gigabyte P35Xv3 (Core i7-4720HQ / 16GB / 1TB / 1080P)

The only thing I did to the attached DSDTs was error correct. No other patches have been applied, if you would rather have the originals, warts and all, let me know.
 
Last edited:
Can't thank you enough for your help, RehabMan. All the info you have in this forum and your github repo has really helped me learn a thing or two. Anywho, I have a couple battery patch submissions for you if they pass muster.

Microsoft Surface Pro 4 (Core i5-6300U / 8GB / 256GB)

Gigabyte P35Xv3 (Core i7-4720HQ / 16GB / 1TB / 1080P)

The only thing I did to the attached DSDTs was error correct. No other patches have been applied, if you would rather have the originals, warts and all, let me know.

The Gigabyte P35Xv3 patch seems ok (not battery related, but you might want to patch RPM1 and RPM2).

The Microsoft Surface Pro 4 patch creates an error. You might want to check it.
 
The Gigabyte P35Xv3 patch seems ok (not battery related, but you might want to patch RPM1 and RPM2).

The Microsoft Surface Pro 4 patch creates an error. You might want to check it.

I assume those are fan related. I have patched them before, didn't seem to matter temperature wise.

The SP4 patch works for me every time without error so not sure what to say about that.
 
I assume those are fan related. I have patched them before, didn't seem to matter temperature wise.

Good idea to patch it since it may be useful in the future...

The SP4 patch works for me every time without error so not sure what to say about that.

Try with the files you provided... you'll see...
 
Good idea to patch it since it may be useful in the future...



Try with the files you provided... you'll see...

Ok, I'll add it to my guide.


I just tried it with the uploaded files, I don't know if it's because we are set up differently or what, but the patch works perfectly for me. :-/

Take a look.

https://youtu.be/7bGvhv02GwI
 
Ok, I'll add it to my guide.


I just tried it with the uploaded files, I don't know if it's because we are set up differently or what, but the patch works perfectly for me. :-/

Take a look.

https://youtu.be/7bGvhv02GwI

I'm using a newer iasl that detects more errors.

This patch is problematic (and doesn't make sense):
Code:
into_all all code_regex \_SB.PCI0.LPCB.EC0.B1RC removeall_matched;

It translates this line of code:
Code:
            Store (\_SB.PCI0.LPCB.EC0.B1RC, B1SC)

To:
Code:
            Store (\, B1SC)

The resulting code is invalid. The new iasl compiler flags it as an error and no wonder... it is clearly wrong.

Note: I noticed the problem simply by reviewing the changes in the preview window.

When you fix both problems in each of these patches, you can re-submit.
 
I'm using a newer iasl that detects more errors.

This patch is problematic (and doesn't make sense):
Code:
into_all all code_regex \_SB.PCI0.LPCB.EC0.B1RC removeall_matched;

It translates this line of code:
Code:
            Store (\_SB.PCI0.LPCB.EC0.B1RC, B1SC)

To:
Code:
            Store (\, B1SC)

The resulting code is invalid. The new iasl compiler flags it as an error and no wonder... it is clearly wrong.

Note: I noticed the problem simply by reviewing the changes in the preview window.

When you fix both problems in each of these patches, you can re-submit.

Ahhh, my bad. I corrected the Surface Pro 4 patch. I've also added RPM1 and RPM2 to the Gigabyte patch - On 10.10, it didn't make any difference I could detect, but interestingly, I get faster shutdown and restart times with them patched on El Cap.
 

Attachments

  • Gigabyte-P35Xv3.zip
    35.8 KB · Views: 71
  • SurfacePro4-batterypatch.zip
    43.8 KB · Views: 61
Back
Top