mirror of
https://github.com/torvalds/linux.git
synced 2026-09-24 06:24:02 +02:00
caif_virtio: Use vringh_notify_enable correctly
Check on the correct return value from vringh_notify_enable_kern(). It returns false if more packets are available, not true. Signed-off-by: Sjur Brændeland <sjur.brandeland@stericsson.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
cf994e0afa
commit
b2273be8d2
|
|
@ -318,7 +318,7 @@ static int cfv_rx_poll(struct napi_struct *napi, int quota)
|
||||||
|
|
||||||
/* Really out of patckets? (stolen from virtio_net)*/
|
/* Really out of patckets? (stolen from virtio_net)*/
|
||||||
napi_complete(napi);
|
napi_complete(napi);
|
||||||
if (unlikely(vringh_notify_enable_kern(cfv->vr_rx)) &&
|
if (unlikely(!vringh_notify_enable_kern(cfv->vr_rx)) &&
|
||||||
napi_schedule_prep(napi)) {
|
napi_schedule_prep(napi)) {
|
||||||
vringh_notify_disable_kern(cfv->vr_rx);
|
vringh_notify_disable_kern(cfv->vr_rx);
|
||||||
__napi_schedule(napi);
|
__napi_schedule(napi);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user