[Galaxy S 4 i9505 Original Android Development] Advancer:
I went with Ondemand as governor, put the phone to charge and it rebooted within 2 minutes. Here's the latest kmsg:

[ 0.000000] Truncating memory at 0xc0000000 to fit in 32-bit physical address space
[ 0.000000] sec_tsp_mode: LCD_ID = 0x408047, val: 0X408047, ret1: 0x8
[ 0.030761] AXI: msm_bus_fabric_init_driver(): msm_bus_fabric_init_driver
[ 0.031097] MSM_DCVS: msm_dcvs_early_init: Unable to initialize DCVS err=4
[ 0.053527] msm_rpm_get_status(): Status id 433 not defined for target
[ 0.053558] msm_rpm_get_status(): Status id 433 not defined for target
[ 0.053558] msm_rpm_get_status(): Status id 433 not defined for target
[ 0.053558] msm_rpm_get_status(): Status id 433 not defined for target
[ 0.053588] msm_rpm_get_status(): Status id 433 not defined for target
[ 0.053588] msm_rpm_get_status(): Status id 433 not defined for target
[ 0.053588] msm_rpm_get_status(): Status id 433 not defined for target
[ 0.053619] msm_rpm_get_status(): Status id 433 not defined for target
[ 0.156646] sensor_power_on_vdd: done
[ 0.211029] i2c i2c-4: Failed to register i2c client imx135 at 0x10 (-16)
[ 0.211181] i2c i2c-4: Can't create device at 0x10
[ 0.211547] i2c i2c-4: Failed to register i2c client s5k3l1yx at 0x34 (-16)
[ 0.211700] i2c i2c-4: Can't create device at 0x34
[ 0.244354] ion_heap_create: Invalid heap type 3
[ 0.248779] msm_slim_ctrl msm_slim_ctrl.1: Slim-dev:3 report inf element:0x0
[ 0.248992] msm_slim_ctrl msm_slim_ctrl.1: offset:0x0:bit mask:8
[ 0.249298] msm_slim_ctrl msm_slim_ctrl.1: Slim-dev:4 report inf element:0x400
[ 0.249633] msm_slim_ctrl msm_slim_ctrl.1: offset:0x0:bit mask:8
[ 0.326446] Error-Bad Function Input
[ 0.327331] Error-Bad Function Input
[ 0.418640] smd_channel_probe_worker: allocation table not initialized
[ 0.437957] mdm_modem_probe: registered mdm id 0
[ 0.438720] mdm_do_first_power_on:id 0: Powering on modem for the first time
[ 0.450805] msm_slim_ctrl msm_slim_ctrl.1: Slim-dev:2 report inf element:0x400
[ 0.450988] msm_slim_ctrl msm_slim_ctrl.1: offset:0x0:bit mask:8
[ 0.888122] [mdnie lite] start!
[ 0.888336] [mdnie lite] end!
[ 0.903991] hdmi_msm hdmi_msm.1: external_common_state_create: sysfs group ddeec008
[ 0.908752] Inside writeback_driver_init
[ 0.911895] Inside writeback_probe
[ 1.311401] CHARGING MHZ ON 0-0-0-0
[ 1.520416] wcd9xxx_slim_probe: failed to get slimbus tabla-slim logical address: -6
[ 1.647064] msm_otg msm_otg: failed to get phy_clk
[ 1.762298] mtp_function_init: MTP-KTOONSEZ_initS - type:0 ret:0
[ 1.769622] mtp_function_init: MTP-KTOONSEZ_initG - type:0 ret:0
[ 1.850860] couldn't get usb power supply
[ 1.929199] [jc_spi_init:336] Entered
[ 1.932037] [jc_spi_probe:301] Entered
[ 1.935668] [jc_spi_probe:311] jc_spi successfully probed
[ 1.941162] jc_config_isp_irq~~~~~~~~~~
[ 1.944976] msm_eeprom_probe probe_fail
[ 1.954254] msm_sensor_i2c_probe s5k6b2yx probe succeeded
[ 1.958709] msm_eeprom_probe probe_fail
[ 2.017456] mmc0: No card detect facilities available
[ 2.211181] mmc0: msmsdcc_execute_tuning: found good phase = 0
[ 2.216522] mmc0: msmsdcc_execute_tuning: found good phase = 1
[ 2.222351] mmc0: msmsdcc_execute_tuning: found good phase = 2
[ 2.224456] power_supply sec-fuelgauge: driver failed to report `status' property: 4294967274
[ 2.225067] power_supply sec-fuelgauge: driver failed to report `status' property: 4294967274
[ 2.245300] mmc0: msmsdcc_execute_tuning: found good phase = 3
[ 2.250915] mmc0: msmsdcc_execute_tuning: found good phase = 4
[ 2.256774] mmc0: msmsdcc_execute_tuning: found good phase = 5
[ 2.262603] mmc0: msmsdcc_execute_tuning: found good phase = 6
[ 2.268402] mmc0: msmsdcc_execute_tuning: found good phase = 7
[ 2.274200] mmc0: msmsdcc_execute_tuning: found good phase = 8
[ 2.280059] mmc0: msmsdcc_execute_tuning: found good phase = 9
[ 2.285888] mmc0: msmsdcc_execute_tuning: found good phase = 10
[ 2.291717] mmc0: msmsdcc_execute_tuning: found good phase = 11
[ 2.297668] mmc0: msmsdcc_execute_tuning: found good phase = 12
[ 2.303985] mmc0: msmsdcc_execute_tuning: found good phase = 14
[ 2.309173] power_supply sec-charger: driver failed to report `power_now' property: 4294967274
[ 2.309478] mmc0: msmsdcc_execute_tuning: found good phase = 15
[ 2.309509] mmc0: msmsdcc_execute_tuning: finally setting the tuning phase to 8
[ 2.332550] ELEVATOR_INIT: row-0
[ 2.344940] power_supply sec-charger: driver failed to report `power_now' property: 4294967274
[ 2.438354] msm8930_audio_init: Not the right machine type
[ 2.443725] msm_audio_init: Not the right machine type
[ 2.908081] START KTHERMAL
[ 3.122680] Unable to register core for 0
[ 3.130371] sec-battery sec-battery: sec_battery_probe: Failed to Enable Wakeup Source(-6)
[ 3.143585] irda_device_init called!
[ 3.147186] barcode_emul_ice4: probe complete barcode_emul_probe
[ 3.153289] brcm_wlan_power: WL_REG_ON failed to pull up
[ 3.157897] brcm_wlan_power: WL_REG_ON failed to pull down
[ 4.374694] synaptics_rmi4_i2c 3-0020: synaptics_ta_cb: device is in suspend state or reflash.
[ 5.177368] brcm_wlan_power: WL_REG_ON failed to pull up
[ 5.181854] brcm_wlan_power: WL_REG_ON failed to pull down
[ 7.198150] brcm_wlan_power: WL_REG_ON failed to pull up
[ 7.202941] brcm_wlan_power: WL_REG_ON failed to pull down
[ 9.606323] mmc1: msmsdcc_execute_tuning: found good phase = 0
[ 9.611633] mmc1: msmsdcc_execute_tuning: found good phase = 1
[ 9.617187] mmc1: msmsdcc_execute_tuning: found good phase = 2
[ 9.623382] mmc1: msmsdcc_execute_tuning: found good phase = 3
[ 9.629821] mmc1: msmsdcc_execute_tuning: found good phase = 4
[ 9.634979] mmc1: msmsdcc_execute_tuning: found good phase = 5
[ 9.640655] mmc1: msmsdcc_execute_tuning: found good phase = 6
[ 9.647766] mmc1: msmsdcc_execute_tuning: found good phase = 9
[ 9.652770] mmc1: msmsdcc_execute_tuning: found good phase = 10
[ 9.658630] mmc1: msmsdcc_execute_tuning: found good phase = 11
[ 9.664825] mmc1: msmsdcc_execute_tuning: found good phase = 12
[ 9.670501] mmc1: msmsdcc_execute_tuning: found good phase = 13
[ 9.678253] mmc1: msmsdcc_execute_tuning: found good phase = 14
[ 9.683258] mmc1: msmsdcc_execute_tuning: found good phase = 15
[ 9.689147] mmc1: msmsdcc_execute_tuning: finally setting the tuning phase to 2
[ 12.578521] init: /init.qcom.rc: 646: invalid command '/system/bin/log'
[ 12.584350] init: /init.qcom.rc: 717: ignored duplicate definition of service 'fuse_extSdCard'
[ 12.593292] init: /init.qcom.rc: 782: invalid command 'kill'
[ 12.598388] init: /init.qcom.rc: 784: invalid command 'kill'
[ 12.604064] init: /init.qcom.rc: 786: invalid command 'kill'
[ 12.609649] init: /init.qcom.rc: 788: invalid command 'kill'
[ 12.616455] init: init.target.rc: 47: invalid command 'check_fs'
[ 12.621520] init: init.target.rc: 61: invalid command 'check_fs'
[ 12.627532] init: init.target.rc: 90: invalid command 'check_fs'
[ 12.633758] init: init.target.rc: 104: invalid command 'check_fs'
[ 12.647064] init: invalid uid 'fm_radio'
[ 12.912536] power_supply sec-fuelgauge: driver failed to report `status' property: 4294967274
[ 12.924194] power_supply sec-charger: driver failed to report `power_now' property: 4294967274
[ 13.048950] init: cannot open '/initlogo.rle'
[ 13.409637] init: failed to open '/sys/devices/soc0/soc_id'
[ 13.414367] init: failed to open '/sys/devices/soc0/platform_version'
[ 13.420715] init: failed to open '/sys/devices/soc0/hw_platform'
[ 13.426727] init: Detected MSM SOC ID=153 SOC VER=65536 BOARD TYPE=MTP
[ 13.449249] healthd: wakealarm_init: timerfd_create failed
[ 13.455535] init: cannot find '/system/bin/rf4ce', disabling 'rf4ce'
[ 13.460937] init: cannot find '/system/bin/qrngd', disabling 'qrngd'
[ 13.467834] init: cannot find '/system/bin/bintvoutservice', disabling 'TvoutService_C'
[ 13.481536] init: cannot find '/system/bin/imsqmidaemon', disabling 'imsqmidaemon'
[ 13.500854] SET GPU OC-33-450
[ 13.503112] store_scaling_booted call open: 1890000
[ 13.507751] store_scaling_booted call close: 2322000
[ 13.510192] init: cannot find '/system/bin/gsiff_daemon', disabling 'gsiff_daemon'
[ 13.511566] init: property 'sys.powerctl' doesn't exist while expanding '${sys.powerctl}'
[ 13.511596] init: powerctl: cannot expand '${sys.powerctl}'
[ 13.511596] init: property 'sys.sysctl.extra_free_kbytes' doesn't exist while expanding '${sys.sysctl.extra_free_kbytes}'
[ 13.511627] init: cannot expand '${sys.sysctl.extra_free_kbytes}' while writing to '/proc/sys/vm/extra_free_kbytes'
[ 13.586090] mtp_function_bind_config: MTP-KTOONSEZ_mtp_bind_config - type:0 ret:0
[ 13.685028] init: cannot find '/system/bin/quipc_igsn', disabling 'quipc_igsn'
[ 13.700531] init: cannot find '/system/bin/quipc_main', disabling 'quipc_main'
[ 13.710937] init: cannot find '/system/bin/location-mq', disabling 'location_mq'
[ 13.733184] init: cannot find '/system/bin/lowi-server', disabling 'lowi-server'
[ 13.740936] init: cannot find '/system/bin/xtwifi-inet-agent', disabling 'xtwifi_inet'
[ 13.758209] init: cannot find '/system/bin/xtwifi-client', disabling 'xtwifi_client'
[ 14.391754] cpufreq_gov_resume_gov_DENIED:
[ 14.391754] cpufreq_gov_resume_gov_SCHED_DENIED2:
[ 14.757202] [mdnie lite] is negative Mode On = 0
[ 14.757202] [mdnie lite] negative off when resume, tuning again!
[ 14.757232] [mdnie lite] mDNIe_Set_Mode start , mode(0), background(0)
[ 14.757232] [mdnie lite] = UI MODE =
[ 14.757232] [mdnie lite] = STANDARD MODE =
[ 14.757263] [mdnie lite] send tuning cmd!!
[ 14.806915] [mdnie lite] mDNIe_Set_Mode end , mode(0), background(0)
[ 15.219970] init: sys_prop: permission denied uid:1003 name:boot.sfbootcomplete
[ 17.861328] mag_store_hwoffset success
[ 20.503967] diag: proc 1, msg mask update fail -12, tried 419
[ 24.028503] WLDEV-ERROR) wldev_set_country : wldev_set_country: set country for NO as NO rev 4
[ 24.442138] qtaguid: iface_stat: stat_update() wlan0 not found
[ 24.447052] qtaguid: iface_stat: stat_update() wlan0 not found
[ 25.913970] msm_pm_mode_attr_store: spc is blocked (1) from [sh]
[ 25.919433] msm_pm_mode_attr_store: spc is blocked (2) from [sh]
[ 25.925292] msm_pm_mode_attr_store: spc is blocked (3) from [sh]
[ 25.931121] msm_pm_mode_attr_store: spc is blocked (4) from [sh]
[ 25.937469] STORE GOVERNOR ondemand - interactive
[ 25.941986] STORE GOVERNOR ondemand - interactive
[ 25.946502] STORE GOVERNOR ondemand - interactive
[ 25.951019] STORE GOVERNOR ondemand - interactive
[ 26.073486] mpd msm_mpd_attr_slack_time_max_us_store: Error 4 returned when setting algo param slack_time_max_us to 45000
[ 26.084228] mpd msm_mpd_attr_slack_time_min_us_store: Error 4 returned when setting algo param slack_time_min_us to 15000
[ 26.095458] mpd msm_mpd_attr_em_win_size_min_us_store: Error 4 returned when setting algo param em_win_size_min_us to 100000
[ 26.107208] mpd msm_mpd_attr_em_win_size_max_us_store: Error 4 returned when setting algo param em_win_size_max_us to 1000000
[ 26.118927] mpd msm_mpd_attr_online_util_pct_min_store: Error 4 returned when setting algo param online_util_pct_min to 3
[ 26.129486] mpd msm_mpd_attr_online_util_pct_max_store: Error 4 returned when setting algo param online_util_pct_max to 25
[ 26.140380] mpd msm_mpd_attr_em_max_util_pct_store: Error 4 returned when setting algo param em_max_util_pct to 97
[ 26.151397] mpd msm_mpd_attr_mp_em_rounding_point_min_store: Error 4 returned when setting algo param mp_em_rounding_point_min to 10
[ 26.163391] mpd msm_mpd_attr_mp_em_rounding_point_max_store: Error 4 returned when setting algo param mp_em_rounding_point_max to 85
[ 26.166442] init: sys_prop: permission denied uid:1003 name:boot.sfbootcomplete
[ 26.208160] init: sys_prop: permission denied uid:1003 name:service.bootanim.exit
[ 26.330139] init: no such service 'thermal-engine'
[ 26.338714] init: no such service 'mpdecision'
[ 29.552337] init: sys_prop: permission denied uid:1001 name:persist.sys.timezone
[ 30.122131] qtaguid: iface_stat: stat_update() wlan0 not found
[ 30.127044] qtaguid: iface_stat: stat_update() wlan0 not found
[ 33.714324] KTMAX77693-6-1900
[ 33.716491] KTMAX77693-7-1600
[ 33.720581] KTMAX77693-4-1600-100-1900
[ 33.723175] KTMAX77693-5-1600-1900
[ 33.727233] KTMAX77693-1-1600
[ 33.978332] CHARGING MHZ ON 0-0-0-0
[ 35.774810] KTMAX77693-2-1120
[ 35.852569] KTMAX77693-2-1120
[ 44.781799] cpufreq_gov_suspend_gov_DENIED2:
[ 44.781829] cpufreq_gov_suspend_gov_SCHED_DENIED2:
[ 44.859252] dtv_pipe is not configured yet
[ 45.353332] [TouchKey] cypress_touchkey_led_work 417 Touchkey is not enabled.
[ 45.645843] KTMAX77693-2-1600
[ 50.394714] store_UV_mV_table: 18
[ 50.401702] STORE GOVERNOR ondemand - ondemand
[ 50.442840] SET GPU OC-33-450
[ 50.446899] [mdnie lite] scenario_store, input value = 0
[ 50.451477] [mdnie lite] mDNIe_Set_Mode start , mode(0), background(0)
[ 50.458068] [mdnie lite] [ERROR] not ST_DSI_RESUME. do not send mipi cmd.
[ 50.465240] [mdnie lite] set background mode : 4
[ 50.469421] [mdnie lite] mode_store, input background(4)
[ 50.474792] [mdnie lite] mDNIe_Set_Mode start , mode(0), background(4)
[ 50.481323] [mdnie lite] [ERROR] not ST_DSI_RESUME. do not send mipi cmd.
[ 50.488586] [mdnie lite] negative_store, input value = 0
[ 50.493652] [mdnie lite] mDNIe_Set_Negative START
[ 50.498016] [mdnie lite] Negative mode(0) -> reset mode(0)
[ 50.503662] [mdnie lite] mDNIe_Set_Mode start , mode(0), background(4)
[ 50.510009] [mdnie lite] [ERROR] not ST_DSI_RESUME. do not send mipi cmd.
[ 50.516815] [mdnie lite] mDNIe_Set_Negative END
[ 50.521697] [mdnie lite] outdoor value = 0, scenario = 0
[ 50.526672] [mdnie lite] mDNIe_Set_Mode start , mode(0), background(4)
[ 50.533111] [mdnie lite] [ERROR] not ST_DSI_RESUME. do not send mipi cmd.
[ 50.542022] CHARGING MHZ ON 0-0-0-0
[ 50.545227] CHARGING MHZ ON 0-0-0-0
[ 61.036743] init: untracked pid 2751 exited
[ 63.204132] init: untracked pid 2755 exited
[ 75.070648] dpm_run_callback(): platform_pm_suspend+0x0/0x5c returns -16
[ 75.070648] PM: Device alarm failed to suspend: error -16
[ 75.070678] PM: Some devices failed to suspend
[ 87.386047] Freezing of user space aborted

No errors detected