Bluesleep Fix / Deep Sleep Discussion

Search This thread

upndwn4par

Inactive Recognized Developer
Jan 22, 2012
3,640
10,375
New Jersey
This is a thread for the discussion of the bluesleep fix / deep sleep issue specifically for the Motorola Atrix 4g

There is a known issue with some roms that prevents the device from entering the deep sleep cpu state, which is ultimately responsible for a significant reduction in battery life. This is believed to be caused by a glitch in the Bluetooth permission settings. A fix has been developed (known as the bluesleep fix) which is thought to correct the problem, and allow the device to enter deep sleep. It has been suggested that the bluesleep fix will also correct a glitch that prevents the wifi from sleeping. I have not experienced wifi sleep issues myself, so I can’t provide any first-hand knowledge.

Almost everyone who has experienced deep sleep issues and has used the bluesleep fix agrees that it works. I have corrected the problem on my device on CM7, CM9, and CM10 roms. The increase in battery life was dramatic.

However, the bluesleep fix is not without controversy. Many people, including at least one developer, believe the bluesleep fix works and recommends its use. Another developer submitted his version of a fix to CM. There are others, including one whose opinion I respect, that believe there is no reason the fix should work and don’t believe that it does. There have been many recent discussions on the topic on CM9 and CM10 threads that you can search for yourself.

If you have used the bluesleep fix to successfully correct deep sleep issues, or tried the fix and it didn’t work, or strongly believe one way or the other, please share your knowledge and experiences below for the benefit of the community!

[The bluesleep fix is attached (flash with CWM) along with before and after screenshots for a CM9 rom on my device.]

[FYI, I was involved in some of the linked discussions under my former user name (Atrix_FauxG). I thought I should mention this to avoid any confusion.]

[At the time I posted this thread I was unable to determine who created the bluesleep fix. If anyone knows, please inform me so I can give proper credit.]


______________________________________________
Edit:
1) I got confirmation from Th3bill that he wrote bluesleep_fix based on settings from olegfusion. Please take a moment to thank both of them (here and here). The bluesleep_fix file can also be found here (feel free to click on a few ads while you are there to further show your appreciation).
2) I neglected to mention that I observed the greatest increase in battery life on CM9 and CM10 roms.
 

Attachments

  • Bluesleep_fix.zip
    125.8 KB · Views: 3,549
Last edited:

ravilov

Senior Member
Jan 26, 2010
2,217
1,346
localhost
[The bluesleep fix is attached (flash with CWM) along with before and after screenshots for a CM9 rom on my device.]
Or not? :confused:


As for me, my battery life was always very good on the Atrix. At some point I came across this bug and the fix for it and I applied it just to be safe. I know what the fix does (basically it setuids a few bluetooth-related utilities and fixes their ownership) and I guess I can kinda sorta see how it would be possible that that fixes the issue. However I can't say I noticed any big difference in my battery life after applying it.

For the record, I went from stock ROM to CM7-RC3, then to CM7-stable, and am now on ABC.
 
  • Like
Reactions: upndwn4par

boulos

Senior Member
May 7, 2012
95
11
Worked for me. I am using CM7 by the way. Before I implemented the fix, my phone never went into deep sleep. Now it does all the time.
 

NFHimself

Senior Member
Mar 12, 2008
816
469
Mount Pearl
Hmm,

Basically, mount /system rw, and chmod 04755 /system/xbin/hci*.

Not sure what the target rom is, but on my bell I don't have a hcidump. I have a dexdump though.

Cheers!
 

ravilov

Senior Member
Jan 26, 2010
2,217
1,346
localhost
Hmm,

Basically, mount /system rw, and chmod 04755 /system/xbin/hci*.

Not sure what the target rom is, but on my bell I don't have a hcidump. I have a dexdump though.

Cheers!
Yeah, that's not the one. ;)

I think the primary target would be CM7 and all ROMs based on it. I have a CM7 based ROM and I have all three hci* utilities.

And yeah, that's basically it, like I said in my previous post. It setuids all three and sets their ownership to root:shell (0:2000).
 
Last edited:
  • Like
Reactions: newbuss

upndwn4par

Inactive Recognized Developer
Jan 22, 2012
3,640
10,375
New Jersey
As stevendeb25 mentioned above, the primary target was MIUI (CM9).


Yeah, that's not the one. ;)

I think the primary target would be CM7 and all the ones based off it. I have a CM7 based ROM and I have all three hci* utilities.

And yeah, that's basically it, like I said in my previous post. It setuids all three and sets their ownership to root:shell (0:2000).
 
  • Like
Reactions: ravilov
S

Soldier-2Point0

Guest
I got 17 hours deep sleep without the bluesleep fix file. I'm on Epinter's CM10.

Sent from my Nexus 7
 

ravilov

Senior Member
Jan 26, 2010
2,217
1,346
localhost
As stevendeb25 mentioned above, the primary target was MIUI (CM9).
Ah, I see. Yeah, CM7 (GB) has all the proper drivers to support the Atrix hardware fully, my guess is that that's the reason CM7-powered devices are able to enter deep sleep state regardless of permissions and ownership of the Bluetooth utils.

Here's a screenshot of my current state. This is after applying the patch though, so I don't know if it's relevant really, but here it is anyway.
 

Attachments

  • ss.png
    ss.png
    40.6 KB · Views: 1,026

upndwn4par

Inactive Recognized Developer
Jan 22, 2012
3,640
10,375
New Jersey
I never checked while on CM7.0, but for me CM7.2 did not enter deep sleep until I applied the patch.


Ah, I see. Yeah, CM7 (GB) has all the proper drivers to support the Atrix hardware fully, my guess is that that's the reason CM7-powered devices are able to enter deep sleep state regardless of permissions and ownership of the Bluetooth utils.

Here's a screenshot of my current state. This is after applying the patch though, so I don't know if it's relevant really, but here it is anyway.
 
S

Soldier-2Point0

Guest
Epinter's CM10 did not enter deep sleep for me. Though, the last update I applied was 20120729. Maybe he incorporated his own fix I mentioned in the OP in to his rom.

You should try 0803 build. No problems here. Epinter did not include any secret fixes to the rom because he did not mention it in the changelog. No sense in fixing something if you're never going to mention it. The blue sleep fix file is listed on his website, but not included on the rom.

This blue sleep fix file may have been useful on other roms, but is not needed on Epinter CM10.

Sent from my MB860 on CM10
 

upndwn4par

Inactive Recognized Developer
Jan 22, 2012
3,640
10,375
New Jersey
I was on Epinter's 0803 build for a few days this week. No deep sleep without bluesleep fix.

Do you use bluetooth? If you don't leave your BT on then there are no deep sleep problems. I don't turn my BT off ever.

I have spent the last few days on Joker's CM10 and same thing - no deep sleep without fix.



You should try 0803 build. No problems here. Epinter did not include any secret fixes to the rom because he did not mention it in the changelog. No sense in fixing something if you're never going to mention it. The blue sleep fix file is listed on his website, but not included on the rom.

This blue sleep fix file may have been useful on other roms, but is not needed on Epinter CM10.

Sent from my MB860 on CM10
 

xateeq

Senior Member
Oct 19, 2010
786
183
My phone goes to deepp sleep without problem, cm7.2 latest nightly.

Sent from my MB860 using xda app-developers app
 

phordych05

Senior Member
Jul 13, 2010
801
43
philly
will this work for the new jelly bean nightly ( 815 ) ...? using darksides new cm10 a07.2

oh and my phone goes into the sleep of death where i can only pull the battery to fix it...will this work for that...?...thanks in advance... ;)
 

upndwn4par

Inactive Recognized Developer
Jan 22, 2012
3,640
10,375
New Jersey
This will fix the bluesleep problem on any CM7 device, but I don't think it will help your SOD problem and it could (in theory) make it worse. I have never experienced the SOD, but many users have said that increasing the minimum clock speed on your kernel to 456 MHz will help.


will this work for the new jelly bean nightly ( 815 ) ...? using darksides new cm10 a07.2

oh and my phone goes into the sleep of death where i can only pull the battery to fix it...will this work for that...?...thanks in advance... ;)
 

gfeo

Senior Member
Aug 10, 2010
78
13
Rio de Janeiro
How can I revert back after flashing the fix?

What I always do before flashing this kind of CWM zip is extract the flashable .zip, see what files it is going to replace or modify, backup my current version of them, replace the modified versions in the folder with my originals (renaming the originals to the modifieds' name, respectively, if necessary), zip it up, and there you have it! That Revert zip almost always works (never failed for me)! ;)



Sent from my MB860 using Tapatalk 2
 

Top Liked Posts

  • There are no posts matching your filters.
  • 10
    This is a thread for the discussion of the bluesleep fix / deep sleep issue specifically for the Motorola Atrix 4g

    There is a known issue with some roms that prevents the device from entering the deep sleep cpu state, which is ultimately responsible for a significant reduction in battery life. This is believed to be caused by a glitch in the Bluetooth permission settings. A fix has been developed (known as the bluesleep fix) which is thought to correct the problem, and allow the device to enter deep sleep. It has been suggested that the bluesleep fix will also correct a glitch that prevents the wifi from sleeping. I have not experienced wifi sleep issues myself, so I can’t provide any first-hand knowledge.

    Almost everyone who has experienced deep sleep issues and has used the bluesleep fix agrees that it works. I have corrected the problem on my device on CM7, CM9, and CM10 roms. The increase in battery life was dramatic.

    However, the bluesleep fix is not without controversy. Many people, including at least one developer, believe the bluesleep fix works and recommends its use. Another developer submitted his version of a fix to CM. There are others, including one whose opinion I respect, that believe there is no reason the fix should work and don’t believe that it does. There have been many recent discussions on the topic on CM9 and CM10 threads that you can search for yourself.

    If you have used the bluesleep fix to successfully correct deep sleep issues, or tried the fix and it didn’t work, or strongly believe one way or the other, please share your knowledge and experiences below for the benefit of the community!

    [The bluesleep fix is attached (flash with CWM) along with before and after screenshots for a CM9 rom on my device.]

    [FYI, I was involved in some of the linked discussions under my former user name (Atrix_FauxG). I thought I should mention this to avoid any confusion.]

    [At the time I posted this thread I was unable to determine who created the bluesleep fix. If anyone knows, please inform me so I can give proper credit.]


    ______________________________________________
    Edit:
    1) I got confirmation from Th3bill that he wrote bluesleep_fix based on settings from olegfusion. Please take a moment to thank both of them (here and here). The bluesleep_fix file can also be found here (feel free to click on a few ads while you are there to further show your appreciation).
    2) I neglected to mention that I observed the greatest increase in battery life on CM9 and CM10 roms.
    1
    Th3bill first brought it to our attention when building miui

    Sent from my MB860 using xda premium
    1
    [The bluesleep fix is attached (flash with CWM) along with before and after screenshots for a CM9 rom on my device.]
    Or not? :confused:


    As for me, my battery life was always very good on the Atrix. At some point I came across this bug and the fix for it and I applied it just to be safe. I know what the fix does (basically it setuids a few bluetooth-related utilities and fixes their ownership) and I guess I can kinda sorta see how it would be possible that that fixes the issue. However I can't say I noticed any big difference in my battery life after applying it.

    For the record, I went from stock ROM to CM7-RC3, then to CM7-stable, and am now on ABC.
    1
    Hmm,

    Basically, mount /system rw, and chmod 04755 /system/xbin/hci*.

    Not sure what the target rom is, but on my bell I don't have a hcidump. I have a dexdump though.

    Cheers!
    Yeah, that's not the one. ;)

    I think the primary target would be CM7 and all ROMs based on it. I have a CM7 based ROM and I have all three hci* utilities.

    And yeah, that's basically it, like I said in my previous post. It setuids all three and sets their ownership to root:shell (0:2000).
    1
    As stevendeb25 mentioned above, the primary target was MIUI (CM9).


    Yeah, that's not the one. ;)

    I think the primary target would be CM7 and all the ones based off it. I have a CM7 based ROM and I have all three hci* utilities.

    And yeah, that's basically it, like I said in my previous post. It setuids all three and sets their ownership to root:shell (0:2000).