Skip to content

Commit

Permalink
Fix missing check for netq->netq_stopping in vioif_rx_intr()
Browse files Browse the repository at this point in the history
Reported-by: syzbot+5120b7a1f97a3f5ca052@syzkaller.appspotmail.com
https://syzkaller.appspot.com/bug?id=243cf4115808e49774a49294f63200770399660b
  • Loading branch information
yamaguchi authored and yamaguchi committed May 11, 2023
1 parent 1b3c330 commit 2b696ab
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions sys/dev/pci/if_vioif.c
@@ -1,4 +1,4 @@
/* $NetBSD: if_vioif.c,v 1.107 2023/03/27 14:56:40 nakayama Exp $ */
/* $NetBSD: if_vioif.c,v 1.108 2023/05/11 05:50:18 yamaguchi Exp $ */

/*
* Copyright (c) 2020 The NetBSD Foundation, Inc.
Expand Down Expand Up @@ -27,7 +27,7 @@
*/

#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: if_vioif.c,v 1.107 2023/03/27 14:56:40 nakayama Exp $");
__KERNEL_RCSID(0, "$NetBSD: if_vioif.c,v 1.108 2023/05/11 05:50:18 yamaguchi Exp $");

#ifdef _KERNEL_OPT
#include "opt_net_mpsafe.h"
Expand Down Expand Up @@ -1924,6 +1924,9 @@ vioif_rx_intr(void *arg)
if (netq->netq_running_handle)
goto done;

if (netq->netq_stopping)
goto done;

netq->netq_running_handle = true;

limit = sc->sc_rx_intr_process_limit;
Expand Down

0 comments on commit 2b696ab

Please sign in to comment.