[Samsung Galaxy S21 Ultra] srle:
Hi all

JUMP TO STEPS - POST 4

Below explanation what is happening:

have been investigating touchscreen not working after one ui 6.1 update on S21 5G (exynos). Have bought this phone second hand, so no idea if the touchscreen is genuine or not.

I rooted the device to gain access to more info, and what is obvious is that this is related to the latest kernel.

Touch works fine in TWRP and this is the /proc/tsp_msg log from TWRP while touchscreen is working

[ 2.886379] slsi_ts 4-0048 : slsi_ts_probe
[ 2.886389] slsi_ts 4-0048 : sec_input_get_lcd_id: lcd is connected
[ 2.886393] slsi_ts 4-0048 : sec_input_get_lcd_id: lcdtype 0x00A10104
[ 2.886397] slsi_ts 4-0048 : sec_input_parse_dt: lcdtype 0x00A10104
[ 2.886403] slsi_ts 4-0048 : sec_input_parse_dt: not use tsp-icid gpio
[ 2.886416] slsi_ts 4-0048 : sec_input_parse_dt: irq_flag property 0x2008
[ 2.886423] slsi_ts 4-0048 : sec_input_parse_dt: not use tsp-id gpio
[ 2.886486] slsi_ts 4-0048 : sec_input_parse_dt: Sysinput enabled OFF
[ 2.886489] slsi_ts 4-0048 : sec_input_parse_dt: motion aivf OFF
[ 2.886491] slsi_ts 4-0048 : sec_input_parse_dt: motion palm OFF
[ 2.886493] slsi_ts 4-0048 : sec_input_parse_dt : zone's size - indicator:133, navigation:266, edge:341
[ 2.886496] slsi_ts 4-0048 : sec_input_parse_dt: ss_touch_num:0
[ 2.886500] slsi_ts 4-0048 : sec_input_parse_dt: i2c buffer limit: 65535, lcd_id:A10104, bringup:0, id:-2,-2, dex:1, max(4095/4095), FOD:1, AOT:1, ED:1, FLM:0, COB:0, disable_vsync_scan:0, unuse_dvdd_power:0, not_support_temp_noti:0, support_vbus_notifier:0
[ 2.886616] slsi_ts 4-0048 : sec_input_parse_dt: set sec_input_handler_wait_resume_work
[ 2.886623] slsi_ts 4-0048 : sec_tclm_parse_dt: tclm_level 2, sec_afe_base 0115
[ 2.886824] slsi_ts 4-0048 : secure_touch_init
[ 2.886828] slsi_ts 4-0048 : slsi_ts_init: init resource
[ 2.886831] slsi_ts 4-0048 : sec_input_pinctrl_configure: ACTIVE
[ 2.888183] slsi_ts 4-0048 : sec_input_power: on: avdd:on, dvdd:on
[ 2.888738] slsi_ts 4-0048 : slsi_ts_wait_for_ready: 09, 00, 10, 00, 00, 00, 00, 00 [0]
[ 2.888740] slsi_ts 4-0048 : slsi_ts_hw_init: power enable
[ 2.889035] slsi_ts 4-0048 : slsi_ts_hw_init: TOUCH DEVICE ID : 53, 45, 37, 92, 00
[ 2.889610] slsi_ts 4-0048 : slsi_ts_hw_init: TOUCH STATUS : 20 || 00, 02, 01, 00
[ 2.889854] slsi_ts 4-0048 : slsi_ts_read_calibration_report: count:7, pass count:7, fail count:0, status:0xA2
[ 2.889857] slsi_ts 4-0048 : slsi_ts_firmware_update_on_probe: initial firmware update y792_o1.bin, cal:A2
[ 2.889952] slsi_ts 4-0048 : slsi_ts_save_version_of_bin: img_ver of bin = 28.18.1.30
[ 2.889954] slsi_ts 4-0048 : slsi_ts_save_version_of_bin: core_ver of bin = 28.18.1.0
[ 2.889957] slsi_ts 4-0048 : slsi_ts_save_version_of_bin: config_ver of bin = 28.18.1.2
[ 2.890370] slsi_ts 4-0048 : slsi_ts_save_version_of_ic: IC Image version info : 28.18.1.30
[ 2.890613] slsi_ts 4-0048 : slsi_ts_save_version_of_ic: IC Core version info : 28.18.1.0
[ 2.890855] slsi_ts 4-0048 : slsi_ts_save_version_of_ic: IC config version info : 28.18.1.2
[ 2.890858] slsi_ts 4-0048 : slsi_ts_firmware_update_on_probe: skip - fw update
[ 2.891275] slsi_ts 4-0048 : slsi_ts_hw_init: nTX:16, nRX:35, rX:4095, rY:4095, dX:1079, dY:2399
[ 2.891498] slsi_ts 4-0048 : slsi_ts_init_proc: done
[ 2.891931] slsi_ts 4-0048 : slsi_ts_get_custom_library: aod_active_area - top:199, edge:132, bottom:199
[ 2.892304] slsi_ts 4-0048 : sec_input_set_fod_info: vi_event:0, x:16, y:18, size:36
[ 2.892308] slsi_ts 4-0048 : slsi_ts_set_custom_library: Sponge (0x00)
[ 2.892860] slsi_ts 4-0048 : slsi_ts_probe: request_irq = 533
[ 2.892959] slsi_ts 4-0048 : slsi_ts_probe: done

Now same log when you boot to the normal ROM:

[ 2.739169] slsi_ts 4-0048 : slsi_ts_probe
[ 2.739176] slsi_ts 4-0048 : sec_input_get_lcd_id: lcd is connected
[ 2.739180] slsi_ts 4-0048 : sec_input_get_lcd_id: lcdtype 0x00A10104
[ 2.739182] slsi_ts 4-0048 : sec_input_parse_dt: lcdtype 0x00A10104
[ 2.739188] slsi_ts 4-0048 : sec_input_parse_dt: not use tsp-icid gpio
[ 2.739199] slsi_ts 4-0048 : sec_input_parse_dt: irq_flag property 0x2008
[ 2.739206] slsi_ts 4-0048 : sec_input_parse_dt: not use tsp-id gpio
[ 2.739275] slsi_ts 4-0048 : sec_input_parse_dt: Sysinput enabled OFF
[ 2.739278] slsi_ts 4-0048 : sec_input_parse_dt: motion aivf OFF
[ 2.739281] slsi_ts 4-0048 : sec_input_parse_dt: motion palm OFF
[ 2.739285] slsi_ts 4-0048 : sec_input_parse_dt : zone's size - indicator:133, navigation:266, edge:341
[ 2.739288] slsi_ts 4-0048 : sec_input_parse_dt: ss_touch_num:0
[ 2.739294] slsi_ts 4-0048 : sec_input_parse_dt: i2c buffer limit: 65535, lcd_id:A10104, bringup:0, id:-2,-2, dex:1, max(4095/4095), FOD:1, AOT:1, ED:1, FLM:0, COB:0, disable_vsync_scan:0, unuse_dvdd_power:0, not_support_temp_noti:0, support_vbus_notifier:0
[ 2.739354] slsi_ts 4-0048 : sec_input_parse_dt: set sec_input_handler_wait_resume_work
[ 2.739359] slsi_ts 4-0048 : sec_tclm_parse_dt: tclm_level 2, sec_afe_base 0115
[ 2.739557] slsi_ts 4-0048 : secure_touch_init
[ 2.739561] slsi_ts 4-0048 : slsi_ts_init: init resource
[ 2.739563] slsi_ts 4-0048 : sec_input_pinctrl_configure: ACTIVE
[ 2.740917] slsi_ts 4-0048 : sec_input_power: on: avdd:on, dvdd:on
[ 2.741473] slsi_ts 4-0048 : slsi_ts_wait_for_ready: 09, 00, 10, 00, 00, 00, 00, 00 [0]
[ 2.741475] slsi_ts 4-0048 : slsi_ts_hw_init: power enable
[ 2.741743] slsi_ts 4-0048 : slsi_ts_hw_init: TOUCH DEVICE ID : 53, 45, 37, 92, 00
[ 2.742317] slsi_ts 4-0048 : slsi_ts_hw_init: TOUCH STATUS : 20 || 00, 02, 01, 00
[ 2.742561] slsi_ts 4-0048 : slsi_ts_read_calibration_report: count:7, pass count:7, fail count:0, status:0xA2
[ 2.742564] slsi_ts 4-0048 : slsi_ts_firmware_update_on_probe: initial firmware update y792_o1.bin, cal:A2
[ 2.742666] slsi_ts 4-0048 : slsi_ts_save_version_of_bin: img_ver of bin = 28.18.1.31
[ 2.742669] slsi_ts 4-0048 : slsi_ts_save_version_of_bin: core_ver of bin = 28.18.1.0
[ 2.742671] slsi_ts 4-0048 : slsi_ts_save_version_of_bin: config_ver of bin = 28.18.1.2
[ 2.743085] slsi_ts 4-0048 : slsi_ts_save_version_of_ic: IC Image version info : 28.18.1.30
[ 2.743328] slsi_ts 4-0048 : slsi_ts_save_version_of_ic: IC Core version info : 28.18.1.0
[ 2.743571] slsi_ts 4-0048 : slsi_ts_save_version_of_ic: IC config version info : 28.18.1.2
[ 2.743706] slsi_ts 4-0048 : slsi_ts_enter_fw_mode: write ok, enter_fw_mode - 0x57 0x55 0xac
[ 2.783362] slsi_ts 4-0048 : slsi_ts_enter_fw_mode: enter fail! read_boot_status = 0x20
[ 2.783366] slsi_ts 4-0048 : slsi_ts_firmware_update: firmware mode failed
[ 2.783369] slsi_ts 4-0048 : slsi_ts_firmware_update_on_probe: failed, retry=1
[ 2.783493] slsi_ts 4-0048 : slsi_ts_enter_fw_mode: write ok, enter_fw_mode - 0x57 0x55 0xac
[ 2.823536] slsi_ts 4-0048 : slsi_ts_enter_fw_mode: enter fail! read_boot_status = 0x20
[ 2.823543] slsi_ts 4-0048 : slsi_ts_firmware_update: firmware mode failed
[ 2.823551] slsi_ts 4-0048 : slsi_ts_firmware_update_on_probe: failed, retry=2
[ 2.823693] slsi_ts 4-0048 : slsi_ts_enter_fw_mode: write ok, enter_fw_mode - 0x57 0x55 0xac
[ 2.863620] slsi_ts 4-0048 : slsi_ts_enter_fw_mode: enter fail! read_boot_status = 0x20
[ 2.863624] slsi_ts 4-0048 : slsi_ts_firmware_update: firmware mode failed
[ 2.863627] slsi_ts 4-0048 : slsi_ts_firmware_update_on_probe: failed, retry=3
[ 2.863640] slsi_ts 4-0048 : slsi_ts_probe: fail to init hw
[ 2.863643] slsi_ts 4-0048 : slsi_ts_release
[ 2.863704] slsi_ts 4-0048 : slsi_ts_fn_remove
[ 2.902832] slsi_ts 4-0048 : sec_input_power: off: avdd:off, dvdd:off

Notice that in ROM boot there is an attempt and a fail to update the firmware of the touchscreen (newer version 28.18.1.31 > 28.18.1.30) that fails and the touchscreen is turned off

It does not appear as an input device and is not loaded by the OS

On TWRP there is not attempt to do that

I even removed the /vendor/firmware/y792_o1.bin but that did not help

Any ideas what we could do here?

Trick the kernel, modify it somehow to skip the fw update?

Anyway this is more the proof that it is OS level problem on Samsung behalf

Hope this helps