Commit 671cd5ee authored by Anton Ivanov's avatar Anton Ivanov Committed by Richard Weinberger

um: vector: Fix NAPI budget handling

Fix the handling of NAPI budget.
Signed-off-by: default avatarAnton Ivanov <anton.ivanov@cambridgegreys.com>
Signed-off-by: default avatarRichard Weinberger <richard@nod.at>
parent 612a8c8e
......@@ -966,7 +966,7 @@ static int vector_mmsg_rx(struct vector_private *vp, int budget)
budget = qi->max_depth;
packet_count = uml_vector_recvmmsg(
vp->fds->rx_fd, qi->mmsg_vector, qi->max_depth, 0);
vp->fds->rx_fd, qi->mmsg_vector, budget, 0);
if (packet_count < 0)
vp->in_error = true;
......@@ -1180,7 +1180,7 @@ static int vector_poll(struct napi_struct *napi, int budget)
if (tx_enqueued || err > 0)
napi_schedule(napi);
if (work_done < budget)
if (work_done <= budget)
napi_complete_done(napi, work_done);
return work_done;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment