[Galaxy Note 4 Original Android Development] dl12345:
RELEASE NOTES VERSION 0.3

Telephony

A workaround for the muted incall audio has been created. This is a small binary that gets run by an init.d script at boot time. This workaround eliminates the need to use a patched Dialer app.

The bug causing the SMS "not sent" error has been fixed. The Ericsson Thor M7450 modem sends spurious trailing bytes in the RIL_SMS_Response which needs to be ignored

Long SMS messages are now sent as multiple SMS messages instead of a single MMS

A bug in the AudioHAL causing wideband calls to be treated as narrowband and resulting in garbled audio has been fixed

The default LineageOS apns-conf.xml has been replaced by the more up-to-date and complete Google master version

If you installed Google Dialer and then flashed the modifed dialer app to fix muted incall audio then you MUST reflash OpenGapps after installing this ROM. OpenGapps automatically removes the Dialer app on bootup and since the modified Dialer app removed Google Dialer on installation, when you boot and OpenGapps removes the stock dialer, you will have no Dialer app.

PowerHAL

The generic Samsung PowerHAL was completely buggy and non-functional and battery profiles simply did not work. The PowerHAL has undergone a rewrite and is now fully functional. As part of the rewrite, you should find that the battery saving profile produces better performance at the cost of a slight increase in battery consumption.

CPU governor

You SHOULD NOT replace the interactive governor with any other governor using kernel auditor or other software. The PowerHAL is dependent on the interactive governor and changing it to a different governor will break the battery power profile settings. A properly tuned interactive governor is probably the best governor anyway, so there is no need to change.

The scaling_max_freq or the maximum cpu speed for ther BIG cluster has been capped at 1.7GHz instead of 1.9GHz. The power envelope of the Cortex A57 is such that it can only sustain 1.9Ghz for literally seconds until thermal throttling kicks in, which then reduces the clock speed to a much lower level to dissipate heat. The 1.7Ghz cap gives better overall sustained performance since it causes less thermal throttling. The maximum 1.9Ghz frequency is largely useless and counterproductive.

When a heavy load is placed on the cpu, the governor will immediately scale it to hispeed_freq, at which point it will pause for a specified number of milliseconds before jumping to the next frequency. Samsung had set this artificially high, which impacts the perceived snappiness of the ROM. This delay has been reduced from 59000 ms to 20000 ms, resulting in a snappier user interface.

A set of scripts has been added to /system/etc/init.d and /system/etc/governor if you wish to override governor settings at boot time. The default governor configuration and an experimental governor configuration are included but disabled.

The experimental governor has substantially better performance but since it is experimental I have not made it the default. Click the button below to see the improved app launch times versus the default governor (in milliseconds). This is a series of 10 cold app launches and the eventual average launch time.

APP	Chrome	Youtube	Open Camera
Default	DL	Δ	Default	DL	Δ	Default	DL	Δ
555	441	1,161	1,270	956	611
521	435	1,430	979	735	662
458	500	1,238	878	704	693
493	483	1,148	1,250	676	663
549	417	1,770	1,160	797	745
463	468	1,159	1,560	783	676
493	500	1,178	972	801	694
497	424	1,128	933	816	650
526	490	1,145	1,170	797	686
545	503	1,970	880	744	665
AVERAGE	510	466	-8.61%	1,333	1,105	-17.07%	781	675	-13.63%

Hotplugging

Support for hotplugging has been implemented but is disabled by default. Please see the script in the init.d folder and uncomment the line to enable. Hotplug scripts live in /etc/hotplug and are named as <event type>.agent. They must be executable. There is an example script available.

DRM/Netflix

Widevine L1 DRM is now working properly and recognized as valid. If you use Magisk and Magisk Hide in conjunction with the Props module, you can get Google Play to recognize your device as certified and download the Netflix app. I still haven't been able to get it to play at rates greater than 1750Kbps. The Netflix app is very restrictive and the stock SM-N910C is not a certified Netflix HD device (other versions of the Note 4 with the Qualcomm Snapdragon are able to stream Netflix HD). To get it working, not only is Widevine L1 required (done), but you also need to be a certified device for Play Store (done using Magisk Hide and Props) and a Netflix recognized device (not done). The OMX AAC codec has been removed as this was causing streaming apps to hang

Casting

Various build.prop changes and p2p_supplicant changes have been implemented and casting should now work without needing to modify anything yourself. I cannot test this as I don't have the necessary hardware.

GPS

Folder location and permissions have been corrected that now allow GPS and LHD to talk to each other, so GPS should be less quirky.

Kernel

The kernel cpufreq drivers have been modified to save and restore maximum and minimum scaling frequency. This is necessary to achieve a properly functioning PowerHAL.

The driver has also been modified to send cpu uevent ONLINE messages that ueventd can process as previously ueventd was not setting sysfs permissions properly when cpus were hotplugged. The Samsung cpu drivers offline the big cluster whenever the display is turned off, which previously would reset any caps to the physical maximum and minimum, invalidating any attempt to cap cpu frequency (which is necessary for the power saving profile).

Post-installation Issues

Google Now voice search. If setup at boot it causes very high CPU usage. Configure it after you have rebooted following the initial installation. Note that it persistently causes cpu usage of 10% - 15% when the screen is active.

Media Scanner (android.process.media) will go bananas after first installation and use high cpu for a while. It is scanning and indexing media. It will stop after a while. If you still have problems with it then you probably have a LOT of media or some corrupted files on your sdcard. You could also clear out your thumbnails folders.

See the full CHANGELOG in the first post.

Other

I still have not tracked down the issues with the rotation sensor and proximity sensor. The rotation issued happened to me once and I could neither duplicate it again nor see anything in the logs. Unfortunately my proximity sensor seems to be completely non-functional. I replaced the hardware module (it's on the front camera board) with one from a spare parts Note 4 that I have, but unfortunately that part had a non-functional camera so I am stuck with my broken proximity sensor. It would help if someone could get a full "logcat -b all" and a dmesg output while trying to use the proximity sensor. Also test it using Sensors Test app and try to recalibrate it using Proximity Sensor Reset/Repair app.