RehabMan / OS-X-BrcmPatchRAM

Broadcom PatchRAM driver for OS X
GNU General Public License v2.0
242 stars 47 forks source link

port tlucks upgrade delay into rehabman code. #63

Open ESProcessing opened 5 years ago

ESProcessing commented 5 years ago

Please review these changes. Added additional delay for: Broadcom BCM94352Z NGFF M.2 WiFi WLAN Bluetooth 4.0 802.11ac up to 867 Mbps card 22*30mm on Lenovo T460.

RehabMan commented 5 years ago

Seems the only change effected here is an IOSleep(0) call at line 165. Because mUpgradeDelay is not initialized until later.

Is that the intention?

ESProcessing commented 5 years ago

That is not the intention. In Tlucks code there are two calls to IOSleep(200). The positions should be in my code, i.e.

t470-mbp:BrcmPatchRAM sjk$ fgrep -A 2 -B 2 tjl * BrcmPatchRAM.cpp-#endif BrcmPatchRAM.cpp- BrcmPatchRAM.cpp:// tjl (sjk) port forward. BrcmPatchRAM.cpp- IOSleep(mUpgradeDelay); BrcmPatchRAM.cpp-

-- BrcmPatchRAM.cpp- DeviceState previousState = kUnknown; BrcmPatchRAM.cpp-#endif BrcmPatchRAM.cpp: // tjl (sjk) port forward. BrcmPatchRAM.cpp- IOSleep(mUpgradeDelay); BrcmPatchRAM.cpp- IOLockLock(mCompletionLock);

Cheers, Scott.

On Feb 27, 2019, at 10:43 PM, RehabMan notifications@github.com wrote:

Seems the only change effected here is an IOSleep(0) call at line 165. Because mUpgradeDelay is not initialized until later.

Is that the intention?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/RehabMan/OS-X-BrcmPatchRAM/pull/63#issuecomment-468125873, or mute the thread https://github.com/notifications/unsubscribe-auth/Aeaub4nGHYCBGrxV9l87DA1kS3ewy_Wwks5vR1B8gaJpZM4bV4BW.

ESProcessing commented 5 years ago

Just looked at and tested the code. It is not the first IOSleep at line 164 of BrcmPatchRam.cpp, that I just commented out in my fork. It is the one at line 1221 that gives me stability across sleep/wake cycles.

ESProcessing commented 5 years ago

Please check my latest fork. I moved the new variable initialization up, and have the two IOSleep call in.

On Feb 27, 2019, at 10:43 PM, RehabMan notifications@github.com wrote:

Seems the only change effected here is an IOSleep(0) call at line 165. Because mUpgradeDelay is not initialized until later.

Is that the intention?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/RehabMan/OS-X-BrcmPatchRAM/pull/63#issuecomment-468125873, or mute the thread https://github.com/notifications/unsubscribe-auth/Aeaub4nGHYCBGrxV9l87DA1kS3ewy_Wwks5vR1B8gaJpZM4bV4BW.

ESProcessing commented 5 years ago

I have been running these changes for 3 weeks without a single drop of BT over many sleep/wake cycles.

bpr_probedelay=200 bpr_upgradedelay=250 bpr_initialdelay=400 bpr_postresetdelay=400

The bpr_upgradedelay=250 is the new delay I ported from TLUCK.