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

Skip to content
Commit 3baa0daa authored by Sai Chaitanya Kaveti's avatar Sai Chaitanya Kaveti
Browse files

msm: mhi_dev: Avoiding delay in transfer completion



When size of user client buffer is smaller than the size of data read,
client calls the mhi_uci_client_read API for the second time with the
remaining bytes of data to be copied. In this, data is already read
from host but copying to client buffer is pending. With the current
logic device waits for read_wq and then eventually exits as there is
no data to read from host. This is causing a delay in the transfer
completion in the case where user client buffer is less than data read
from host.

To avoid this delay, entering the loop to read data from host only if
it is a new transfer. For old transfers, as read from host is already
done, waiting for read_wq is avoided with this change.

Change-Id: I75b6f6e3673cf5c05693579acaddf189b5478926
Signed-off-by: default avatarSai Chaitanya Kaveti <quic_skaveti@quicinc.com>
parent 70e9561d
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