Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 11761e37 authored by Michael Butler's avatar Michael Butler
Browse files

Remove 'blocking' param from NN ResilientPreparedModel and *Buffer

This change removes the 'blocking' parameter for the
ResilientPreparedModel::Factory and ResilientBuffer::Factory. The
'blocking' parameter is only useful for ResilientDevice::Factory, which
behind the scenes chooses between the HIDL calls IDevice::getService and
IDevice::tryGetService. The equivalent calls for IPreparedModel and
IBuffer are not used, as both are created from the IDevice object.

This change also modifies the ResilientDevice's device recovery
behavior. Prior to this change, ResilientDevice's recovery mechanism had
the following behavior:
* attempt to call a function
* if the function did not return a DEAD_OBJECT error, return
* if the function returned a DEAD_OBJECT error, attempt to recover the
  device
* whether or not the recovery succeeded, call the function again

This CL changes the behavior so that if device recovery fails,
ResilientDevice will not call the function the second time.

Bug: N/A
Test: mma
Change-Id: Icf37d05c884c740178324fcd046ea56914ef7d44
parent 98ed9baf
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment