From b86651721f18f40319efe94ed3eac2d26682e5b9 Mon Sep 17 00:00:00 2001 From: Heiko Carstens Date: Wed, 5 Jan 2011 12:47:33 +0100 Subject: [PATCH] [S390] tape: add support for irq statistics Add support for ccw based tape I/O interrupt statistics in /proc/interrupts. Signed-off-by: Heiko Carstens Signed-off-by: Martin Schwidefsky --- arch/s390/include/asm/irq.h | 1 + arch/s390/kernel/irq.c | 1 + drivers/s390/char/tape_core.c | 2 ++ 3 files changed, 4 insertions(+) diff --git a/arch/s390/include/asm/irq.h b/arch/s390/include/asm/irq.h index 65e63c02b0f9..6986343a566f 100644 --- a/arch/s390/include/asm/irq.h +++ b/arch/s390/include/asm/irq.h @@ -20,6 +20,7 @@ enum interruption_class { IOINT_DAS, IOINT_C15, IOINT_C70, + IOINT_TAP, NMI_NMI, NR_IRQS, }; diff --git a/arch/s390/kernel/irq.c b/arch/s390/kernel/irq.c index 8c241416576f..5d7b6fbb3c13 100644 --- a/arch/s390/kernel/irq.c +++ b/arch/s390/kernel/irq.c @@ -37,6 +37,7 @@ static const struct irq_class intrclass_names[] = { {.name = "DAS", .desc = "[I/O] DASD" }, {.name = "C15", .desc = "[I/O] 3215" }, {.name = "C70", .desc = "[I/O] 3270" }, + {.name = "TAP", .desc = "[I/O] Tape" }, {.name = "NMI", .desc = "[NMI] Machine Check" }, }; diff --git a/drivers/s390/char/tape_core.c b/drivers/s390/char/tape_core.c index b3a3e8e8656e..7978a0adeaf3 100644 --- a/drivers/s390/char/tape_core.c +++ b/drivers/s390/char/tape_core.c @@ -14,6 +14,7 @@ #define KMSG_COMPONENT "tape" #define pr_fmt(fmt) KMSG_COMPONENT ": " fmt +#include #include #include // for kernel parameters #include // for requesting modules @@ -1114,6 +1115,7 @@ __tape_do_irq (struct ccw_device *cdev, unsigned long intparm, struct irb *irb) struct tape_request *request; int rc; + kstat_cpu(smp_processor_id()).irqs[IOINT_TAP]++; device = dev_get_drvdata(&cdev->dev); if (device == NULL) { return; -- 2.20.1