Samsung enables FOD in TS driver (fod_enable) at all times except
a small number of optical FOD sensor that doesn't have BiometricFeature
.FEATURE_SUPPORT_AOD. As optical type sensor support is not implemented
currently, this HAL is only used on device that has FOD always-on.
This change follows behavior of stock firmware and without toggling of
FOD enable state FOD should be more stable.
Plus it allows setInteractive and config_powerDecoupleInteractiveModeFromDisplay
to function properly with FOD. Currently setInteractive(0) happens before
a onShowFODView (which is the current point to call fod_enable) can be
triggered by the Doze, as TS driver only handles command when it is enabled,
FOD doesn't work when there is a setInteractive(0) that disables TS.
Change-Id: I22291cc62d81ffdaa5edd3f684f9788b0c0650c2
We found that stock firmware calculates the fod rect
from resolution and a set of inscreen fingerprint
sensor position data at boot and then use set_fod_rect
command to tell the Kernel TSP driver.
Then the Kernel TSP driver wrote it to "sponge"
(presumably firmware of touchscreen panel).
It is not yet known what exactly was done with this
data but it is good to keep in line with stock
firmware when we can.
Change-Id: Id44d399a8dc482c7d6f320a3bbfea1282ac4f83a
Signed-off-by: Jesse Chan <jc@lineageos.org>
Enabling sensor on Press is slow and frequent on/off
switching on Press/Release leads to unexpected results.
Looking into Kernel, the purpose of FOD_ENABLE/FOD_DISABLE
commands are to save battery. (ts->lowpower_mode) It is not
meant to handle fingerprint authentication on Press/Release.
It is expected that FOD is in ENABLED state whenever the user
is EXPECTED to use fingerprint authentication soon.
Thus, this patch moved FOD_ENABLE/FOD_DISABLE from
OnPress/onRelease to onShowFODView/onHideFODView so the
fingerprint authentication can be faster and the logic makes
more sense.
Change-Id: Id94b71acd55038d6eda7a1a89dde5fdf5a1e298f
Signed-off-by: Jesse Chan <jc@lineageos.org>
This fixes fingerprint on the SM-A510F and possibly other older Samsung devices when using the new
HIDL implementation
Change-Id: Ie8883d3d628e924a9b181b08681388cd05e5f325