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

Commit 6ba0ce5f authored by Steven Moreland's avatar Steven Moreland
Browse files

RPC Binder: avoid spinnning for partial chunked read

(issues spotted by fmayle@)

I avoided calling poll on sockets, in order to try to
avoid wasting a syscall in some cases.

However, when we simulated a partial read (to avoid
the kernel problems) and there was a partial read of
that as well, it caused CPU spinning.

Just poll every time. It works, and since there's no
busy looping, it's actually much better. We're also
planning on switching the default chunk size to be
larger, so we'd never hit the 2 syscall case normally
anymore.

There is also a log added if a busy spin can happen
again so it's more visible and this logic is quite
complicated.

Bug: 416772676
Test: binderRpcTest
Flag: EXEMPT bugfix
Change-Id: Ia2e6c70a5ec9efd762f7eefa9b8cc30479f395a3
parent a55e0c37
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment