• Benjamin Berg's avatar
    lib: Remove state from fp_img_driver activate handler · 4cec2841
    Benjamin Berg authored
    The state was always AWAIT_FINGER and it was never used by any driver
    (except for error checking). So remove it, in particular as a correct
    state change will be done after activation anyway.
    
    The only driver with code that actually did anything based on this was
    the URU4000 driver. However, all it did was an explicit state change
    execution. This is not necessary, as the state_change handler is called
    anyway (i.e. we now only write the AWAIT_FINGER register once rather
    than twice).
    
    Manual changes plus:
    
    @ init @
    identifier driver_name;
    identifier activate_func;
    @@
    struct fp_img_driver driver_name = {
        ...,
        .activate = activate_func,
        ...,
    };
    @ remove_arg @
    identifier dev;
    identifier state;
    identifier init.activate_func;
    @@
    activate_func (
    	struct fp_img_dev *dev
    -	, enum fp_imgdev_state state
    	)
    {
    	<...
    -	if (state != IMGDEV_STATE_AWAIT_FINGER_ON) { ... }
    	...>
    }
    4cec2841
Name
Last commit
Last update
demo Loading commit data...
doc Loading commit data...
examples Loading commit data...
libfprint Loading commit data...
.gitignore Loading commit data...
.gitlab-ci.yml Loading commit data...
AUTHORS Loading commit data...
COPYING Loading commit data...
HACKING.md Loading commit data...
INSTALL Loading commit data...
NEWS Loading commit data...
README Loading commit data...
THANKS Loading commit data...
TODO Loading commit data...
meson.build Loading commit data...
meson_options.txt Loading commit data...