[PATCH 4/7] x86/irq: arch_irq_stat() returns unsigned int

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

 



irq_err_count is atomic_t, extending it to u64 does not make the value
wider, it's still unsigned int and will wrap around like unsigned int.

Signed-off-by: Alexei Lozovsky <me@xxxxxxxxxx>
---
 arch/x86/include/asm/hardirq.h | 2 +-
 arch/x86/kernel/irq.c          | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/arch/x86/include/asm/hardirq.h b/arch/x86/include/asm/hardirq.h
index 461536b45391..3b0d79e72871 100644
--- a/arch/x86/include/asm/hardirq.h
+++ b/arch/x86/include/asm/hardirq.h
@@ -57,7 +57,7 @@ extern void ack_bad_irq(unsigned int irq);
 extern unsigned int arch_irq_stat_cpu(unsigned int cpu);
 #define arch_irq_stat_cpu	arch_irq_stat_cpu
 
-extern u64 arch_irq_stat(void);
+extern unsigned int arch_irq_stat(void);
 #define arch_irq_stat		arch_irq_stat
 
 
diff --git a/arch/x86/kernel/irq.c b/arch/x86/kernel/irq.c
index cefe1bc9f42c..18691ed499d1 100644
--- a/arch/x86/kernel/irq.c
+++ b/arch/x86/kernel/irq.c
@@ -218,9 +218,9 @@ unsigned int arch_irq_stat_cpu(unsigned int cpu)
 	return sum;
 }
 
-u64 arch_irq_stat(void)
+unsigned int arch_irq_stat(void)
 {
-	u64 sum = atomic_read(&irq_err_count);
+	unsigned int sum = atomic_read(&irq_err_count);
 	return sum;
 }
 
-- 
2.25.1




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux