The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Dipankar Sarma <dipankar@gamebox.net>
To: Linus Torvalds <torvalds@transmeta.com>
Cc: linux-kernel@vger.kernel.org
Subject: [patch] kernel_stat cleanup
Date: Wed, 6 Nov 2002 01:11:00 +0530	[thread overview]
Message-ID: <20021106011100.A28528@dikhow> (raw)

This is a trivial cleanup removing two old unused macros from
kernel_stat.h that made no sense with the new per-CPU kstat.
Also included a few finicky coding style changes. Please apply.

Thanks
Dipankar


diff -urN linux-2.5.46-base/include/linux/kernel_stat.h linux-2.5.46-misc/include/linux/kernel_stat.h
--- linux-2.5.46-base/include/linux/kernel_stat.h	Tue Nov  5 21:58:28 2002
+++ linux-2.5.46-misc/include/linux/kernel_stat.h	Tue Nov  5 23:22:05 2002
@@ -35,23 +35,16 @@
 
 extern unsigned long nr_context_switches(void);
 
-/*
- * Maybe we need to smp-ify kernel_stat some day. It would be nice to do
- * that without having to modify all the code that increments the stats.
- */
-#define KERNEL_STAT_INC(x) kstat.x++
-#define KERNEL_STAT_ADD(x, y) kstat.x += y
-
 #if !defined(CONFIG_ARCH_S390)
 /*
  * Number of interrupts per specific IRQ source, since bootup
  */
-static inline int kstat_irqs (int irq)
+static inline int kstat_irqs(int irq)
 {
 	int i, sum=0;
 
-	for (i = 0 ; i < NR_CPUS ; i++) 
-		if (cpu_possible(i)) 
+	for (i = 0; i < NR_CPUS; i++)
+		if (cpu_possible(i))
 			sum += kstat_cpu(i).irqs[irq];
 
 	return sum;

                 reply	other threads:[~2002-11-05 19:37 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20021106011100.A28528@dikhow \
    --to=dipankar@gamebox.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@transmeta.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox