init_device() should be used to initialize a session. Reuses existing
session if available.
end_session() explicitly closes any existing session and requests a new
one
lock() enables soft-lock
clear_session() is the equivalent of lock() + end_session()
A new function ensure_unlocked() can be used to open a session and
prompt for PIN and passphrase before further operations.