x86: Distinguish TLB shootdown interrupts from other functions call interrupts
[linux-2.6-block.git] / arch / x86 / mm / tlb.c
index 613cd83e8c0cf424bbf627973fb4af54634d8e8e..0777f042e4002e695b316c99889b594daebc5448 100644 (file)
@@ -98,6 +98,8 @@ static void flush_tlb_func(void *info)
 {
        struct flush_tlb_info *f = info;
 
+       inc_irq_stat(irq_tlb_count);
+
        if (f->flush_mm != this_cpu_read(cpu_tlbstate.active_mm))
                return;
 
@@ -320,7 +322,7 @@ static ssize_t tlbflush_write_file(struct file *file,
        if (kstrtos8(buf, 0, &shift))
                return -EINVAL;
 
-       if (shift > 64)
+       if (shift < -1 || shift >= BITS_PER_LONG)
                return -EINVAL;
 
        tlb_flushall_shift = shift;