From: Andrew Morton <akpm@osdl.org>
To: Zwane Mwaikambo <zwane@arm.linux.org.uk>
Cc: wli@holomorphy.com, helgehaf@aitel.hist.no, zboszor@freemail.hu,
linux-kernel@vger.kernel.org
Subject: Re: 2.5.74-mm1
Date: Fri, 4 Jul 2003 01:56:42 -0700 [thread overview]
Message-ID: <20030704015642.7840cab5.akpm@osdl.org> (raw)
In-Reply-To: <Pine.LNX.4.53.0307040437100.24383@montezuma.mastecende.com>
Zwane Mwaikambo <zwane@arm.linux.org.uk> wrote:
>
> > I shall make that change.
>
> Very nice, thanks!
Like this. I erased every `volatile' I could find. No idea why they were
in there.
arch/i386/kernel/smp.c | 2 -
arch/i386/kernel/smpboot.c | 6 ++---
include/asm-i386/smp.h | 2 -
include/linux/bitmap.h | 52 ++++++++++++++++++++++++++-------------------
4 files changed, 36 insertions(+), 26 deletions(-)
diff -puN include/linux/bitmap.h~gcc-bug-workaround include/linux/bitmap.h
--- 25/include/linux/bitmap.h~gcc-bug-workaround 2003-07-04 01:52:11.000000000 -0700
+++ 25-akpm/include/linux/bitmap.h 2003-07-04 01:52:11.000000000 -0700
@@ -10,7 +10,7 @@
#include <linux/bitops.h>
#include <linux/string.h>
-static inline int bitmap_empty(const volatile unsigned long *bitmap, int bits)
+static inline int bitmap_empty(const unsigned long *bitmap, int bits)
{
int k;
for (k = 0; k < bits/BITS_PER_LONG; ++k)
@@ -24,7 +24,7 @@ static inline int bitmap_empty(const vol
return 1;
}
-static inline int bitmap_full(const volatile unsigned long *bitmap, int bits)
+static inline int bitmap_full(const unsigned long *bitmap, int bits)
{
int k;
for (k = 0; k < bits/BITS_PER_LONG; ++k)
@@ -38,7 +38,8 @@ static inline int bitmap_full(const vola
return 1;
}
-static inline int bitmap_equal(const volatile unsigned long *bitmap1, volatile unsigned long *bitmap2, int bits)
+static inline int bitmap_equal(const unsigned long *bitmap1,
+ unsigned long *bitmap2, int bits)
{
int k;
for (k = 0; k < bits/BITS_PER_LONG; ++k)
@@ -46,13 +47,14 @@ static inline int bitmap_equal(const vol
return 0;
if (bits % BITS_PER_LONG)
- if ((bitmap1[k] ^ bitmap2[k]) & ((1UL << (bits % BITS_PER_LONG)) - 1))
+ if ((bitmap1[k] ^ bitmap2[k]) &
+ ((1UL << (bits % BITS_PER_LONG)) - 1))
return 0;
return 1;
}
-static inline void bitmap_complement(volatile unsigned long *bitmap, int bits)
+static inline void bitmap_complement(unsigned long *bitmap, int bits)
{
int k;
@@ -60,23 +62,24 @@ static inline void bitmap_complement(vol
bitmap[k] = ~bitmap[k];
}
-static inline void bitmap_clear(volatile unsigned long *bitmap, int bits)
+static inline void bitmap_clear(unsigned long *bitmap, int bits)
{
CLEAR_BITMAP((unsigned long *)bitmap, bits);
}
-static inline void bitmap_fill(volatile unsigned long *bitmap, int bits)
+static inline void bitmap_fill(unsigned long *bitmap, int bits)
{
- memset((unsigned long *)bitmap, 0xff, BITS_TO_LONGS(bits)*sizeof(unsigned long));
+ memset(bitmap, 0xff, BITS_TO_LONGS(bits)*sizeof(unsigned long));
}
-static inline void bitmap_copy(volatile unsigned long *dst, const volatile unsigned long *src, int bits)
+static inline void bitmap_copy(unsigned long *dst,
+ const unsigned long *src, int bits)
{
- memcpy((unsigned long *)dst, (unsigned long *)src, BITS_TO_LONGS(bits)*sizeof(unsigned long));
+ memcpy(dst, src, BITS_TO_LONGS(bits)*sizeof(unsigned long));
}
-static inline void bitmap_shift_left(volatile unsigned long *,const volatile unsigned long *,int,int);
-static inline void bitmap_shift_right(volatile unsigned long *dst, const volatile unsigned long *src, int shift, int bits)
+static inline void bitmap_shift_right(unsigned long *dst,
+ const unsigned long *src, int shift, int bits)
{
int k;
DECLARE_BITMAP(__shr_tmp, bits);
@@ -88,7 +91,8 @@ static inline void bitmap_shift_right(vo
bitmap_copy(dst, __shr_tmp, bits);
}
-static inline void bitmap_shift_left(volatile unsigned long *dst, const volatile unsigned long *src, int shift, int bits)
+static inline void bitmap_shift_left(unsigned long *dst,
+ const unsigned long *src, int shift, int bits)
{
int k;
DECLARE_BITMAP(__shl_tmp, bits);
@@ -100,24 +104,28 @@ static inline void bitmap_shift_left(vol
bitmap_copy(dst, __shl_tmp, bits);
}
-static inline void bitmap_and(volatile unsigned long *dst, const volatile unsigned long *bitmap1, const volatile unsigned long *bitmap2, int bits)
+static inline void bitmap_and(unsigned long *dst, const unsigned long *bitmap1,
+ const unsigned long *bitmap2, int bits)
{
int k;
+ int nr = BITS_TO_LONGS(bits);
- for (k = 0; k < BITS_TO_LONGS(bits); ++k)
+ for (k = 0; k < nr; k++)
dst[k] = bitmap1[k] & bitmap2[k];
}
-static inline void bitmap_or(volatile unsigned long *dst, const volatile unsigned long *bitmap1, const volatile unsigned long *bitmap2, int bits)
+static inline void bitmap_or(unsigned long *dst, const unsigned long *bitmap1,
+ const unsigned long *bitmap2, int bits)
{
int k;
+ int nr = BITS_TO_LONGS(bits);
- for (k = 0; k < BITS_TO_LONGS(bits); ++k)
+ for (k = 0; k < nr; k++)
dst[k] = bitmap1[k] | bitmap2[k];
}
#if BITS_PER_LONG == 32
-static inline int bitmap_weight(const volatile unsigned long *bitmap, int bits)
+static inline int bitmap_weight(const unsigned long *bitmap, int bits)
{
int k, w = 0;
@@ -125,12 +133,13 @@ static inline int bitmap_weight(const vo
w += hweight32(bitmap[k]);
if (bits % BITS_PER_LONG)
- w+= hweight32(bitmap[k] & ((1UL << (bits % BITS_PER_LONG)) - 1));
+ w += hweight32(bitmap[k] &
+ ((1UL << (bits % BITS_PER_LONG)) - 1));
return w;
}
#else
-static inline int bitmap_weight(const volatile unsigned long *bitmap, int bits)
+static inline int bitmap_weight(const unsigned long *bitmap, int bits)
{
int k, w = 0;
@@ -138,7 +147,8 @@ static inline int bitmap_weight(const vo
w += hweight64(bitmap[k]);
if (bits % BITS_PER_LONG)
- w += hweight64(bitmap[k] & ((1UL << (bits % BITS_PER_LONG)) - 1));
+ w += hweight64(bitmap[k] &
+ ((1UL << (bits % BITS_PER_LONG)) - 1));
return w;
}
diff -puN include/asm-i386/smp.h~gcc-bug-workaround include/asm-i386/smp.h
--- 25/include/asm-i386/smp.h~gcc-bug-workaround 2003-07-04 01:52:17.000000000 -0700
+++ 25-akpm/include/asm-i386/smp.h 2003-07-04 01:52:25.000000000 -0700
@@ -53,7 +53,7 @@ extern void zap_low_mappings (void);
*/
#define smp_processor_id() (current_thread_info()->cpu)
-extern volatile cpumask_t cpu_callout_map;
+extern cpumask_t cpu_callout_map;
#define cpu_possible(cpu) cpu_isset(cpu, cpu_callout_map)
diff -puN arch/i386/kernel/smpboot.c~gcc-bug-workaround arch/i386/kernel/smpboot.c
--- 25/arch/i386/kernel/smpboot.c~gcc-bug-workaround 2003-07-04 01:52:36.000000000 -0700
+++ 25-akpm/arch/i386/kernel/smpboot.c 2003-07-04 01:52:59.000000000 -0700
@@ -64,8 +64,8 @@ int phys_proc_id[NR_CPUS]; /* Package ID
/* bitmap of online cpus */
cpumask_t cpu_online_map;
-static volatile cpumask_t cpu_callin_map;
-volatile cpumask_t cpu_callout_map;
+static cpumask_t cpu_callin_map;
+cpumask_t cpu_callout_map;
static cpumask_t smp_commenced_mask;
/* Per CPU bogomips and other parameters */
@@ -529,7 +529,7 @@ static inline void unmap_cpu_to_node(int
#endif /* CONFIG_NUMA */
-volatile u8 cpu_2_logical_apicid[NR_CPUS] = { [0 ... NR_CPUS-1] = BAD_APICID };
+u8 cpu_2_logical_apicid[NR_CPUS] = { [0 ... NR_CPUS-1] = BAD_APICID };
void map_cpu_to_logical_apicid(void)
{
diff -puN arch/i386/kernel/smp.c~gcc-bug-workaround arch/i386/kernel/smp.c
--- 25/arch/i386/kernel/smp.c~gcc-bug-workaround 2003-07-04 01:55:10.000000000 -0700
+++ 25-akpm/arch/i386/kernel/smp.c 2003-07-04 01:55:25.000000000 -0700
@@ -241,7 +241,7 @@ inline void send_IPI_mask_sequence(cpuma
* Optimizations Manfred Spraul <manfred@colorfullife.com>
*/
-static volatile cpumask_t flush_cpumask;
+static cpumask_t flush_cpumask;
static struct mm_struct * flush_mm;
static unsigned long flush_va;
static spinlock_t tlbstate_lock = SPIN_LOCK_UNLOCKED;
_
next prev parent reply other threads:[~2003-07-04 8:46 UTC|newest]
Thread overview: 111+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-07-03 10:39 2.5.74-mm1 Boszormenyi Zoltan
2003-07-03 13:09 ` 2.5.74-mm1 Boszormenyi Zoltan
2003-07-03 19:22 ` 2.5.74-mm1 Andrew Morton
2003-07-03 20:08 ` 2.5.74-mm1 Helge Hafting
2003-07-03 21:15 ` 2.5.74-mm1 Andrew Morton
2003-07-04 5:53 ` 2.5.74-mm1 William Lee Irwin III
2003-07-04 7:12 ` 2.5.74-mm1 Boszormenyi Zoltan
2003-07-04 7:16 ` 2.5.74-mm1 Zwane Mwaikambo
2003-07-04 7:15 ` 2.5.74-mm1 Zwane Mwaikambo
2003-07-04 7:50 ` 2.5.74-mm1 Zwane Mwaikambo
2003-07-04 8:27 ` 2.5.74-mm1 Andrew Morton
2003-07-04 8:37 ` 2.5.74-mm1 Zwane Mwaikambo
2003-07-04 8:56 ` Andrew Morton [this message]
2003-07-04 8:57 ` 2.5.74-mm1 William Lee Irwin III
2003-07-04 8:52 ` 2.5.74-mm1 William Lee Irwin III
2003-07-04 20:00 ` 2.5.74-mm1 Helge Hafting
2003-07-04 20:08 ` 2.5.74-mm1 William Lee Irwin III
2003-07-03 22:26 ` 2.5.74-mm1 William Lee Irwin III
2003-07-03 23:01 ` 2.5.74-mm1 Zwane Mwaikambo
2003-07-03 23:16 ` 2.5.74-mm1 William Lee Irwin III
-- strict thread matches above, loose matches on Subject: below --
2003-07-03 9:37 2.5.74-mm1 Andrew Morton
2003-07-03 10:37 ` 2.5.74-mm1 Wiktor Wodecki
2003-07-03 11:06 ` 2.5.74-mm1 Russell King
2003-07-03 14:15 ` 2.5.74-mm1 Russell King
2003-07-03 16:05 ` 2.5.74-mm1 Patrick Mochel
2003-07-03 16:19 ` 2.5.74-mm1 Russell King
2003-07-03 16:24 ` 2.5.74-mm1 Patrick Mochel
2003-07-03 16:47 ` 2.5.74-mm1 Wiktor Wodecki
2003-07-03 18:43 ` 2.5.74-mm1 Serge Eric Thiam
2003-07-03 21:49 ` 2.5.74-mm1 Wiktor Wodecki
2003-07-03 21:53 ` 2.5.74-mm1 Russell King
2003-07-03 22:12 ` 2.5.74-mm1 Patrick Mochel
2003-07-03 22:14 ` 2.5.74-mm1 Russell King
2003-07-04 8:00 ` 2.5.74-mm1 Wiktor Wodecki
2003-07-03 16:02 ` 2.5.74-mm1 Felipe Alfaro Solana
2003-07-03 18:11 ` 2.5.74-mm1 Pasi Savolainen
2003-07-03 20:25 ` 2.5.74-mm1 William Lee Irwin III
2003-07-03 20:48 ` 2.5.74-mm1 William Lee Irwin III
2003-07-04 21:07 ` 2.5.74-mm1 William Lee Irwin III
2003-07-05 1:15 ` 2.5.74-mm1 Andrew Morton
2003-07-05 5:21 ` 2.5.74-mm1 Anton Blanchard
2003-07-05 11:18 ` 2.5.74-mm1 William Lee Irwin III
2003-07-05 11:46 ` 2.5.74-mm1 William Lee Irwin III
2003-07-05 10:44 ` 2.5.74-mm1 William Lee Irwin III
2003-07-05 18:43 ` 2.5.74-mm1 Andrew Morton
2003-07-05 21:17 ` 2.5.74-mm1 William Lee Irwin III
2003-07-05 21:27 ` 2.5.74-mm1 Andrew Morton
2003-07-05 22:03 ` 2.5.74-mm1 William Lee Irwin III
2003-07-05 0:16 ` 2.5.74-mm1 Daniel Phillips
2003-07-05 15:28 ` 2.5.74-mm1 Daniel Phillips
2003-07-05 16:01 ` 2.5.74-mm1 Con Kolivas
2003-07-05 17:47 ` 2.5.74-mm1 Daniel Phillips
2003-07-06 3:41 ` 2.5.74-mm1 Con Kolivas
2003-07-06 18:50 ` 2.5.74-mm1 Daniel Phillips
2003-07-05 19:14 ` 2.5.74-mm1 Andrew Morton
2003-07-05 21:09 ` 2.5.74-mm1 Daniel Phillips
2003-07-05 21:44 ` 2.5.74-mm1 Jamie Lokier
2003-07-05 22:10 ` 2.5.74-mm1 Daniel Phillips
2003-07-06 1:28 ` 2.5.74-mm1 Jamie Lokier
2003-07-06 2:14 ` 2.5.74-mm1 Daniel Phillips
2003-07-06 2:21 ` 2.5.74-mm1 Davide Libenzi
2003-07-06 13:54 ` 2.5.74-mm1 Daniel Phillips
2003-07-07 10:00 ` 2.5.74-mm1 Mel Gorman
2003-07-07 12:24 ` 2.5.74-mm1 Daniel Phillips
2003-07-07 13:09 ` 2.5.74-mm1 Alex Riesen
2003-07-07 14:33 ` 2.5.74-mm1 Daniel Phillips
2003-07-07 14:34 ` 2.5.74-mm1 Alex Riesen
2003-07-07 13:16 ` 2.5.74-mm1 Mel Gorman
2003-07-07 14:47 ` 2.5.74-mm1 Davide Libenzi
2003-07-07 15:23 ` 2.5.74-mm1 Jamie Lokier
2003-07-07 17:25 ` 2.5.74-mm1 Davide Libenzi
2003-07-07 17:55 ` 2.5.74-mm1 Daniel Phillips
2003-07-07 18:36 ` 2.5.74-mm1 Davide Libenzi
2003-07-07 19:07 ` 2.5.74-mm1 Daniel Phillips
2003-07-07 22:03 ` 2.5.74-mm1 Davide Libenzi
2003-07-08 0:13 ` 2.5.74-mm1 Daniel Phillips
2003-07-08 0:29 ` 2.5.74-mm1 Davide Libenzi
2003-07-08 1:07 ` 2.5.74-mm1 Daniel Phillips
2003-07-08 7:48 ` 2.5.74-mm1 Davide Libenzi
2003-07-08 9:18 ` 2.5.74-mm1 Nick Piggin
2003-07-08 15:24 ` 2.5.74-mm1 Davide Libenzi
2003-07-09 0:36 ` 2.5.74-mm1 Nick Piggin
2003-07-08 11:09 ` 2.5.74-mm1 Daniel Phillips
2003-07-08 18:19 ` 2.5.74-mm1 Davide Libenzi
2003-07-08 19:12 ` 2.5.74-mm1 Davide Libenzi
2003-07-07 19:39 ` 2.5.74-mm1 Jamie Lokier
2003-07-07 19:36 ` 2.5.74-mm1 Jamie Lokier
2003-07-09 22:17 ` 2.5.74-mm1 Daniel Phillips
2003-07-09 22:24 ` 2.5.74-mm1 Jamie Lokier
2003-07-09 22:29 ` 2.5.74-mm1 Davide Libenzi
2003-07-09 23:15 ` 2.5.74-mm1 Daniel Phillips
2003-07-09 23:19 ` 2.5.74-mm1 Jamie Lokier
2003-07-09 22:59 ` 2.5.74-mm1 Daniel Phillips
2003-07-10 2:01 ` 2.5.74-mm1 Peter Chubb
2003-07-11 1:04 ` 2.5.74-mm1 Daniel Phillips
2003-07-11 1:08 ` 2.5.74-mm1 William Lee Irwin III
2003-07-11 5:44 ` 2.5.74-mm1 Davide Libenzi
2003-07-11 8:07 ` 2.5.74-mm1 Daniel Phillips
2003-07-07 15:28 ` 2.5.74-mm1 Daniel Phillips
2003-07-07 17:58 ` 2.5.74-mm1 Davide Libenzi
[not found] ` <Pine.LNX.4.55.0307070745250.4428@bigblue.dev.mcafeelabs.co m>
2003-07-07 17:15 ` 2.5.74-mm1 Mike Galbraith
2003-07-05 22:11 ` 2.5.74-mm1 Diego Calleja García
2003-07-05 23:31 ` 2.5.74-mm1 Daniel Phillips
2003-07-06 0:23 ` 2.5.74-mm1 Diego Calleja García
2003-07-06 22:59 ` 2.5.74-mm1 Jamie Lokier
2003-07-06 2:29 ` 2.5.74-mm1 Davide Libenzi
2003-07-06 0:10 ` 2.5.74-mm1 Daniel Phillips
2003-07-06 0:10 ` 2.5.74-mm1 Davide Libenzi
2003-07-05 19:40 ` 2.5.74-mm1 Diego Calleja García
2003-07-05 19:48 ` 2.5.74-mm1 Davide Libenzi
2003-07-05 21:22 ` 2.5.74-mm1 Daniel Phillips
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=20030704015642.7840cab5.akpm@osdl.org \
--to=akpm@osdl.org \
--cc=helgehaf@aitel.hist.no \
--cc=linux-kernel@vger.kernel.org \
--cc=wli@holomorphy.com \
--cc=zboszor@freemail.hu \
--cc=zwane@arm.linux.org.uk \
/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
all inboxes | Powered by JetHome®