Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/xen/xen Drop xbdi_lock() before calling intr_disest...



details:   https://anonhg.NetBSD.org/src/rev/1680ed74eeb3
branches:  trunk
changeset: 971863:1680ed74eeb3
user:      bouyer <bouyer%NetBSD.org@localhost>
date:      Wed May 06 20:09:26 2020 +0000

description:
Drop xbdi_lock() before calling intr_disestablish(), it needs to take
cpu_lock.

diffstat:

 sys/arch/xen/xen/xbdback_xenbus.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (34 lines):

diff -r ee1709488da0 -r 1680ed74eeb3 sys/arch/xen/xen/xbdback_xenbus.c
--- a/sys/arch/xen/xen/xbdback_xenbus.c Wed May 06 19:52:19 2020 +0000
+++ b/sys/arch/xen/xen/xbdback_xenbus.c Wed May 06 20:09:26 2020 +0000
@@ -1,4 +1,4 @@
-/*      $NetBSD: xbdback_xenbus.c,v 1.94 2020/05/06 19:49:00 bouyer Exp $      */
+/*      $NetBSD: xbdback_xenbus.c,v 1.95 2020/05/06 20:09:26 bouyer Exp $      */
 
 /*
  * Copyright (c) 2006 Manuel Bouyer.
@@ -26,7 +26,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: xbdback_xenbus.c,v 1.94 2020/05/06 19:49:00 bouyer Exp $");
+__KERNEL_RCSID(0, "$NetBSD: xbdback_xenbus.c,v 1.95 2020/05/06 20:09:26 bouyer Exp $");
 
 #include <sys/buf.h>
 #include <sys/condvar.h>
@@ -643,7 +643,6 @@
                return;
        }
        hypervisor_mask_event(xbdi->xbdi_evtchn);
-       intr_disestablish(xbdi->xbdi_ih);
 
        /* signal thread that we want to disconnect, then wait for it */
        xbdi->xbdi_status = DISCONNECTING;
@@ -653,6 +652,7 @@
                cv_wait(&xbdi->xbdi_cv, &xbdi->xbdi_lock);
 
        mutex_exit(&xbdi->xbdi_lock);
+       intr_disestablish(xbdi->xbdi_ih);
 
        xenbus_switch_state(xbdi->xbdi_xbusd, NULL, XenbusStateClosing);
 }



Home | Main Index | Thread Index | Old Index