Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/printf/vprintf.c

    rda1bafb r90c8b8d  
    3838#include <synch/spinlock.h>
    3939#include <arch/asm.h>
     40#include <arch/types.h>
    4041#include <typedefs.h>
    41 #include <typedefs.h>
    42 #include <str.h>
     42#include <string.h>
    4343
    44 IRQ_SPINLOCK_STATIC_INITIALIZE_NAME(printf_lock, "*printf_lock");
     44SPINLOCK_STATIC_INITIALIZE_NAME(printf_lock, "*printf_lock");
    4545
    4646static int vprintf_str_write(const char *str, size_t size, void *data)
     
    9393        };
    9494       
    95         irq_spinlock_lock(&printf_lock, true);
     95        ipl_t ipl = interrupts_disable();
     96        spinlock_lock(&printf_lock);
     97       
    9698        int ret = printf_core(fmt, &ps, ap);
    97         irq_spinlock_unlock(&printf_lock, true);
     99       
     100        spinlock_unlock(&printf_lock);
     101        interrupts_restore(ipl);
    98102       
    99103        return ret;
Note: See TracChangeset for help on using the changeset viewer.