* Which architectures need 64-bit resources?
@ 2006-11-06 12:23 Matthew Wilcox
2006-11-06 12:52 ` Arnd Bergmann
2006-11-06 16:02 ` Ralf Baechle
0 siblings, 2 replies; 8+ messages in thread
From: Matthew Wilcox @ 2006-11-06 12:23 UTC (permalink / raw)
To: linux-arch
I have a patch sitting in the parisc tree which does:
config RESOURCES_64BIT
- bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && EXPER
IMENTAL)
+ bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && !PARI
SC && EXPERIMENTAL)
default 64BIT
This is a bit selfish really, and it'll lead to something pretty ugly and
unmaintainable ...
+ bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && !PARISC && !M68K && !AVR && !CRIS && !FRV && !H8300 && !M32R && !S390 && !SUPERH && !SPARC && !V850 && !XTENSA && EXPERIMENTAL)
at least if my understanding of those arches needs is correct. Much better
to have the dependencies be positive:
+ bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && (ARM || X86 || MIPS || PPC) && EXPERIMENTAL)
Do I have that set of architectures right? Any others that need 64 bit
resource types? Any there that shouldn't be there? Should we ditch
the EXPERIMENTAL tag at the same time?
^ permalink raw reply [flat|nested] 8+ messages in thread* Re: Which architectures need 64-bit resources? 2006-11-06 12:23 Which architectures need 64-bit resources? Matthew Wilcox @ 2006-11-06 12:52 ` Arnd Bergmann 2006-11-06 16:02 ` Ralf Baechle 1 sibling, 0 replies; 8+ messages in thread From: Arnd Bergmann @ 2006-11-06 12:52 UTC (permalink / raw) To: Matthew Wilcox; +Cc: linux-arch On Monday 06 November 2006 13:23, Matthew Wilcox wrote: > + bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && (ARM || X86 || MIPS || PPC) && EXPERIMENTAL) > How about reversing the logic to make it bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (RESOURCES_64BIT_ENABLE && EXPERIMENTAL) Then each architecture could either have config RESOURCES_64BIT_ENABLE def_bool y if !64BIT or even select RESOURCES_64BIT to switch it on unconditionally. Arnd <>< ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Which architectures need 64-bit resources? 2006-11-06 12:23 Which architectures need 64-bit resources? Matthew Wilcox 2006-11-06 12:52 ` Arnd Bergmann @ 2006-11-06 16:02 ` Ralf Baechle 2006-11-06 16:32 ` Matthew Wilcox 1 sibling, 1 reply; 8+ messages in thread From: Ralf Baechle @ 2006-11-06 16:02 UTC (permalink / raw) To: Matthew Wilcox; +Cc: linux-arch On Mon, Nov 06, 2006 at 05:23:37AM -0700, Matthew Wilcox wrote: > + bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && (ARM || X86 || MIPS || PPC) && EXPERIMENTAL) For MIPS at least it would be needed for a few platforms only, so I'd like to do "select RESOURCES_64BIT" as suitable for a platform. in the big machine selection menu in arch/mips/Kconfig. Ralf ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Which architectures need 64-bit resources? 2006-11-06 16:02 ` Ralf Baechle @ 2006-11-06 16:32 ` Matthew Wilcox 2006-11-06 17:13 ` Ralf Baechle ` (2 more replies) 0 siblings, 3 replies; 8+ messages in thread From: Matthew Wilcox @ 2006-11-06 16:32 UTC (permalink / raw) To: Ralf Baechle; +Cc: linux-arch, Vivek Goyal On Mon, Nov 06, 2006 at 04:02:06PM +0000, Ralf Baechle wrote: > On Mon, Nov 06, 2006 at 05:23:37AM -0700, Matthew Wilcox wrote: > > > + bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && (ARM || X86 || MIPS || PPC) && EXPERIMENTAL) > > For MIPS at least it would be needed for a few platforms only, so I'd > like to do "select RESOURCES_64BIT" as suitable for a platform. in the > big machine selection menu in arch/mips/Kconfig. I don't see why you shouldn't do that anyway ... seems like ARM wants to do the same thing. In fact, I'd go so far as to say this isn't an option that users should ever be asked. You can tell by the help text for it: help This option allows memory and IO resources to be 64 bit. How ... helpful. Here's a proposed patch (which needs buy-in from the ARM, MIPS and PowerPC guys, plus anyone who knows about x86-32 machines with 64-bit IO). Grepping the arch/*/configs/* doesn't show anyone else using it by default. I got the info for ARM from Vince Sanders, and made my best guess for MIPS & PPC. This patch is entirely untested. diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index adb05de..d73cf59 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -241,6 +241,7 @@ config ARCH_IXP23XX bool "IXP23XX-based" depends on MMU select PCI + select RESOURCES_64BIT help Support for Intel's IXP23xx (XScale) family of processors. diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index 8a49884..f0205e0 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig @@ -1556,6 +1556,7 @@ config SB1_PASS_2_1_WORKAROUNDS config 64BIT_PHYS_ADDR bool "Support for 64-bit physical address space" depends on (CPU_R4X00 || CPU_R5000 || CPU_RM7000 || CPU_RM9000 || CPU_R10000 || CPU_SB1 || CPU_MIPS32 || CPU_MIPS64) && 32BIT + select RESOURCES_64BIT config CPU_HAS_LLSC bool diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig index 8b69104..29ab1e0 100644 --- a/arch/powerpc/Kconfig +++ b/arch/powerpc/Kconfig @@ -227,10 +227,11 @@ config PTE_64BIT config PHYS_64BIT bool 'Large physical address support' if E500 depends on 44x || E500 + select RESOURCES_64BIT default y if 44x ---help--- This option enables kernel support for larger than 32-bit physical - addresses. This features is not be available on all e500 cores. + addresses. This features is not available on all e500 cores. If in doubt, say N here. diff --git a/lib/Kconfig b/lib/Kconfig index 734ce95..613942d 100644 --- a/lib/Kconfig +++ b/lib/Kconfig @@ -92,9 +92,14 @@ config TEXTSEARCH_FSM tristate # -# plist support is select#ed if needed +# plist support is selected if needed # config PLIST boolean +# 64-bit resources are selected by individual architectures +config RESOURCES_64BIT + bool + default 64BIT + endmenu diff --git a/mm/Kconfig b/mm/Kconfig index db7c55d..089513f 100644 --- a/mm/Kconfig +++ b/mm/Kconfig @@ -151,9 +151,3 @@ config MIGRATION while the virtual addresses are not changed. This is useful for example on NUMA systems to put pages nearer to the processors accessing the page. - -config RESOURCES_64BIT - bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && EXPERIMENTAL) - default 64BIT - help - This option allows memory and IO resources to be 64 bit. ^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: Which architectures need 64-bit resources? 2006-11-06 16:32 ` Matthew Wilcox @ 2006-11-06 17:13 ` Ralf Baechle 2006-11-07 1:37 ` Geert Uytterhoeven 2006-11-07 9:36 ` Russell King 2 siblings, 0 replies; 8+ messages in thread From: Ralf Baechle @ 2006-11-06 17:13 UTC (permalink / raw) To: Matthew Wilcox; +Cc: linux-arch, Vivek Goyal On Mon, Nov 06, 2006 at 09:32:43AM -0700, Matthew Wilcox wrote: > Here's a proposed patch (which needs buy-in from the ARM, MIPS and > PowerPC guys, plus anyone who knows about x86-32 machines with 64-bit > IO). Grepping the arch/*/configs/* doesn't show anyone else using it by > default. > > I got the info for ARM from Vince Sanders, and made my best guess for > MIPS & PPC. This patch is entirely untested. The MIPS segment looks good, so feel free to add an Acked-by me. Ralf ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Which architectures need 64-bit resources? 2006-11-06 16:32 ` Matthew Wilcox 2006-11-06 17:13 ` Ralf Baechle @ 2006-11-07 1:37 ` Geert Uytterhoeven 2006-11-07 3:33 ` Matthew Wilcox 2006-11-07 9:36 ` Russell King 2 siblings, 1 reply; 8+ messages in thread From: Geert Uytterhoeven @ 2006-11-07 1:37 UTC (permalink / raw) To: Matthew Wilcox; +Cc: Ralf Baechle, linux-arch, Vivek Goyal On Mon, 6 Nov 2006, Matthew Wilcox wrote: > On Mon, Nov 06, 2006 at 04:02:06PM +0000, Ralf Baechle wrote: > > On Mon, Nov 06, 2006 at 05:23:37AM -0700, Matthew Wilcox wrote: > > > > > + bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && (ARM || X86 || MIPS || PPC) && EXPERIMENTAL) > > > > For MIPS at least it would be needed for a few platforms only, so I'd > > like to do "select RESOURCES_64BIT" as suitable for a platform. in the > > big machine selection menu in arch/mips/Kconfig. > > I don't see why you shouldn't do that anyway ... seems like ARM wants to > do the same thing. In fact, I'd go so far as to say this isn't an option > that users should ever be asked. You can tell by the help text for it: Ah, good that the `possibility' of 64-bit resources on m68k goes away, and I haven't `fixed' all those printf() format warnings yet... Speaking about that: how many recently-added silencing casts should be removed on platforms without 64-bit resources? Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Which architectures need 64-bit resources? 2006-11-07 1:37 ` Geert Uytterhoeven @ 2006-11-07 3:33 ` Matthew Wilcox 0 siblings, 0 replies; 8+ messages in thread From: Matthew Wilcox @ 2006-11-07 3:33 UTC (permalink / raw) To: Geert Uytterhoeven; +Cc: Ralf Baechle, linux-arch, Vivek Goyal On Tue, Nov 07, 2006 at 02:37:46AM +0100, Geert Uytterhoeven wrote: > Ah, good that the `possibility' of 64-bit resources on m68k goes away, and I > haven't `fixed' all those printf() format warnings yet... > > Speaking about that: how many recently-added silencing casts should be removed > on platforms without 64-bit resources? Absolutely none, I'm afraid. struct resource { resource_size_t start; resource_size_t end; ... GCC complains about resource_size_t, no matter what you typedef it to be. It'd be nice if we could tell GCC that %r meant it'd consume a resource_size_t, but afaict, there's no ability to define additions to the format attribute. Viro's mused on disabling the printk checking entirely with gcc and just using sparse to verify format strings (so we can add our own types, etc), but I don't think that's realistic unless a lot more people start installing sparse. And widespread adoption of sparse seems unlikely, given that it's under OSL 1.1 which means it can't go into Debian [1]. GCC's in Stage 1 ... anyone want to write a patch to c-format.c? [1] http://wiki.debian.org/DFSGLicenses#head-2b7e4b3507dcc5657dabaf145df20d6c7d41f159 ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Which architectures need 64-bit resources? 2006-11-06 16:32 ` Matthew Wilcox 2006-11-06 17:13 ` Ralf Baechle 2006-11-07 1:37 ` Geert Uytterhoeven @ 2006-11-07 9:36 ` Russell King 2 siblings, 0 replies; 8+ messages in thread From: Russell King @ 2006-11-07 9:36 UTC (permalink / raw) To: Matthew Wilcox; +Cc: Ralf Baechle, linux-arch, Vivek Goyal On Mon, Nov 06, 2006 at 09:32:43AM -0700, Matthew Wilcox wrote: > On Mon, Nov 06, 2006 at 04:02:06PM +0000, Ralf Baechle wrote: > > On Mon, Nov 06, 2006 at 05:23:37AM -0700, Matthew Wilcox wrote: > > > > > + bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && (ARM || X86 || MIPS || PPC) && EXPERIMENTAL) > > > > For MIPS at least it would be needed for a few platforms only, so I'd > > like to do "select RESOURCES_64BIT" as suitable for a platform. in the > > big machine selection menu in arch/mips/Kconfig. > > I don't see why you shouldn't do that anyway ... seems like ARM wants to > do the same thing. In fact, I'd go so far as to say this isn't an option > that users should ever be asked. You can tell by the help text for it: For the ARM bits... Acked-by: Russell King <rmk+kernel@arm.linux.org.uk> Thanks. -- Russell King Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/ maintainer of: 2.6 Serial core ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2006-11-07 9:36 UTC | newest] Thread overview: 8+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2006-11-06 12:23 Which architectures need 64-bit resources? Matthew Wilcox 2006-11-06 12:52 ` Arnd Bergmann 2006-11-06 16:02 ` Ralf Baechle 2006-11-06 16:32 ` Matthew Wilcox 2006-11-06 17:13 ` Ralf Baechle 2006-11-07 1:37 ` Geert Uytterhoeven 2006-11-07 3:33 ` Matthew Wilcox 2006-11-07 9:36 ` Russell King
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox