ioapic/x86_64: Add missing imen_lock/unlock
[dragonfly.git] / sys / platform / pc64 / apic / ioapic.c
index c3325d7..2ff9d58 100644 (file)
@@ -374,9 +374,11 @@ ioapic_gsi_setup(int gsi)
                                 *
                                 * This GSI is not used, disable it.
                                 */
+                               imen_lock();
                                ioapic_pin_setup(ioapic_gsi_ioaddr(gsi),
                                    ioapic_gsi_pin(gsi), 0,
                                    INTR_TRIGGER_EDGE, INTR_POLARITY_HIGH, 0);
+                               imen_unlock();
                                return;
                        }
                        trig = INTR_TRIGGER_EDGE;