* [patch] SImple Topology API v0.3 (1/2)
@ 2002-08-22 19:13 Matthew Dobson
2002-08-22 19:22 ` [Lse-tech] " Christoph Hellwig
2002-08-27 14:31 ` Pavel Machek
0 siblings, 2 replies; 12+ messages in thread
From: Matthew Dobson @ 2002-08-22 19:13 UTC (permalink / raw)
To: Andrew Morton, Linus Torvalds, linux-kernel, linux-mm
Cc: Martin Bligh, Andrea Arcangeli, Michael Hohnbaum, lse-tech
[-- Attachment #1: Type: text/plain, Size: 450 bytes --]
Andrew, Linus, et al:
Here's the latest version of the Simple Topology API. I've broken the patches
into a solely in-kernel portion, and a portion that exposes the API to
userspace via syscalls and prctl. This patch (part 1) is the in-kernel part.
I hope that the smaller versions of these patches will draw more feedback,
comments, flames, etc. Other than that, the patch remains relatively unchanged
from the last posting.
Cheers!
-Matt
[-- Attachment #2: simple_topo-v0.3-in_kernel-2.5.31.patch --]
[-- Type: text/plain, Size: 7417 bytes --]
diff -Nur linux-2.5.27-vanilla/arch/i386/config.in linux-2.5.27-api/arch/i386/config.in
--- linux-2.5.27-vanilla/arch/i386/config.in Sat Jul 20 12:11:12 2002
+++ linux-2.5.27-api/arch/i386/config.in Wed Jul 24 17:33:41 2002
@@ -166,7 +166,15 @@
define_bool CONFIG_X86_IO_APIC y
fi
else
- bool 'Multiquad NUMA system' CONFIG_MULTIQUAD
+ bool 'Multi-node NUMA system support' CONFIG_X86_NUMA
+ if [ "$CONFIG_X86_NUMA" = "y" ]; then
+ #Platform Choices
+ bool 'Multiquad (IBM/Sequent) NUMAQ support' CONFIG_X86_NUMAQ
+ if [ "$CONFIG_X86_NUMAQ" = "y" ]; then
+ define_bool CONFIG_MULTIQUAD y
+ define_bool CONFIG_X86_TSC_DISABLE y
+ fi
+ fi
fi
bool 'Machine Check Exception' CONFIG_X86_MCE
diff -Nur linux-2.5.27-vanilla/arch/i386/kernel/smpboot.c linux-2.5.27-api/arch/i386/kernel/smpboot.c
--- linux-2.5.27-vanilla/arch/i386/kernel/smpboot.c Sat Jul 20 12:11:18 2002
+++ linux-2.5.27-api/arch/i386/kernel/smpboot.c Wed Jul 24 17:33:41 2002
@@ -60,6 +60,9 @@
/* Bitmask of currently online CPUs */
unsigned long cpu_online_map;
+/* Bitmask of currently online memory blocks */
+unsigned long memblk_online_map;
+
static volatile unsigned long cpu_callin_map;
volatile unsigned long cpu_callout_map;
static unsigned long smp_commenced_mask;
diff -Nur linux-2.5.27-vanilla/include/asm-i386/mmzone.h linux-2.5.27-api/include/asm-i386/mmzone.h
--- linux-2.5.27-vanilla/include/asm-i386/mmzone.h Wed Dec 31 16:00:00 1969
+++ linux-2.5.27-api/include/asm-i386/mmzone.h Wed Jul 24 17:33:41 2002
@@ -0,0 +1,53 @@
+/*
+ * linux/include/asm-i386/mmzone.h
+ *
+ * Written by: Matthew Dobson, IBM Corporation
+ *
+ * Copyright (C) 2002, IBM Corp.
+ *
+ * All rights reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, GOOD TITLE or
+ * NON INFRINGEMENT. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ *
+ * Send feedback to <colpatch@us.ibm.com>
+ */
+#ifndef _ASM_MMZONE_H_
+#define _ASM_MMZONE_H_
+
+#ifdef CONFIG_X86_NUMAQ
+
+#define NR_MEMBLKS 32 /* Max number of Memory Blocks */
+
+#include <asm/numaq.h>
+
+#else /* !CONFIG_X86_NUMAQ */
+
+#define NR_MEMBLKS 1
+
+/* Other architectures wishing to use this simple topology API should fill
+ in the below functions as appropriate in their own <arch>.h file. */
+#define _cpu_to_node(cpu) (0)
+#define _memblk_to_node(memblk) (0)
+#define _node_to_node(nid) (0)
+#define _node_to_cpu(node) (0)
+#define _node_to_memblk(node) (0)
+
+#endif /* CONFIG_X86_NUMAQ */
+
+/* Returns the number of the current Node. */
+#define numa_node_id() (_cpu_to_node(smp_processor_id()))
+
+#endif /* _ASM_MMZONE_H_ */
diff -Nur linux-2.5.27-vanilla/include/asm-i386/numaq.h linux-2.5.27-api/include/asm-i386/numaq.h
--- linux-2.5.27-vanilla/include/asm-i386/numaq.h Wed Dec 31 16:00:00 1969
+++ linux-2.5.27-api/include/asm-i386/numaq.h Wed Jul 24 17:33:41 2002
@@ -0,0 +1,60 @@
+/*
+ * linux/include/asm-i386/numaq.h
+ *
+ * Written by: Matthew Dobson, IBM Corporation
+ *
+ * Copyright (C) 2002, IBM Corp.
+ *
+ * All rights reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, GOOD TITLE or
+ * NON INFRINGEMENT. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ *
+ * Send feedback to <colpatch@us.ibm.com>
+ */
+#ifndef _I386_NUMAQ_H
+#define _I386_NUMAQ_H
+
+#ifdef CONFIG_X86_NUMAQ
+
+#include <asm/smpboot.h>
+
+/* Returns the number of the node containing CPU 'cpu' */
+#define _cpu_to_node(cpu) (cpu_to_logical_apicid(cpu) >> 4)
+
+/* Returns the number of the node containing MemBlk 'memblk' */
+#define _memblk_to_node(memblk) (memblk)
+
+/* Returns the number of the node containing Node 'nid'. This architecture is flat,
+ so it is a pretty simple function! */
+#define _node_to_node(nid) (nid)
+
+/* Returns the number of the first CPU on Node 'node' */
+static inline int _node_to_cpu(int node)
+{
+ int i, cpu, logical_apicid = node << 4;
+
+ for(i = 1; i < 16; i <<= 1)
+ if ((cpu = logical_apicid_to_cpu(logical_apicid | i)) >= 0)
+ return cpu;
+
+ return 0;
+}
+
+/* Returns the number of the first MemBlk on Node 'node' */
+#define _node_to_memblk(node) (node)
+
+#endif /* CONFIG_X86_NUMAQ */
+#endif /* _I386_NUMAQ_H */
diff -Nur linux-2.5.27-vanilla/include/asm-i386/smp.h linux-2.5.27-api/include/asm-i386/smp.h
--- linux-2.5.27-vanilla/include/asm-i386/smp.h Sat Jul 20 12:11:06 2002
+++ linux-2.5.27-api/include/asm-i386/smp.h Wed Jul 24 17:33:41 2002
@@ -55,6 +55,7 @@
extern void smp_alloc_memory(void);
extern unsigned long phys_cpu_present_map;
extern unsigned long cpu_online_map;
+extern unsigned long memblk_online_map;
extern volatile unsigned long smp_invalidate_needed;
extern int pic_mode;
extern int smp_num_siblings;
@@ -95,6 +96,11 @@
return hweight32(cpu_online_map);
}
+extern inline unsigned int num_online_memblks(void)
+{
+ return hweight32(memblk_online_map);
+}
+
extern inline int any_online_cpu(unsigned int mask)
{
if (mask & cpu_online_map)
diff -Nur linux-2.5.27-vanilla/include/linux/mmzone.h linux-2.5.27-api/include/linux/mmzone.h
--- linux-2.5.27-vanilla/include/linux/mmzone.h Sat Jul 20 12:11:05 2002
+++ linux-2.5.27-api/include/linux/mmzone.h Wed Jul 24 17:33:41 2002
@@ -220,15 +20,15 @@
#define NODE_MEM_MAP(nid) mem_map
#define MAX_NR_NODES 1
-#else /* !CONFIG_DISCONTIGMEM */
-
-#include <asm/mmzone.h>
+#else /* CONFIG_DISCONTIGMEM */
/* page->zone is currently 8 bits ... */
#define MAX_NR_NODES (255 / MAX_NR_ZONES)
#endif /* !CONFIG_DISCONTIGMEM */
+#include <asm/mmzone.h>
+
#define MAP_ALIGN(x) ((((x) % sizeof(struct page)) == 0) ? (x) : ((x) + \
sizeof(struct page) - ((x) % sizeof(struct page))))
diff -Nur linux-2.5.27-vanilla/include/linux/smp.h linux-2.5.27-api/include/linux/smp.h
--- linux-2.5.27-vanilla/include/linux/smp.h Sat Jul 20 12:11:22 2002
+++ linux-2.5.27-api/include/linux/smp.h Wed Jul 24 17:33:41 2002
@@ -93,6 +93,7 @@
#define smp_call_function(func,info,retry,wait) ({ 0; })
static inline void smp_send_reschedule(int cpu) { }
static inline void smp_send_reschedule_all(void) { }
+#define memblk_online_map 1
#define cpu_online_map 1
#define cpu_online(cpu) ({ cpu; 1; })
#define num_online_cpus() 1
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [Lse-tech] [patch] SImple Topology API v0.3 (1/2)
2002-08-22 19:13 [patch] SImple Topology API v0.3 (1/2) Matthew Dobson
@ 2002-08-22 19:22 ` Christoph Hellwig
2002-08-22 20:41 ` Matthew Dobson
2002-08-27 14:31 ` Pavel Machek
1 sibling, 1 reply; 12+ messages in thread
From: Christoph Hellwig @ 2002-08-22 19:22 UTC (permalink / raw)
To: Matthew Dobson
Cc: Andrew Morton, Linus Torvalds, linux-kernel, linux-mm,
Martin Bligh, Andrea Arcangeli, Michael Hohnbaum, lse-tech
On Thu, Aug 22, 2002 at 12:13:23PM -0700, Matthew Dobson wrote:
> --- linux-2.5.27-vanilla/include/linux/mmzone.h Sat Jul 20 12:11:05 2002
> +++ linux-2.5.27-api/include/linux/mmzone.h Wed Jul 24 17:33:41 2002
> @@ -220,15 +20,15 @@
> #define NODE_MEM_MAP(nid) mem_map
> #define MAX_NR_NODES 1
>
> -#else /* !CONFIG_DISCONTIGMEM */
> -
> -#include <asm/mmzone.h>
> +#else /* CONFIG_DISCONTIGMEM */
>
> /* page->zone is currently 8 bits ... */
> #define MAX_NR_NODES (255 / MAX_NR_ZONES)
>
> #endif /* !CONFIG_DISCONTIGMEM */
>
> +#include <asm/mmzone.h>
> +
What is the exact purpose of this change?
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [Lse-tech] [patch] SImple Topology API v0.3 (1/2)
2002-08-22 19:22 ` [Lse-tech] " Christoph Hellwig
@ 2002-08-22 20:41 ` Matthew Dobson
2002-08-22 20:48 ` Christoph Hellwig
0 siblings, 1 reply; 12+ messages in thread
From: Matthew Dobson @ 2002-08-22 20:41 UTC (permalink / raw)
To: Christoph Hellwig
Cc: Andrew Morton, Linus Torvalds, linux-kernel, linux-mm,
Martin Bligh, Andrea Arcangeli, Michael Hohnbaum, lse-tech
The file asm/mmzone.h needs to be included in both the CONFIG_DISCONTIGMEM and
!CONFIG_DISCONTIGMEM cases (at least after my patch). This just pulls the
#include out of the #ifdefs.
Cheers!
-Matt
Christoph Hellwig wrote:
> On Thu, Aug 22, 2002 at 12:13:23PM -0700, Matthew Dobson wrote:
>
>>--- linux-2.5.27-vanilla/include/linux/mmzone.h Sat Jul 20 12:11:05 2002
>>+++ linux-2.5.27-api/include/linux/mmzone.h Wed Jul 24 17:33:41 2002
>>@@ -220,15 +20,15 @@
>> #define NODE_MEM_MAP(nid) mem_map
>> #define MAX_NR_NODES 1
>>
>>-#else /* !CONFIG_DISCONTIGMEM */
>>-
>>-#include <asm/mmzone.h>
>>+#else /* CONFIG_DISCONTIGMEM */
>>
>> /* page->zone is currently 8 bits ... */
>> #define MAX_NR_NODES (255 / MAX_NR_ZONES)
>>
>> #endif /* !CONFIG_DISCONTIGMEM */
>>
>>+#include <asm/mmzone.h>
>>+
>
>
> What is the exact purpose of this change?
>
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by: OSDN - Tired of that same old
> cell phone? Get a new here for FREE!
> https://www.inphonic.com/r.asp?r=sourceforge1&refcode1=vs3390
> _______________________________________________
> Lse-tech mailing list
> Lse-tech@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/lse-tech
>
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [Lse-tech] [patch] SImple Topology API v0.3 (1/2)
2002-08-22 20:41 ` Matthew Dobson
@ 2002-08-22 20:48 ` Christoph Hellwig
0 siblings, 0 replies; 12+ messages in thread
From: Christoph Hellwig @ 2002-08-22 20:48 UTC (permalink / raw)
To: Matthew Dobson
Cc: Andrew Morton, Linus Torvalds, linux-kernel, linux-mm,
Martin Bligh, Andrea Arcangeli, Michael Hohnbaum, lse-tech
On Thu, Aug 22, 2002 at 01:41:51PM -0700, Matthew Dobson wrote:
> The file asm/mmzone.h needs to be included in both the CONFIG_DISCONTIGMEM and
> !CONFIG_DISCONTIGMEM cases (at least after my patch). This just pulls the
> #include out of the #ifdefs.
Maybe I've noticed that myself? But why do you suddenly break every port
of execept of i386,ia64, alpha and mips64? What is the reason your patch
needs this?
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch] SImple Topology API v0.3 (1/2)
2002-08-22 19:13 [patch] SImple Topology API v0.3 (1/2) Matthew Dobson
2002-08-22 19:22 ` [Lse-tech] " Christoph Hellwig
@ 2002-08-27 14:31 ` Pavel Machek
2002-08-27 21:18 ` Andrea Arcangeli
2002-08-28 13:14 ` Thunder from the hill
1 sibling, 2 replies; 12+ messages in thread
From: Pavel Machek @ 2002-08-27 14:31 UTC (permalink / raw)
To: Matthew Dobson
Cc: Andrew Morton, Linus Torvalds, linux-kernel, linux-mm,
Martin Bligh, Andrea Arcangeli, Michael Hohnbaum, lse-tech
Hi!
> Andrew, Linus, et al:
> Here's the latest version of the Simple Topology API. I've broken the patches
> into a solely in-kernel portion, and a portion that exposes the API to
> userspace via syscalls and prctl. This patch (part 1) is the in-kernel part.
> I hope that the smaller versions of these patches will draw more feedback,
> comments, flames, etc. Other than that, the patch remains relatively unchanged
> from the last posting.
> - bool 'Multiquad NUMA system' CONFIG_MULTIQUAD
> + bool 'Multi-node NUMA system support' CONFIG_X86_NUMA
Why not simply CONFIG_NUMA?
Pavel
> + if [ "" = "y" ]; then
> + #Platform Choices
> + bool 'Multiquad (IBM/Sequent) NUMAQ support' CONFIG_X86_NUMAQ
> + if [ "" = "y" ]; then
> + define_bool CONFIG_MULTIQUAD y
> + define_bool CONFIG_X86_TSC_DISABLE y
> + fi
> + fi
> fi
>
> bool 'Machine Check Exception' CONFIG_X86_MCE
> diff -Nur linux-2.5.27-vanilla/arch/i386/kernel/smpboot.c linux-2.5.27-api/arch/i386/kernel/smpboot.c
> --- linux-2.5.27-vanilla/arch/i386/kernel/smpboot.c Sat Jul 20 12:11:18 2002
> +++ linux-2.5.27-api/arch/i386/kernel/smpboot.c Wed Jul 24 17:33:41 2002
> @@ -60,6 +60,9 @@
> /* Bitmask of currently online CPUs */
> unsigned long cpu_online_map;
>
> +/* Bitmask of currently online memory blocks */
> +unsigned long memblk_online_map;
> +
> static volatile unsigned long cpu_callin_map;
> volatile unsigned long cpu_callout_map;
> static unsigned long smp_commenced_mask;
> diff -Nur linux-2.5.27-vanilla/include/asm-i386/mmzone.h linux-2.5.27-api/include/asm-i386/mmzone.h
> --- linux-2.5.27-vanilla/include/asm-i386/mmzone.h Wed Dec 31 16:00:00 1969
> +++ linux-2.5.27-api/include/asm-i386/mmzone.h Wed Jul 24 17:33:41 2002
> @@ -0,0 +1,53 @@
> +/*
> + * linux/include/asm-i386/mmzone.h
> + *
> + * Written by: Matthew Dobson, IBM Corporation
> + *
> + * Copyright (C) 2002, IBM Corp.
> + *
> + * All rights reserved.
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + *
> + * This program is distributed in the hope that it will be useful, but
> + * WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, GOOD TITLE or
> + * NON INFRINGEMENT. See the GNU General Public License for more
> + * details.
> + *
> + * You should have received a copy of the GNU General Public License
> + * along with this program; if not, write to the Free Software
> + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
> + *
> + * Send feedback to <colpatch@us.ibm.com>
> + */
> +#ifndef _ASM_MMZONE_H_
> +#define _ASM_MMZONE_H_
> +
> +#ifdef CONFIG_X86_NUMAQ
> +
> +#define NR_MEMBLKS 32 /* Max number of Memory Blocks */
> +
> +#include <asm/numaq.h>
> +
> +#else /* !CONFIG_X86_NUMAQ */
> +
> +#define NR_MEMBLKS 1
> +
> +/* Other architectures wishing to use this simple topology API should fill
> + in the below functions as appropriate in their own <arch>.h file. */
> +#define _cpu_to_node(cpu) (0)
> +#define _memblk_to_node(memblk) (0)
> +#define _node_to_node(nid) (0)
> +#define _node_to_cpu(node) (0)
> +#define _node_to_memblk(node) (0)
> +
> +#endif /* CONFIG_X86_NUMAQ */
> +
> +/* Returns the number of the current Node. */
> +#define numa_node_id() (_cpu_to_node(smp_processor_id()))
> +
> +#endif /* _ASM_MMZONE_H_ */
> diff -Nur linux-2.5.27-vanilla/include/asm-i386/numaq.h linux-2.5.27-api/include/asm-i386/numaq.h
> --- linux-2.5.27-vanilla/include/asm-i386/numaq.h Wed Dec 31 16:00:00 1969
> +++ linux-2.5.27-api/include/asm-i386/numaq.h Wed Jul 24 17:33:41 2002
> @@ -0,0 +1,60 @@
> +/*
> + * linux/include/asm-i386/numaq.h
> + *
> + * Written by: Matthew Dobson, IBM Corporation
> + *
> + * Copyright (C) 2002, IBM Corp.
> + *
> + * All rights reserved.
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation; either version 2 of the License, or
> + * (at your option) any later version.
> + *
> + * This program is distributed in the hope that it will be useful, but
> + * WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, GOOD TITLE or
> + * NON INFRINGEMENT. See the GNU General Public License for more
> + * details.
> + *
> + * You should have received a copy of the GNU General Public License
> + * along with this program; if not, write to the Free Software
> + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
> + *
> + * Send feedback to <colpatch@us.ibm.com>
> + */
> +#ifndef _I386_NUMAQ_H
> +#define _I386_NUMAQ_H
> +
> +#ifdef CONFIG_X86_NUMAQ
> +
> +#include <asm/smpboot.h>
> +
> +/* Returns the number of the node containing CPU 'cpu' */
> +#define _cpu_to_node(cpu) (cpu_to_logical_apicid(cpu) >> 4)
> +
> +/* Returns the number of the node containing MemBlk 'memblk' */
> +#define _memblk_to_node(memblk) (memblk)
> +
> +/* Returns the number of the node containing Node 'nid'. This architecture is flat,
> + so it is a pretty simple function! */
> +#define _node_to_node(nid) (nid)
> +
> +/* Returns the number of the first CPU on Node 'node' */
> +static inline int _node_to_cpu(int node)
> +{
> + int i, cpu, logical_apicid = node << 4;
> +
> + for(i = 1; i < 16; i <<= 1)
> + if ((cpu = logical_apicid_to_cpu(logical_apicid | i)) >= 0)
> + return cpu;
> +
> + return 0;
> +}
> +
> +/* Returns the number of the first MemBlk on Node 'node' */
> +#define _node_to_memblk(node) (node)
> +
> +#endif /* CONFIG_X86_NUMAQ */
> +#endif /* _I386_NUMAQ_H */
> diff -Nur linux-2.5.27-vanilla/include/asm-i386/smp.h linux-2.5.27-api/include/asm-i386/smp.h
> --- linux-2.5.27-vanilla/include/asm-i386/smp.h Sat Jul 20 12:11:06 2002
> +++ linux-2.5.27-api/include/asm-i386/smp.h Wed Jul 24 17:33:41 2002
> @@ -55,6 +55,7 @@
> extern void smp_alloc_memory(void);
> extern unsigned long phys_cpu_present_map;
> extern unsigned long cpu_online_map;
> +extern unsigned long memblk_online_map;
> extern volatile unsigned long smp_invalidate_needed;
> extern int pic_mode;
> extern int smp_num_siblings;
> @@ -95,6 +96,11 @@
> return hweight32(cpu_online_map);
> }
>
> +extern inline unsigned int num_online_memblks(void)
> +{
> + return hweight32(memblk_online_map);
> +}
> +
> extern inline int any_online_cpu(unsigned int mask)
> {
> if (mask & cpu_online_map)
> diff -Nur linux-2.5.27-vanilla/include/linux/mmzone.h linux-2.5.27-api/include/linux/mmzone.h
> --- linux-2.5.27-vanilla/include/linux/mmzone.h Sat Jul 20 12:11:05 2002
> +++ linux-2.5.27-api/include/linux/mmzone.h Wed Jul 24 17:33:41 2002
> @@ -220,15 +20,15 @@
> #define NODE_MEM_MAP(nid) mem_map
> #define MAX_NR_NODES 1
>
> -#else /* !CONFIG_DISCONTIGMEM */
> -
> -#include <asm/mmzone.h>
> +#else /* CONFIG_DISCONTIGMEM */
>
> /* page->zone is currently 8 bits ... */
> #define MAX_NR_NODES (255 / MAX_NR_ZONES)
>
> #endif /* !CONFIG_DISCONTIGMEM */
>
> +#include <asm/mmzone.h>
> +
> #define MAP_ALIGN(x) ((((x) % sizeof(struct page)) == 0) ? (x) : ((x) + > sizeof(struct page) - ((x) % sizeof(struct page))))
>
> diff -Nur linux-2.5.27-vanilla/include/linux/smp.h linux-2.5.27-api/include/linux/smp.h
> --- linux-2.5.27-vanilla/include/linux/smp.h Sat Jul 20 12:11:22 2002
> +++ linux-2.5.27-api/include/linux/smp.h Wed Jul 24 17:33:41 2002
> @@ -93,6 +93,7 @@
> #define smp_call_function(func,info,retry,wait) ({ 0; })
> static inline void smp_send_reschedule(int cpu) { }
> static inline void smp_send_reschedule_all(void) { }
> +#define memblk_online_map 1
> #define cpu_online_map 1
> #define cpu_online(cpu) ({ cpu; 1; })
> #define num_online_cpus() 1
--
Philips Velo 1: 1"x4"x8", 300gram, 60, 12MB, 40bogomips, linux, mutt,
details at http://atrey.karlin.mff.cuni.cz/~pavel/velo/index.html.
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch] SImple Topology API v0.3 (1/2)
2002-08-27 14:31 ` Pavel Machek
@ 2002-08-27 21:18 ` Andrea Arcangeli
2002-08-28 13:14 ` Thunder from the hill
1 sibling, 0 replies; 12+ messages in thread
From: Andrea Arcangeli @ 2002-08-27 21:18 UTC (permalink / raw)
To: Pavel Machek
Cc: Matthew Dobson, Andrew Morton, Linus Torvalds, linux-kernel,
linux-mm, Martin Bligh, Michael Hohnbaum, lse-tech
On Tue, Aug 27, 2002 at 02:31:16PM +0000, Pavel Machek wrote:
> Hi!
>
> > Andrew, Linus, et al:
> > Here's the latest version of the Simple Topology API. I've broken the patches
> > into a solely in-kernel portion, and a portion that exposes the API to
> > userspace via syscalls and prctl. This patch (part 1) is the in-kernel part.
> > I hope that the smaller versions of these patches will draw more feedback,
> > comments, flames, etc. Other than that, the patch remains relatively unchanged
> > from the last posting.
>
> > - bool 'Multiquad NUMA system' CONFIG_MULTIQUAD
> > + bool 'Multi-node NUMA system support' CONFIG_X86_NUMA
>
> Why not simply CONFIG_NUMA?
that is just used by the common code, it fits well for that usage and it
has different semantics.
Andrea
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch] SImple Topology API v0.3 (1/2)
2002-08-27 14:31 ` Pavel Machek
2002-08-27 21:18 ` Andrea Arcangeli
@ 2002-08-28 13:14 ` Thunder from the hill
2002-08-28 19:29 ` Pavel Machek
1 sibling, 1 reply; 12+ messages in thread
From: Thunder from the hill @ 2002-08-28 13:14 UTC (permalink / raw)
To: Pavel Machek
Cc: Matthew Dobson, Andrew Morton, Linus Torvalds, linux-kernel,
linux-mm, Martin Bligh, Andrea Arcangeli, Michael Hohnbaum,
lse-tech
Hi,
On Tue, 27 Aug 2002, Pavel Machek wrote:
> > - bool 'Multiquad NUMA system' CONFIG_MULTIQUAD
> > + bool 'Multi-node NUMA system support' CONFIG_X86_NUMA
>
> Why not simply CONFIG_NUMA?
Because NUMA is subordinate to X86, and another technology named NUMA
might appear? Nano-uplinked micro-array... No Ugliness Munched Archive?
Whatever...
Thunder
--
--./../...-/. -.--/---/..-/.-./..././.-../..-. .---/..-/.../- .-
--/../-./..-/-/./--..-- ../.----./.-../.-.. --./../...-/. -.--/---/..-
.- -/---/--/---/.-./.-./---/.--/.-.-.-
--./.-/-.../.-./.././.-../.-.-.-
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch] SImple Topology API v0.3 (1/2)
2002-08-28 13:14 ` Thunder from the hill
@ 2002-08-28 19:29 ` Pavel Machek
2002-08-28 20:02 ` Thunder from the hill
2002-08-28 22:31 ` [Lse-tech] " Timothy D. Witham
0 siblings, 2 replies; 12+ messages in thread
From: Pavel Machek @ 2002-08-28 19:29 UTC (permalink / raw)
To: Thunder from the hill
Cc: Matthew Dobson, Andrew Morton, Linus Torvalds, linux-kernel,
linux-mm, Martin Bligh, Andrea Arcangeli, Michael Hohnbaum,
lse-tech
Hi!
> > > - bool 'Multiquad NUMA system' CONFIG_MULTIQUAD
> > > + bool 'Multi-node NUMA system support' CONFIG_X86_NUMA
> >
> > Why not simply CONFIG_NUMA?
>
> Because NUMA is subordinate to X86, and another technology named NUMA
> might appear? Nano-uplinked micro-array... No Ugliness Munched Archive?
> Whatever...
NUMA means non-uniform memory access. At least IBM, AMD and SGI do
NUMA; and I guess anyone with 100+ nodes *has* numa machine. (BUt as
andrea already explained, CONFIG_NUMA is already taken for generic
NUMA support.)
Pavel
--
Casualities in World Trade Center: ~3k dead inside the building,
cryptography in U.S.A. and free speech in Czech Republic.
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [patch] SImple Topology API v0.3 (1/2)
2002-08-28 19:29 ` Pavel Machek
@ 2002-08-28 20:02 ` Thunder from the hill
2002-08-28 22:31 ` [Lse-tech] " Timothy D. Witham
1 sibling, 0 replies; 12+ messages in thread
From: Thunder from the hill @ 2002-08-28 20:02 UTC (permalink / raw)
To: Pavel Machek
Cc: Thunder from the hill, Matthew Dobson, Andrew Morton,
Linus Torvalds, linux-kernel, linux-mm, Martin Bligh,
Andrea Arcangeli, Michael Hohnbaum, lse-tech
Hi,
On Wed, 28 Aug 2002, Pavel Machek wrote:
> > Because NUMA is subordinate to X86, and another technology named NUMA
> > might appear? Nano-uplinked micro-array... No Ugliness Munched Archive?
> > Whatever...
>
> NUMA means non-uniform memory access. At least IBM, AMD and SGI do
> NUMA; and I guess anyone with 100+ nodes *has* numa machine. (BUt as
> andrea already explained, CONFIG_NUMA is already taken for generic
> NUMA support.)
I'm aware of that. You didn't get my point, though. I was just suggesting
that there might be other things called NUMA, so CONFIG_X86_NUMA may be
just right.
Thunder
--
--./../...-/. -.--/---/..-/.-./..././.-../..-. .---/..-/.../- .-
--/../-./..-/-/./--..-- ../.----./.-../.-.. --./../...-/. -.--/---/..-
.- -/---/--/---/.-./.-./---/.--/.-.-.-
--./.-/-.../.-./.././.-../.-.-.-
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [Lse-tech] Re: [patch] SImple Topology API v0.3 (1/2)
2002-08-28 19:29 ` Pavel Machek
2002-08-28 20:02 ` Thunder from the hill
@ 2002-08-28 22:31 ` Timothy D. Witham
2002-08-28 22:40 ` Thunder from the hill
1 sibling, 1 reply; 12+ messages in thread
From: Timothy D. Witham @ 2002-08-28 22:31 UTC (permalink / raw)
To: Pavel Machek
Cc: Thunder from the hill, Matthew Dobson, Andrew Morton,
Linus Torvalds, linux-kernel, linux-mm, Martin Bligh,
Andrea Arcangeli, Michael Hohnbaum, lse-tech
How about the old Marketing name CONFIG_CCNUMA?
Tim
On Wed, 2002-08-28 at 12:29, Pavel Machek wrote:
> Hi!
>
> > > > - bool 'Multiquad NUMA system' CONFIG_MULTIQUAD
> > > > + bool 'Multi-node NUMA system support' CONFIG_X86_NUMA
> > >
> > > Why not simply CONFIG_NUMA?
> >
> > Because NUMA is subordinate to X86, and another technology named NUMA
> > might appear? Nano-uplinked micro-array... No Ugliness Munched Archive?
> > Whatever...
>
> NUMA means non-uniform memory access. At least IBM, AMD and SGI do
> NUMA; and I guess anyone with 100+ nodes *has* numa machine. (BUt as
> andrea already explained, CONFIG_NUMA is already taken for generic
> NUMA support.)
>
> Pavel
>
> --
> Casualities in World Trade Center: ~3k dead inside the building,
> cryptography in U.S.A. and free speech in Czech Republic.
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by: Jabber - The world's fastest growing
> real-time communications platform! Don't just IM. Build it in!
> http://www.jabber.com/osdn/xim
> _______________________________________________
> Lse-tech mailing list
> Lse-tech@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/lse-tech
--
Timothy D. Witham - Lab Director - wookie@osdlab.org
Open Source Development Lab Inc - A non-profit corporation
15275 SW Koll Parkway - Suite H - Beaverton OR, 97006
(503)-626-2455 x11 (office) (503)-702-2871 (cell)
(503)-626-2436 (fax)
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [Lse-tech] Re: [patch] SImple Topology API v0.3 (1/2)
2002-08-28 22:31 ` [Lse-tech] " Timothy D. Witham
@ 2002-08-28 22:40 ` Thunder from the hill
2002-08-28 22:42 ` Timothy D. Witham
0 siblings, 1 reply; 12+ messages in thread
From: Thunder from the hill @ 2002-08-28 22:40 UTC (permalink / raw)
To: Timothy D. Witham
Cc: Pavel Machek, Thunder from the hill, Matthew Dobson,
Andrew Morton, Linus Torvalds, linux-kernel, linux-mm,
Martin Bligh, Andrea Arcangeli, Michael Hohnbaum, lse-tech
Hi,
On 28 Aug 2002, Timothy D. Witham wrote:
> How about the old Marketing name CONFIG_CCNUMA?
Why not keep CONFIG_X86_NUMA then?
Thunder
--
--./../...-/. -.--/---/..-/.-./..././.-../..-. .---/..-/.../- .-
--/../-./..-/-/./--..-- ../.----./.-../.-.. --./../...-/. -.--/---/..-
.- -/---/--/---/.-./.-./---/.--/.-.-.-
--./.-/-.../.-./.././.-../.-.-.-
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [Lse-tech] Re: [patch] SImple Topology API v0.3 (1/2)
2002-08-28 22:40 ` Thunder from the hill
@ 2002-08-28 22:42 ` Timothy D. Witham
0 siblings, 0 replies; 12+ messages in thread
From: Timothy D. Witham @ 2002-08-28 22:42 UTC (permalink / raw)
To: Thunder from the hill
Cc: Pavel Machek, Matthew Dobson, Andrew Morton, Linus Torvalds,
linux-kernel, linux-mm, Martin Bligh, Andrea Arcangeli,
Michael Hohnbaum, lse-tech
that I was thinking of is that you might have
a case in the future where you would like to break out
some of the stuff into say ... PPC or SPARC NUMA and also
X86 NUMA but still keep the Cache Coherent NUMA configuration
as a base. But that is just wild talk from somebody
who knows wild talk. :-)
Tim
On Wed, 2002-08-28 at 15:40, Thunder from the hill wrote:
> Hi,
>
> On 28 Aug 2002, Timothy D. Witham wrote:
> > How about the old Marketing name CONFIG_CCNUMA?
>
> Why not keep CONFIG_X86_NUMA then?
>
> Thunder
> --
> --./../...-/. -.--/---/..-/.-./..././.-../..-. .---/..-/.../- .-
> --/../-./..-/-/./--..-- ../.----./.-../.-.. --./../...-/. -.--/---/..-
> .- -/---/--/---/.-./.-./---/.--/.-.-.-
> --./.-/-.../.-./.././.-../.-.-.-
--
Timothy D. Witham - Lab Director - wookie@osdlab.org
Open Source Development Lab Inc - A non-profit corporation
15275 SW Koll Parkway - Suite H - Beaverton OR, 97006
(503)-626-2455 x11 (office) (503)-702-2871 (cell)
(503)-626-2436 (fax)
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2002-08-28 22:42 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-08-22 19:13 [patch] SImple Topology API v0.3 (1/2) Matthew Dobson
2002-08-22 19:22 ` [Lse-tech] " Christoph Hellwig
2002-08-22 20:41 ` Matthew Dobson
2002-08-22 20:48 ` Christoph Hellwig
2002-08-27 14:31 ` Pavel Machek
2002-08-27 21:18 ` Andrea Arcangeli
2002-08-28 13:14 ` Thunder from the hill
2002-08-28 19:29 ` Pavel Machek
2002-08-28 20:02 ` Thunder from the hill
2002-08-28 22:31 ` [Lse-tech] " Timothy D. Witham
2002-08-28 22:40 ` Thunder from the hill
2002-08-28 22:42 ` Timothy D. Witham
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox