* Re: /sbin/init: error while loading shared libraries: libm.so.6:cannot open shared object file: No such file or directory [Scanned]
From: S. Fricke @ 2007-11-15 12:52 UTC (permalink / raw)
To: linuxppc-embedded
In-Reply-To: <1195129440.10980.7.camel@linux-2drc.site>
[-- Attachment #1: Type: text/plain, Size: 1145 bytes --]
Hello,
> I have a problem with booting the uRamdisk image from eldk 4.1 on an
> TQM5200 (MPC5200 CPU) board.
> I have taken the uRamdisk image from the "/eldk/ppc_6xx/images" folder
> and copied it to the flash. After booting the following output came
> after the Kernel boot:
>
> Freeing unused kernel memory: 64k init
> /sbin/init: error while loading shared libraries: libm.so.6: cannot open
> shared object file: No such file or directory
> Kernel panic: Attempted to kill init!
> <0>Rebooting in 1 seconds..
>
>
> An image from eldk 3.1.1 is working fine with the Kernel 2.4.25.
> The files libm.so.6 and libm-2.3.5.so are available in the /lib folder.
>
> Does anyone has an idea, what this could be?
This is a problem of handling the eldk. Please contact the eldk-ml on [1].
[1] http://lists.denx.de/mailman/listinfo/eldk
Bye!
eS.eF.
--
-- S. Fricke ----------------------------- MAILTO:silvio.fricke@gmail.com --
Diplom-Informatiker (FH)
Linux-Entwicklung JABBER: silvio@jabber.ccc.de
----------------------------------------------------------------------------
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply
* /sbin/init: error while loading shared libraries: libm.so.6:cannot open shared object file: No such file or directory [Scanned]
From: Lindner @ 2007-11-15 12:24 UTC (permalink / raw)
To: linuxppc-embedded
Hello,
I have a problem with booting the uRamdisk image from eldk 4.1 on an
TQM5200 (MPC5200 CPU) board.
I have taken the uRamdisk image from the "/eldk/ppc_6xx/images" folder
and copied it to the flash. After booting the following output came
after the Kernel boot:
Freeing unused kernel memory: 64k init
/sbin/init: error while loading shared libraries: libm.so.6: cannot open
shared object file: No such file or directory
Kernel panic: Attempted to kill init!
<0>Rebooting in 1 seconds..
An image from eldk 3.1.1 is working fine with the Kernel 2.4.25.
The files libm.so.6 and libm-2.3.5.so are available in the /lib folder.
Does anyone has an idea, what this could be?
Thanks,
Michael
^ permalink raw reply
* Re: [PATCH 2/2] ps3fb: video memory size cleanups
From: Geert Uytterhoeven @ 2007-11-15 12:00 UTC (permalink / raw)
To: Andrew Morton; +Cc: Linux/PPC Development
In-Reply-To: <Pine.LNX.4.62.0711151152290.19455@pademelon.sonytel.be>
[-- Attachment #1: Type: TEXT/PLAIN, Size: 2268 bytes --]
ps3fb: video memory size cleanups:
- Limit video memory size to avoid crossing a 256 MiB boundary in IOIF space.
- Pass the actual amount of video memory used to lv1_gpu_memory_allocate().
Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
---
FIXME Booting with `ps3fb=49M' should work now. Except that on recent
kernels the system goes out of memory before you get there :-(
drivers/video/ps3fb.c | 11 +++++++++--
1 files changed, 9 insertions(+), 2 deletions(-)
--- a/drivers/video/ps3fb.c
+++ b/drivers/video/ps3fb.c
@@ -51,7 +51,6 @@
#define L1GPU_DISPLAY_SYNC_HSYNC 1
#define L1GPU_DISPLAY_SYNC_VSYNC 2
-#define DDR_SIZE (0) /* used no ddr */
#define GPU_CMD_BUF_SIZE (64 * 1024)
#define GPU_IOIF (0x0d000000UL)
#define GPU_ALIGN_UP(x) _ALIGN_UP((x), 64)
@@ -1060,6 +1059,7 @@ static int __devinit ps3fb_probe(struct
u64 xdr_lpar;
int status, res_index;
struct task_struct *task;
+ unsigned long max_ps3fb_size;
status = ps3_open_hv_device(dev);
if (status) {
@@ -1085,8 +1085,15 @@ static int __devinit ps3fb_probe(struct
ps3fb_set_sync(&dev->core);
+ max_ps3fb_size = _ALIGN_UP(GPU_IOIF, 256*1024*1024) - GPU_IOIF;
+ if (ps3fb_videomemory.size > max_ps3fb_size) {
+ dev_info(&dev->core, "Limiting ps3fb mem size to %lu bytes\n",
+ max_ps3fb_size);
+ ps3fb_videomemory.size = max_ps3fb_size;
+ }
+
/* get gpu context handle */
- status = lv1_gpu_memory_allocate(DDR_SIZE, 0, 0, 0, 0,
+ status = lv1_gpu_memory_allocate(ps3fb_videomemory.size, 0, 0, 0, 0,
&ps3fb.memory_handle, &ddr_lpar);
if (status) {
dev_err(&dev->core, "%s: lv1_gpu_memory_allocate failed: %d\n",
With kind regards,
Geert Uytterhoeven
Software Architect
Sony Network and Software Technology Center Europe
The Corporate Village · Da Vincilaan 7-D1 · B-1935 Zaventem · Belgium
Phone: +32 (0)2 700 8453
Fax: +32 (0)2 700 8622
E-mail: Geert.Uytterhoeven@sonycom.com
Internet: http://www.sony-europe.com/
Sony Network and Software Technology Center Europe
A division of Sony Service Centre (Europe) N.V.
Registered office: Technologielaan 7 · B-1840 Londerzeel · Belgium
VAT BE 0413.825.160 · RPR Brussels
Fortis Bank Zaventem · Swift GEBABEBB08A · IBAN BE39001382358619
^ permalink raw reply
* [PATCH v6 04/13] [POWERPC] Add generic support for simple MPC5200 based boards
From: Marian Balakowicz @ 2007-11-15 11:40 UTC (permalink / raw)
To: linuxppc-dev
This patch adds support for 'mpc5200-simple-platform' compatible
boards which do not need a platform specific setup. Such boards
are supported assuming the following:
- GPIO pins are configured by the firmware,
- CDM configuration (clocking) is setup correctly by firmware,
- if the 'fsl,has-wdt' property is present in one of the
gpt nodes, then it is safe to use such gpt to reset the board,
- PCI is supported if enabled in the kernel configuration
and if there is a PCI bus node defined in the device tree.
Signed-off-by: Marian Balakowicz <m8@semihalf.com>
---
Once more, this is a updated version of the patch 04/13 from
the patchset that adds arch/powerpc support for three MPC5200 based boards:
TQ-Components TQM5200, Schindler CM5200 and Promess Motion-PRO.
Thanks to Stephen Rothwell for catching inconsistencies that
sneaked in.
Cheers,
Marian Balakowicz
arch/powerpc/boot/dts/lite5200.dts | 2 -
arch/powerpc/boot/dts/lite5200b.dts | 2 -
arch/powerpc/platforms/52xx/Kconfig | 22 ++++++-
arch/powerpc/platforms/52xx/Makefile | 1
arch/powerpc/platforms/52xx/mpc5200_simple.c | 85 ++++++++++++++++++++++++++
5 files changed, 108 insertions(+), 4 deletions(-)
create mode 100644 arch/powerpc/platforms/52xx/mpc5200_simple.c
diff --git a/arch/powerpc/boot/dts/lite5200.dts b/arch/powerpc/boot/dts/lite5200.dts
index 6731763..5902362 100644
--- a/arch/powerpc/boot/dts/lite5200.dts
+++ b/arch/powerpc/boot/dts/lite5200.dts
@@ -19,7 +19,7 @@
/ {
model = "fsl,lite5200";
// revision = "1.0";
- compatible = "fsl,lite5200","generic-mpc5200";
+ compatible = "fsl,lite5200";
#address-cells = <1>;
#size-cells = <1>;
diff --git a/arch/powerpc/boot/dts/lite5200b.dts b/arch/powerpc/boot/dts/lite5200b.dts
index b540388..b509129 100644
--- a/arch/powerpc/boot/dts/lite5200b.dts
+++ b/arch/powerpc/boot/dts/lite5200b.dts
@@ -19,7 +19,7 @@
/ {
model = "fsl,lite5200b";
// revision = "1.0";
- compatible = "fsl,lite5200b","generic-mpc5200";
+ compatible = "fsl,lite5200b";
#address-cells = <1>;
#size-cells = <1>;
diff --git a/arch/powerpc/platforms/52xx/Kconfig b/arch/powerpc/platforms/52xx/Kconfig
index 2938d49..36e880b 100644
--- a/arch/powerpc/platforms/52xx/Kconfig
+++ b/arch/powerpc/platforms/52xx/Kconfig
@@ -19,6 +19,26 @@ config PPC_MPC5200_BUGFIX
It is safe to say 'Y' here
+config PPC_MPC5200_SIMPLE
+ bool "Generic support for simple MPC5200 based boards"
+ depends on PPC_MULTIPLATFORM && PPC32
+ select PPC_MPC5200
+ default n
+ help
+ This option enables support for a simple MPC52xx based boards which
+ do not need a custom platform specific setup. Such boards are
+ supported assuming the following:
+
+ - GPIO pins are configured by the firmware,
+ - CDM configuration (clocking) is setup correctly by firmware,
+ - if the 'fsl,has-wdt' property is present in one of the
+ gpt nodes, then it is safe to use such gpt to reset the board,
+ - PCI is supported if enabled in the kernel configuration
+ and if there is a PCI bus node defined in the device tree.
+
+ Boards that are compatible with this generic platform support
+ are: 'tqc,tqm5200', 'promess,motionpro', 'schindler,cm5200'.
+
config PPC_EFIKA
bool "bPlan Efika 5k2. MPC5200B based computer"
depends on PPC_MULTIPLATFORM && PPC32
@@ -34,5 +54,3 @@ config PPC_LITE5200
select WANT_DEVICE_TREE
select PPC_MPC5200
default n
-
-
diff --git a/arch/powerpc/platforms/52xx/Makefile b/arch/powerpc/platforms/52xx/Makefile
index 307dbc1..fe1b81b 100644
--- a/arch/powerpc/platforms/52xx/Makefile
+++ b/arch/powerpc/platforms/52xx/Makefile
@@ -6,6 +6,7 @@ obj-y += mpc52xx_pic.o mpc52xx_common.o
obj-$(CONFIG_PCI) += mpc52xx_pci.o
endif
+obj-$(CONFIG_PPC_MPC5200_SIMPLE) += mpc5200_simple.o
obj-$(CONFIG_PPC_EFIKA) += efika.o
obj-$(CONFIG_PPC_LITE5200) += lite5200.o
diff --git a/arch/powerpc/platforms/52xx/mpc5200_simple.c b/arch/powerpc/platforms/52xx/mpc5200_simple.c
new file mode 100644
index 0000000..754aa93
--- /dev/null
+++ b/arch/powerpc/platforms/52xx/mpc5200_simple.c
@@ -0,0 +1,85 @@
+/*
+ * Support for 'mpc5200-simple-platform' compatible boards.
+ *
+ * Written by Marian Balakowicz <m8@semihalf.com>
+ * Copyright (C) 2007 Semihalf
+ *
+ * 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.
+ *
+ * Description:
+ * This code implements support for a simple MPC52xx based boards which
+ * do not need a custom platform specific setup. Such boards are
+ * supported assuming the following:
+ *
+ * - GPIO pins are configured by the firmware,
+ * - CDM configuration (clocking) is setup correctly by firmware,
+ * - if the 'fsl,has-wdt' property is present in one of the
+ * gpt nodes, then it is safe to use such gpt to reset the board,
+ * - PCI is supported if enabled in the kernel configuration
+ * and if there is a PCI bus node defined in the device tree.
+ *
+ * Boards that are compatible with this generic platform support
+ * are listed in a 'board' table.
+ */
+
+#undef DEBUG
+#include <asm/time.h>
+#include <asm/prom.h>
+#include <asm/machdep.h>
+#include <asm/mpc52xx.h>
+
+/*
+ * Setup the architecture
+ */
+static void __init mpc5200_simple_setup_arch(void)
+{
+ if (ppc_md.progress)
+ ppc_md.progress("mpc5200_simple_setup_arch()", 0);
+
+ /* Some mpc5200 & mpc5200b related configuration */
+ mpc5200_setup_xlb_arbiter();
+
+ /* Map wdt for mpc52xx_restart() */
+ mpc52xx_map_wdt();
+
+ mpc52xx_setup_pci();
+}
+
+/* list of the supported boards */
+static char *board[] __initdata = {
+ "promess,motionpro",
+ "schindler,cm5200",
+ "tqc,tqm5200",
+ NULL
+};
+
+/*
+ * Called very early, MMU is off, device-tree isn't unflattened
+ */
+static int __init mpc5200_simple_probe(void)
+{
+ unsigned long node = of_get_flat_dt_root();
+ int i = 0;
+
+ while (board[i]) {
+ if (of_flat_dt_is_compatible(node, board[i]))
+ break;
+ i++;
+ }
+
+ return (board[i] != NULL);
+}
+
+define_machine(mpc5200_simple_platform) {
+ .name = "mpc5200-simple-platform",
+ .probe = mpc5200_simple_probe,
+ .setup_arch = mpc5200_simple_setup_arch,
+ .init = mpc52xx_declare_of_platform_devices,
+ .init_IRQ = mpc52xx_init_irq,
+ .get_irq = mpc52xx_get_irq,
+ .restart = mpc52xx_restart,
+ .calibrate_decr = generic_calibrate_decr,
+};
^ permalink raw reply related
* Re: [PATCH v5 04/13] [POWERPC] Add generic support for simple MPC5200 based boards
From: Marian Balakowicz @ 2007-11-15 11:06 UTC (permalink / raw)
To: Stephen Rothwell; +Cc: linuxppc-dev
In-Reply-To: <20071115102149.898061fb.sfr@canb.auug.org.au>
Hi Stephen,
Stephen Rothwell wrote:
>
> On Wed, 14 Nov 2007 11:21:37 +0100 Marian Balakowicz <m8@semihalf.com> wrote:
>> +++ b/arch/powerpc/platforms/52xx/mpc5200_simple.c
>> +#include <asm/time.h>
>> +#include <asm/machdep.h>
>> +#include <asm/mpc52xx.h>
>
> You still need asm/prom.h because you use of_get_flat_dt_root() and
> of_flat_dt_is_compatible().
>
>> +/* list of the supported boards */
>> +static const char *board[] __initdata = {
>
> Unfortunately you can't use "const" and "__initdata", so just remove the
> "const". (const changes the attributes on the section that __initdata is
> stored in.)
Arghh, too much of a hurry it seems, thanks for catching it.
Cheers,
m.
^ permalink raw reply
* Re: [PATCH] Fix boot problem with iSeries lacking hugepage support
From: Mel Gorman @ 2007-11-15 11:06 UTC (permalink / raw)
To: Andrew Morton; +Cc: linux-mm, linuxppc-dev, linux-kernel, sfr
In-Reply-To: <20071115023216.44002c28.akpm@linux-foundation.org>
On (15/11/07 02:32), Andrew Morton didst pronounce:
> On Thu, 15 Nov 2007 10:13:22 +0000 mel@skynet.ie (Mel Gorman) wrote:
>
> > This patch is a fix for 2.6.24.
> >
> > Ordinarily the size of a pageblock is determined at compile-time based on the
> > hugepage size. On PPC64, the hugepage size is determined at runtime based on
> > what is supported by the machine. With legacy machines such as iSeries that do
> > not support hugepages, HPAGE_SHIFT becomes 0. This results in pageblock_order
> > being set to -PAGE_SHIFT and a crash results shortly afterwards.
> >
> > This patch sets HUGETLB_PAGE_SIZE_VARIABLE for PPC64 and adds a function
> > to select a sensible value for pageblock order by default. It checks that
> > HPAGE_SHIFT is a sensible value before using the hugepage size; if it is
> > not MAX_ORDER-1 is used.
> >
> > Credit goes to Stephen Rothwell for identifying the bug and testing candidate
> > patches. Additional credit goes to Andy Whitcroft for spotting a problem
> > with respects to IA-64 before releasing. Additional credit to David Gibson
> > for testing with the libhugetlbfs test suite.
> >
>
> umm.
>
> > +
> > +/* Return a sensible default order for the pageblock size. */
> > +static inline int __init pageblock_default_order(void)
>
> inline and __init doesn't make sense.
>
I know the __init is meaningless in this context. It is there as a guide
if someone decides to drop the inline for some reason that it should
remain as __init. I can post a version with just the inline.
> > +{
> > + if (HPAGE_SHIFT > PAGE_SHIFT)
> > + return HUGETLB_PAGE_ORDER;
> > +
> > + return MAX_ORDER-1;
> > +}
> > +
> > /* Initialise the number of pages represented by NR_PAGEBLOCK_BITS */
> > static inline void __init set_pageblock_order(unsigned int order)
> > {
> > @@ -3357,7 +3367,7 @@ static inline void __init set_pageblock_
> > }
> > #else /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
> >
> > -/* Defined this way to avoid accidently referencing HUGETLB_PAGE_ORDER */
> > +#define pageblock_default_order(x) (0)
>
> that won't compile.
>
It's never used so it could have been anything and still compiled. I admit
this is confusing. I've posted a version below that changes this to a static
inline, returns MAX_ORDER-1 which is a sensible value even if unused and
comments on what is happening.
> > #define set_pageblock_order(x) do {} while (0)
> >
> > #endif /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
> > @@ -3442,7 +3452,7 @@ static void __meminit free_area_init_cor
> > if (!size)
> > continue;
> >
> > - set_pageblock_order(HUGETLB_PAGE_ORDER);
> > + set_pageblock_order(pageblock_default_order());
> > setup_usemap(pgdat, zone, size);
> > ret = init_currently_empty_zone(zone, zone_start_pfn,
>
>
> --- a/mm/page_alloc.c~fix-boot-problem-with-iseries-lacking-hugepage-support-fix
> +++ a/mm/page_alloc.c
> @@ -3268,7 +3268,7 @@ static void inline setup_usemap(struct p
> #ifdef CONFIG_HUGETLB_PAGE_SIZE_VARIABLE
>
> /* Return a sensible default order for the pageblock size. */
> -static inline int __init pageblock_default_order(void)
> +static inline int pageblock_default_order(void)
> {
> if (HPAGE_SHIFT > PAGE_SHIFT)
> return HUGETLB_PAGE_ORDER;
> @@ -3291,7 +3291,11 @@ static inline void __init set_pageblock_
> }
> #else /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
>
> -#define pageblock_default_order(x) (0)
> +static inline int pageblock_default_order(void)
> +{
> + return 0;
> +}
> +
> #define set_pageblock_order(x) do {} while (0)
>
> #endif /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
> _
>
>
> please avoid adding macros when C could have been used. C is nicer to look
> at and has typechecking and stuff.
>
Understood. Here is an updated version. It is functionally equivilant to
the earlier patch but may be easier on the eye
===
Ordinarily the size of a pageblock is determined at compile-time based on the
hugepage size. On PPC64, the hugepage size is determined at runtime based on
what is supported by the machine. With legacy machines such as iSeries that
do not support hugepages, HPAGE_SHIFT is 0. This results in pageblock_order
being set to -PAGE_SHIFT and a crash results shortly afterwards.
This patch adds a function to select a sensible value for pageblock order by
default when HUGETLB_PAGE_SIZE_VARIABLE is set. It checks that HPAGE_SHIFT
is a sensible value before using the hugepage size; if it is not MAX_ORDER-1
is used.
This is a fix for 2.6.24.
Credit goes to Stephen Rothwell for identifying the bug and testing candidate
patches. Additional credit goes to Andy Whitcroft for spotting a problem
with respects to IA-64 before releasing. Additional credit to David Gibson
for testing with the libhugetlbfs test suite.
Signed-off-by: Mel Gorman <mel@csn.ul.ie>
Tested-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
arch/powerpc/Kconfig | 5 +++++
mm/page_alloc.c | 23 +++++++++++++++++++++--
2 files changed, 26 insertions(+), 2 deletions(-)
diff -rup -X /usr/src/patchset-0.6/bin//dontdiff linux-2.6.24-rc2-mm1-clean/arch/powerpc/Kconfig linux-2.6.24-rc2-mm1-varpage-fix/arch/powerpc/Kconfig
--- linux-2.6.24-rc2-mm1-clean/arch/powerpc/Kconfig 2007-11-14 11:38:05.000000000 +0000
+++ linux-2.6.24-rc2-mm1-varpage-fix/arch/powerpc/Kconfig 2007-11-15 10:44:38.000000000 +0000
@@ -187,6 +187,11 @@ config FORCE_MAX_ZONEORDER
default "9" if PPC_64K_PAGES
default "13"
+config HUGETLB_PAGE_SIZE_VARIABLE
+ bool
+ depends on HUGETLB_PAGE
+ default y
+
config MATH_EMULATION
bool "Math emulation"
depends on 4xx || 8xx || E200 || PPC_MPC832x || E500
diff -rup -X /usr/src/patchset-0.6/bin//dontdiff linux-2.6.24-rc2-mm1-clean/mm/page_alloc.c linux-2.6.24-rc2-mm1-varpage-fix/mm/page_alloc.c
--- linux-2.6.24-rc2-mm1-clean/mm/page_alloc.c 2007-11-14 11:38:08.000000000 +0000
+++ linux-2.6.24-rc2-mm1-varpage-fix/mm/page_alloc.c 2007-11-15 11:01:13.000000000 +0000
@@ -3342,6 +3342,16 @@ static void inline setup_usemap(struct p
#endif /* CONFIG_SPARSEMEM */
#ifdef CONFIG_HUGETLB_PAGE_SIZE_VARIABLE
+
+/* Return a sensible default order for the pageblock size. */
+static inline int pageblock_default_order(void)
+{
+ if (HPAGE_SHIFT > PAGE_SHIFT)
+ return HUGETLB_PAGE_ORDER;
+
+ return MAX_ORDER-1;
+}
+
/* Initialise the number of pages represented by NR_PAGEBLOCK_BITS */
static inline void __init set_pageblock_order(unsigned int order)
{
@@ -3357,7 +3367,16 @@ static inline void __init set_pageblock_
}
#else /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
-/* Defined this way to avoid accidently referencing HUGETLB_PAGE_ORDER */
+/*
+ * When CONFIG_HUGETLB_PAGE_SIZE_VARIABLE is not set, set_pageblock_order()
+ * and pageblock_default_order() are unused as pageblock_order is set
+ * at compile-time. See include/linux/pageblock-flags.h for the values of
+ * pageblock_order based on the kernel config
+ */
+static inline int pageblock_default_order(unsigned int order)
+{
+ return MAX_ORDER-1;
+}
#define set_pageblock_order(x) do {} while (0)
#endif /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
@@ -3442,7 +3461,7 @@ static void __meminit free_area_init_cor
if (!size)
continue;
- set_pageblock_order(HUGETLB_PAGE_ORDER);
+ set_pageblock_order(pageblock_default_order());
setup_usemap(pgdat, zone, size);
ret = init_currently_empty_zone(zone, zone_start_pfn,
size, MEMMAP_EARLY);
--
--
Mel Gorman
Part-time Phd Student Linux Technology Center
University of Limerick IBM Dublin Software Lab
^ permalink raw reply
* Re: [PATCH] Fix boot problem with iSeries lacking hugepage support
From: Andrew Morton @ 2007-11-15 10:59 UTC (permalink / raw)
To: Mel Gorman; +Cc: linux-mm, linuxppc-dev, linux-kernel, sfr
In-Reply-To: <20071115105237.GD5128@skynet.ie>
On Thu, 15 Nov 2007 10:52:38 +0000 mel@skynet.ie (Mel Gorman) wrote:
> > Shouldn't this have been HUGETLB_PAGE_ORDER?
> >
>
> As a #define, possibly but as a static inline - definitly not.
>
> In this context, the define is not used because set_pageblock_order()
> is a no-op when CONFIG_HUGETLB_PAGE_SIZE_VARIABLE is unset.
> pageblock_default_order() is only defined for symmetry as set_pageblock_order()
> is defined in both contexts. However, as a #define it might make more sense
> to a casual reader to see HUGETLB_PAGE_ORDER even if it has no effect. I
> can send a version of the patch that does this with a comment explaining
> what is going on with set_pageblock_order() if you like.
>
> However, in a follow-up fix, you make pageblock_default_order() a static
> inline. If it tries to return HUGETLB_PAGE_ORDER, it will fail to compile
> when CONFIG_HUGETLB_PAGE is not set.
>
> Which would you prefer?
Don't care really. Something which is fixed up ;)
^ permalink raw reply
* [PATCH 0/2] PS3 patches for 2.6.24
From: Geert Uytterhoeven @ 2007-11-15 10:56 UTC (permalink / raw)
To: Andrew Morton; +Cc: Linux/PPC Development
[-- Attachment #1: Type: TEXT/PLAIN, Size: 938 bytes --]
Hi Andrew,
Here are 2 more patches for PS3 we would like to get in 2.6.24:
[1] ps3: Prefix all ps3-specific kernel modules with `ps3'
[2] ps3fb: video memory size cleanups
The first one fixes 2 PS3-specific modules having generic names.
The second one fixes a possible system lock up.
Please apply and forward to Linus, thanks!
With kind regards,
Geert Uytterhoeven
Software Architect
Sony Network and Software Technology Center Europe
The Corporate Village · Da Vincilaan 7-D1 · B-1935 Zaventem · Belgium
Phone: +32 (0)2 700 8453
Fax: +32 (0)2 700 8622
E-mail: Geert.Uytterhoeven@sonycom.com
Internet: http://www.sony-europe.com/
Sony Network and Software Technology Center Europe
A division of Sony Service Centre (Europe) N.V.
Registered office: Technologielaan 7 · B-1840 Londerzeel · Belgium
VAT BE 0413.825.160 · RPR Brussels
Fortis Bank Zaventem · Swift GEBABEBB08A · IBAN BE39001382358619
^ permalink raw reply
* Re: [PATCH] Fix boot problem with iSeries lacking hugepage support
From: Mel Gorman @ 2007-11-15 10:52 UTC (permalink / raw)
To: Andrew Morton; +Cc: linux-mm, linuxppc-dev, linux-kernel, sfr
In-Reply-To: <20071115023943.a54b0464.akpm@linux-foundation.org>
On (15/11/07 02:39), Andrew Morton didst pronounce:
> On Thu, 15 Nov 2007 10:13:22 +0000 mel@skynet.ie (Mel Gorman) wrote:
>
> > This patch is a fix for 2.6.24.
> >
> > Ordinarily the size of a pageblock is determined at compile-time based on the
> > hugepage size. On PPC64, the hugepage size is determined at runtime based on
> > what is supported by the machine. With legacy machines such as iSeries that do
> > not support hugepages, HPAGE_SHIFT becomes 0. This results in pageblock_order
> > being set to -PAGE_SHIFT and a crash results shortly afterwards.
> >
> > This patch sets HUGETLB_PAGE_SIZE_VARIABLE for PPC64 and adds a function
> > to select a sensible value for pageblock order by default. It checks that
> > HPAGE_SHIFT is a sensible value before using the hugepage size; if it is
> > not MAX_ORDER-1 is used.
> >
> > Credit goes to Stephen Rothwell for identifying the bug and testing candidate
> > patches. Additional credit goes to Andy Whitcroft for spotting a problem
> > with respects to IA-64 before releasing. Additional credit to David Gibson
> > for testing with the libhugetlbfs test suite.
> >
> > Signed-off-by: Mel Gorman <mel@csn.ul.ie>
> > Tested-by: Stephen Rothwell <sfr@canb.auug.org.au>
> >
> > ---
> > arch/powerpc/Kconfig | 5 +++++
> > mm/page_alloc.c | 14 ++++++++++++--
> > 2 files changed, 17 insertions(+), 2 deletions(-)
> >
> > diff -rup -X /usr/src/patchset-0.6/bin//dontdiff linux-2.6.24-rc2-mm1-clean/arch/powerpc/Kconfig linux-2.6.24-rc2-005_iSeries_fix/arch/powerpc/Kconfig
> > --- linux-2.6.24-rc2-mm1-clean/arch/powerpc/Kconfig 2007-11-14 11:38:05.000000000 +0000
> > +++ linux-2.6.24-rc2-005_iSeries_fix/arch/powerpc/Kconfig 2007-11-14 11:39:12.000000000 +0000
> > @@ -187,6 +187,11 @@ config FORCE_MAX_ZONEORDER
> > default "9" if PPC_64K_PAGES
> > default "13"
> >
> > +config HUGETLB_PAGE_SIZE_VARIABLE
> > + bool
> > + depends on HUGETLB_PAGE
> > + default y
> > +
> > config MATH_EMULATION
> > bool "Math emulation"
> > depends on 4xx || 8xx || E200 || PPC_MPC832x || E500
> > diff -rup -X /usr/src/patchset-0.6/bin//dontdiff linux-2.6.24-rc2-mm1-clean/mm/page_alloc.c linux-2.6.24-rc2-005_iSeries_fix/mm/page_alloc.c
> > --- linux-2.6.24-rc2-mm1-clean/mm/page_alloc.c 2007-11-14 11:38:08.000000000 +0000
> > +++ linux-2.6.24-rc2-005_iSeries_fix/mm/page_alloc.c 2007-11-14 13:45:19.000000000 +0000
> > @@ -3342,6 +3342,16 @@ static void inline setup_usemap(struct p
> > #endif /* CONFIG_SPARSEMEM */
> >
> > #ifdef CONFIG_HUGETLB_PAGE_SIZE_VARIABLE
> > +
> > +/* Return a sensible default order for the pageblock size. */
> > +static inline int __init pageblock_default_order(void)
> > +{
> > + if (HPAGE_SHIFT > PAGE_SHIFT)
> > + return HUGETLB_PAGE_ORDER;
> > +
> > + return MAX_ORDER-1;
> > +}
> > +
> > /* Initialise the number of pages represented by NR_PAGEBLOCK_BITS */
> > static inline void __init set_pageblock_order(unsigned int order)
> > {
> > @@ -3357,7 +3367,7 @@ static inline void __init set_pageblock_
> > }
> > #else /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
> >
> > -/* Defined this way to avoid accidently referencing HUGETLB_PAGE_ORDER */
> > +#define pageblock_default_order(x) (0)
>
> Shouldn't this have been HUGETLB_PAGE_ORDER?
>
As a #define, possibly but as a static inline - definitly not.
In this context, the define is not used because set_pageblock_order()
is a no-op when CONFIG_HUGETLB_PAGE_SIZE_VARIABLE is unset.
pageblock_default_order() is only defined for symmetry as set_pageblock_order()
is defined in both contexts. However, as a #define it might make more sense
to a casual reader to see HUGETLB_PAGE_ORDER even if it has no effect. I
can send a version of the patch that does this with a comment explaining
what is going on with set_pageblock_order() if you like.
However, in a follow-up fix, you make pageblock_default_order() a static
inline. If it tries to return HUGETLB_PAGE_ORDER, it will fail to compile
when CONFIG_HUGETLB_PAGE is not set.
Which would you prefer?
> > #define set_pageblock_order(x) do {} while (0)
> >
> > #endif /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
> > @@ -3442,7 +3452,7 @@ static void __meminit free_area_init_cor
> > if (!size)
> > continue;
> >
> > - set_pageblock_order(HUGETLB_PAGE_ORDER);
> > + set_pageblock_order(pageblock_default_order());
> > setup_usemap(pgdat, zone, size);
> > ret = init_currently_empty_zone(zone, zone_start_pfn,
> > size, MEMMAP_EARLY);
> > --
> > --
> > Mel Gorman
> > Part-time Phd Student Linux Technology Center
> > University of Limerick IBM Dublin Software Lab
>
--
--
Mel Gorman
Part-time Phd Student Linux Technology Center
University of Limerick IBM Dublin Software Lab
^ permalink raw reply
* Re: [PATCH] Fix boot problem with iSeries lacking hugepage support
From: Andrew Morton @ 2007-11-15 10:39 UTC (permalink / raw)
To: Mel Gorman; +Cc: linux-mm, linuxppc-dev, linux-kernel, sfr
In-Reply-To: <20071115101322.GA5128@skynet.ie>
On Thu, 15 Nov 2007 10:13:22 +0000 mel@skynet.ie (Mel Gorman) wrote:
> This patch is a fix for 2.6.24.
>
> Ordinarily the size of a pageblock is determined at compile-time based on the
> hugepage size. On PPC64, the hugepage size is determined at runtime based on
> what is supported by the machine. With legacy machines such as iSeries that do
> not support hugepages, HPAGE_SHIFT becomes 0. This results in pageblock_order
> being set to -PAGE_SHIFT and a crash results shortly afterwards.
>
> This patch sets HUGETLB_PAGE_SIZE_VARIABLE for PPC64 and adds a function
> to select a sensible value for pageblock order by default. It checks that
> HPAGE_SHIFT is a sensible value before using the hugepage size; if it is
> not MAX_ORDER-1 is used.
>
> Credit goes to Stephen Rothwell for identifying the bug and testing candidate
> patches. Additional credit goes to Andy Whitcroft for spotting a problem
> with respects to IA-64 before releasing. Additional credit to David Gibson
> for testing with the libhugetlbfs test suite.
>
> Signed-off-by: Mel Gorman <mel@csn.ul.ie>
> Tested-by: Stephen Rothwell <sfr@canb.auug.org.au>
>
> ---
> arch/powerpc/Kconfig | 5 +++++
> mm/page_alloc.c | 14 ++++++++++++--
> 2 files changed, 17 insertions(+), 2 deletions(-)
>
> diff -rup -X /usr/src/patchset-0.6/bin//dontdiff linux-2.6.24-rc2-mm1-clean/arch/powerpc/Kconfig linux-2.6.24-rc2-005_iSeries_fix/arch/powerpc/Kconfig
> --- linux-2.6.24-rc2-mm1-clean/arch/powerpc/Kconfig 2007-11-14 11:38:05.000000000 +0000
> +++ linux-2.6.24-rc2-005_iSeries_fix/arch/powerpc/Kconfig 2007-11-14 11:39:12.000000000 +0000
> @@ -187,6 +187,11 @@ config FORCE_MAX_ZONEORDER
> default "9" if PPC_64K_PAGES
> default "13"
>
> +config HUGETLB_PAGE_SIZE_VARIABLE
> + bool
> + depends on HUGETLB_PAGE
> + default y
> +
> config MATH_EMULATION
> bool "Math emulation"
> depends on 4xx || 8xx || E200 || PPC_MPC832x || E500
> diff -rup -X /usr/src/patchset-0.6/bin//dontdiff linux-2.6.24-rc2-mm1-clean/mm/page_alloc.c linux-2.6.24-rc2-005_iSeries_fix/mm/page_alloc.c
> --- linux-2.6.24-rc2-mm1-clean/mm/page_alloc.c 2007-11-14 11:38:08.000000000 +0000
> +++ linux-2.6.24-rc2-005_iSeries_fix/mm/page_alloc.c 2007-11-14 13:45:19.000000000 +0000
> @@ -3342,6 +3342,16 @@ static void inline setup_usemap(struct p
> #endif /* CONFIG_SPARSEMEM */
>
> #ifdef CONFIG_HUGETLB_PAGE_SIZE_VARIABLE
> +
> +/* Return a sensible default order for the pageblock size. */
> +static inline int __init pageblock_default_order(void)
> +{
> + if (HPAGE_SHIFT > PAGE_SHIFT)
> + return HUGETLB_PAGE_ORDER;
> +
> + return MAX_ORDER-1;
> +}
> +
> /* Initialise the number of pages represented by NR_PAGEBLOCK_BITS */
> static inline void __init set_pageblock_order(unsigned int order)
> {
> @@ -3357,7 +3367,7 @@ static inline void __init set_pageblock_
> }
> #else /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
>
> -/* Defined this way to avoid accidently referencing HUGETLB_PAGE_ORDER */
> +#define pageblock_default_order(x) (0)
Shouldn't this have been HUGETLB_PAGE_ORDER?
> #define set_pageblock_order(x) do {} while (0)
>
> #endif /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
> @@ -3442,7 +3452,7 @@ static void __meminit free_area_init_cor
> if (!size)
> continue;
>
> - set_pageblock_order(HUGETLB_PAGE_ORDER);
> + set_pageblock_order(pageblock_default_order());
> setup_usemap(pgdat, zone, size);
> ret = init_currently_empty_zone(zone, zone_start_pfn,
> size, MEMMAP_EARLY);
> --
> --
> Mel Gorman
> Part-time Phd Student Linux Technology Center
> University of Limerick IBM Dublin Software Lab
^ permalink raw reply
* Re: [PATCH] Fix boot problem with iSeries lacking hugepage support
From: Andrew Morton @ 2007-11-15 10:32 UTC (permalink / raw)
To: Mel Gorman; +Cc: linux-mm, linuxppc-dev, linux-kernel, sfr
In-Reply-To: <20071115101322.GA5128@skynet.ie>
On Thu, 15 Nov 2007 10:13:22 +0000 mel@skynet.ie (Mel Gorman) wrote:
> This patch is a fix for 2.6.24.
>
> Ordinarily the size of a pageblock is determined at compile-time based on the
> hugepage size. On PPC64, the hugepage size is determined at runtime based on
> what is supported by the machine. With legacy machines such as iSeries that do
> not support hugepages, HPAGE_SHIFT becomes 0. This results in pageblock_order
> being set to -PAGE_SHIFT and a crash results shortly afterwards.
>
> This patch sets HUGETLB_PAGE_SIZE_VARIABLE for PPC64 and adds a function
> to select a sensible value for pageblock order by default. It checks that
> HPAGE_SHIFT is a sensible value before using the hugepage size; if it is
> not MAX_ORDER-1 is used.
>
> Credit goes to Stephen Rothwell for identifying the bug and testing candidate
> patches. Additional credit goes to Andy Whitcroft for spotting a problem
> with respects to IA-64 before releasing. Additional credit to David Gibson
> for testing with the libhugetlbfs test suite.
>
umm.
> +
> +/* Return a sensible default order for the pageblock size. */
> +static inline int __init pageblock_default_order(void)
inline and __init doesn't make sense.
> +{
> + if (HPAGE_SHIFT > PAGE_SHIFT)
> + return HUGETLB_PAGE_ORDER;
> +
> + return MAX_ORDER-1;
> +}
> +
> /* Initialise the number of pages represented by NR_PAGEBLOCK_BITS */
> static inline void __init set_pageblock_order(unsigned int order)
> {
> @@ -3357,7 +3367,7 @@ static inline void __init set_pageblock_
> }
> #else /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
>
> -/* Defined this way to avoid accidently referencing HUGETLB_PAGE_ORDER */
> +#define pageblock_default_order(x) (0)
that won't compile.
> #define set_pageblock_order(x) do {} while (0)
>
> #endif /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
> @@ -3442,7 +3452,7 @@ static void __meminit free_area_init_cor
> if (!size)
> continue;
>
> - set_pageblock_order(HUGETLB_PAGE_ORDER);
> + set_pageblock_order(pageblock_default_order());
> setup_usemap(pgdat, zone, size);
> ret = init_currently_empty_zone(zone, zone_start_pfn,
--- a/mm/page_alloc.c~fix-boot-problem-with-iseries-lacking-hugepage-support-fix
+++ a/mm/page_alloc.c
@@ -3268,7 +3268,7 @@ static void inline setup_usemap(struct p
#ifdef CONFIG_HUGETLB_PAGE_SIZE_VARIABLE
/* Return a sensible default order for the pageblock size. */
-static inline int __init pageblock_default_order(void)
+static inline int pageblock_default_order(void)
{
if (HPAGE_SHIFT > PAGE_SHIFT)
return HUGETLB_PAGE_ORDER;
@@ -3291,7 +3291,11 @@ static inline void __init set_pageblock_
}
#else /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
-#define pageblock_default_order(x) (0)
+static inline int pageblock_default_order(void)
+{
+ return 0;
+}
+
#define set_pageblock_order(x) do {} while (0)
#endif /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
_
please avoid adding macros when C could have been used. C is nicer to look
at and has typechecking and stuff.
^ permalink raw reply
* Re: Do not depend on MAX_ORDER when grouping pages by mobility
From: Mel Gorman @ 2007-11-15 10:13 UTC (permalink / raw)
To: Stephen Rothwell; +Cc: ppc-dev
In-Reply-To: <20071115141740.d22acb0e.sfr@canb.auug.org.au>
On (15/11/07 14:17), Stephen Rothwell didst pronounce:
> Hi Mel,
>
> On Wed, 14 Nov 2007 18:10:45 +0000 mel@skynet.ie (Mel Gorman) wrote:
> >
> > libhugetlbfs test suite and boot test on iSeries is sufficient in this
> > case. However, the version I sent would break on IA-64 due to the lack of
> > a definition for HPAGE_SHIFT when CONFIG_HUGETLB_PAGE is not set. Can you
> > confirm this patch still fixes the problem please? If it does, I'll send
> > it to Andrew as a fix for 2.6.24. Whether iSeries is legacy or not, this is
> > breakage and should be fixed.
>
> The new patch works fine. I reran the libhugetlbfs tests on a Power5+
> machine and the ppc64_defconfig boots on legacy iSeries.
>
Thanks a million for reporting and testing. I've pushed the patch to Andrew.
--
Mel Gorman
Part-time Phd Student Linux Technology Center
University of Limerick IBM Dublin Software Lab
^ permalink raw reply
* [PATCH] Fix boot problem with iSeries lacking hugepage support
From: Mel Gorman @ 2007-11-15 10:13 UTC (permalink / raw)
To: akpm; +Cc: linux-mm, linuxppc-dev, linux-kernel, sfr
This patch is a fix for 2.6.24.
Ordinarily the size of a pageblock is determined at compile-time based on the
hugepage size. On PPC64, the hugepage size is determined at runtime based on
what is supported by the machine. With legacy machines such as iSeries that do
not support hugepages, HPAGE_SHIFT becomes 0. This results in pageblock_order
being set to -PAGE_SHIFT and a crash results shortly afterwards.
This patch sets HUGETLB_PAGE_SIZE_VARIABLE for PPC64 and adds a function
to select a sensible value for pageblock order by default. It checks that
HPAGE_SHIFT is a sensible value before using the hugepage size; if it is
not MAX_ORDER-1 is used.
Credit goes to Stephen Rothwell for identifying the bug and testing candidate
patches. Additional credit goes to Andy Whitcroft for spotting a problem
with respects to IA-64 before releasing. Additional credit to David Gibson
for testing with the libhugetlbfs test suite.
Signed-off-by: Mel Gorman <mel@csn.ul.ie>
Tested-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
arch/powerpc/Kconfig | 5 +++++
mm/page_alloc.c | 14 ++++++++++++--
2 files changed, 17 insertions(+), 2 deletions(-)
diff -rup -X /usr/src/patchset-0.6/bin//dontdiff linux-2.6.24-rc2-mm1-clean/arch/powerpc/Kconfig linux-2.6.24-rc2-005_iSeries_fix/arch/powerpc/Kconfig
--- linux-2.6.24-rc2-mm1-clean/arch/powerpc/Kconfig 2007-11-14 11:38:05.000000000 +0000
+++ linux-2.6.24-rc2-005_iSeries_fix/arch/powerpc/Kconfig 2007-11-14 11:39:12.000000000 +0000
@@ -187,6 +187,11 @@ config FORCE_MAX_ZONEORDER
default "9" if PPC_64K_PAGES
default "13"
+config HUGETLB_PAGE_SIZE_VARIABLE
+ bool
+ depends on HUGETLB_PAGE
+ default y
+
config MATH_EMULATION
bool "Math emulation"
depends on 4xx || 8xx || E200 || PPC_MPC832x || E500
diff -rup -X /usr/src/patchset-0.6/bin//dontdiff linux-2.6.24-rc2-mm1-clean/mm/page_alloc.c linux-2.6.24-rc2-005_iSeries_fix/mm/page_alloc.c
--- linux-2.6.24-rc2-mm1-clean/mm/page_alloc.c 2007-11-14 11:38:08.000000000 +0000
+++ linux-2.6.24-rc2-005_iSeries_fix/mm/page_alloc.c 2007-11-14 13:45:19.000000000 +0000
@@ -3342,6 +3342,16 @@ static void inline setup_usemap(struct p
#endif /* CONFIG_SPARSEMEM */
#ifdef CONFIG_HUGETLB_PAGE_SIZE_VARIABLE
+
+/* Return a sensible default order for the pageblock size. */
+static inline int __init pageblock_default_order(void)
+{
+ if (HPAGE_SHIFT > PAGE_SHIFT)
+ return HUGETLB_PAGE_ORDER;
+
+ return MAX_ORDER-1;
+}
+
/* Initialise the number of pages represented by NR_PAGEBLOCK_BITS */
static inline void __init set_pageblock_order(unsigned int order)
{
@@ -3357,7 +3367,7 @@ static inline void __init set_pageblock_
}
#else /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
-/* Defined this way to avoid accidently referencing HUGETLB_PAGE_ORDER */
+#define pageblock_default_order(x) (0)
#define set_pageblock_order(x) do {} while (0)
#endif /* CONFIG_HUGETLB_PAGE_SIZE_VARIABLE */
@@ -3442,7 +3452,7 @@ static void __meminit free_area_init_cor
if (!size)
continue;
- set_pageblock_order(HUGETLB_PAGE_ORDER);
+ set_pageblock_order(pageblock_default_order());
setup_usemap(pgdat, zone, size);
ret = init_currently_empty_zone(zone, zone_start_pfn,
size, MEMMAP_EARLY);
--
--
Mel Gorman
Part-time Phd Student Linux Technology Center
University of Limerick IBM Dublin Software Lab
^ permalink raw reply
* Problem with uboot on lite5200
From: Leo Hendrawan @ 2007-11-15 9:14 UTC (permalink / raw)
To: linuxppc-embedded
[-- Attachment #1: Type: text/plain, Size: 415 bytes --]
Hi all,
i am newbee in Linux PPC. i have problem with my lite5200 board. previously
it has been installed with uboot. but now i dont receive any message from
uboot in the serial line (serial line is ok with 115200 bps - tested).
how can i re-flash the uboot inside the MPC5200? i use bdi2000, compiled the
new uboot version 1.1.6 but didnt find out anyway to flash it inside the
controller.
thanks for the hint,
[-- Attachment #2: Type: text/html, Size: 438 bytes --]
^ permalink raw reply
* Re: Kernel locks up after calling kernel_execve()
From: Gerhard Pircher @ 2007-11-15 8:48 UTC (permalink / raw)
To: Paul Mackerras; +Cc: linuxppc-dev
In-Reply-To: <18235.28312.88899.861687@cargo.ozlabs.ibm.com>
-------- Original-Nachricht --------
> Datum: Thu, 15 Nov 2007 08:54:32 +1100
> Von: Paul Mackerras <paulus@samba.org>
> An: "Gerhard Pircher" <gerhard_pircher@gmx.net>
> CC: benh@kernel.crashing.org, linuxppc-dev@ozlabs.org
> Betreff: Re: Kernel locks up after calling kernel_execve()
> No it's not just for ppc64. We had a patch that went in some time ago
> to ensure that the M bit was set on various 32-bit platforms because
> otherwise we got data corruption (due to a small cache in the
> northbridge not being kept coherent with the processor cache).
Ah, I thought this was due to a CPU errata, where L2 cache prefetching
causes data corruption with the coherent bit set to 0.
Gerhard
--
Psssst! Schon vom neuen GMX MultiMessenger gehört?
Der kann`s mit allen: http://www.gmx.net/de/go/multimessenger
^ permalink raw reply
* Re: about uImage-DENX-v2.6.14 config
From: Stefan Roese @ 2007-11-15 6:13 UTC (permalink / raw)
To: linuxppc-dev; +Cc: info, zhangwei zhang, linuxppc-embedded
In-Reply-To: <4b7912400711140706i3c96456bua42dc01c6cb5467b@mail.gmail.com>
On Wednesday 14 November 2007, zhangwei zhang wrote:
> Hello, I have a problem when using linux-2.6.14(download from
> ftp.denx.de) for RTAI on ppc440EP.
RTAI on PPC? I thought RTAI was dead for anything other than X86.
And 2.6.14 is quite old. I suggest you use a newer binary version or compile a
the image from the current kernel source.
> I use the ELDK4.1 and when boot the
> uImage I compiled , I always have the problem as following:
>
> ## Booting image at 00500000 ...
> Image Name: Linux-2.6.14
> Image Type: PowerPC Linux Kernel Image (gzip compressed)
> Data Size: 1155686 Bytes = 1.1 MB
> Load Address: 00000000
> Entry Point: 00000000
> Verifying Checksum ... OK
> Uncompressing Kernel Image ... OK
>
> then it stopped . I am afraid that maybe the problem comes from the
> config. I have ever use the uImage-DENX-v2.6.14 you offered in
> ftp.denx.de/pub/linux/amcc/image/yosemite/ and it works. So can you
> send me a config file for 2.6.14 to me? Thank you.
Please don't stick with 2.6.14. Download the current kernel:
http://www.denx.de/cgi-bin/gitweb.cgi?p=linux-2.6-denx.git;a=summary
and there you will find the .config for the Yosemite
(arch/ppc/configs/yosemite_defconfig).
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office@denx.de
=====================================================================
^ permalink raw reply
* Re: Do not depend on MAX_ORDER when grouping pages by mobility
From: Stephen Rothwell @ 2007-11-15 3:17 UTC (permalink / raw)
To: Mel Gorman; +Cc: ppc-dev
In-Reply-To: <20071114181044.GB773@skynet.ie>
[-- Attachment #1: Type: text/plain, Size: 858 bytes --]
Hi Mel,
On Wed, 14 Nov 2007 18:10:45 +0000 mel@skynet.ie (Mel Gorman) wrote:
>
> libhugetlbfs test suite and boot test on iSeries is sufficient in this
> case. However, the version I sent would break on IA-64 due to the lack of
> a definition for HPAGE_SHIFT when CONFIG_HUGETLB_PAGE is not set. Can you
> confirm this patch still fixes the problem please? If it does, I'll send
> it to Andrew as a fix for 2.6.24. Whether iSeries is legacy or not, this is
> breakage and should be fixed.
The new patch works fine. I reran the libhugetlbfs tests on a Power5+
machine and the ppc64_defconfig boots on legacy iSeries.
So
Tested-by: Stephen Rothwell <sfr@canb.auug.org.au> iSeries boot test and
hugetlb tests on PPC64
Thanks.
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply
* Re: Hardware debuggers for PPC74xx G4 CPUs
From: Jon Smirl @ 2007-11-15 2:34 UTC (permalink / raw)
To: Jerry Van Baren; +Cc: Olof Johansson, linuxppc-dev
In-Reply-To: <473BA278.2000402@gmail.com>
On 11/14/07, Jerry Van Baren <gvb.linuxppc.dev@gmail.com> wrote:
> Jon Smirl wrote:
> > On 11/13/07, Benjamin Herrenschmidt <benh@kernel.crashing.org> wrote:
> >>> That's why Dominic wants to get OpenOCD running on the PowerPC. All we
> >>> need is the programming documentation for controlling the CPU via the
> >>> debug hardware.
> >> Note that this is basically different for every CPU around.
> >
> > I'd like to get it for the MPC5200 because of the project I am working
> > on, an open source audio device. It would be nice if there was a cheap
> > hardware debugger available for hackers to use on it. Maybe one of the
> > Freescale developers will see this and send me the right docs.
> >
> > Is it radically different? Dominic has been able to support every ARM
> > 7/9 chip he can get his hands on without too much trouble once the
> > core support was written. I don't think he has ARM 11 working yet.
> >
> >>> Obviously this documentation exist, all of the commercial vendors had
> >>> to have it to develop their debuggers. Maybe it is already out there
> >>> and we just don't know where to look.
> >> Ben.
>
> DISCLAIMER: Extrapolating grossly from almost no knowledge!
>
> My understanding is that the Freescale PPC debugger interface is based
> on the JTAG interface using a proprietary command set. Basically, if
> you do their magic BDM (JTAG extension) command, you get into an
> internal scan chain that allows you to read/write the processor
> internals (registers).
>
> The problems are many...
> * The documentation is only available under NDA, a problem for open
> source debuggers.
This is what we need. I would like it specifically for the mpc5200.
But we want to use it in OpenOCD so NDA won't work.
> * The scan chain is different on every processor, and may be different
> on different revisions of the same processor.
Hopefully the doc will cover this.
> * If you mess up with JTAG, you will probably burn up the CPU. Very
> literally. I've seen it done. Twice. (Thankfully not my screwup, and
> it wasn't a PPC so it deserved to die. ;-) The internal scan chain is
> probably safer, but YMMV.
Dominic is way experienced implementing JTAG for ARM CPUs. He has done
several dozen interfaces. ARM doesn't have any problems releasing
their debugging info.
I've also lined up a mpc5200 development board vendor who wants a
cheap mpc5200 JTAG too and is willing to supply him with target
hardware.
JTAG hardware would be something similar to this:
http://www.amontec.com/jtagkey-tiny.shtml
So $30-40 for hardware with free OpenOCD software and you have JTAG
for the mpc5200.
This puts it in the range of classroom use.
The few embedded classes I've been around lately are being taught on
ARM hardware because it is so cheap. Development boards and the JTAG
can be had for under $100.
For example check out this store, it carries hundreds of ARM products
and almost no PowerPC ones.
http://microcontrollershop.com
--
Jon Smirl
jonsmirl@gmail.com
^ permalink raw reply
* RE: printk/console_init - baud rate setting
From: Siva Prasad @ 2007-11-15 2:17 UTC (permalink / raw)
To: Segher Boessenkool; +Cc: linuxppc-dev, linuxppc-embedded
In-Reply-To: <610b1b49ca582c7a2277e8d6dea2be31@kernel.crashing.org>
Thanks Segher.
It was because of the BASE_BAUD value. We are working at 600MHz, not
18.432. After that change, it worked fine.
Thanks
Siva
-----Original Message-----
From: Segher Boessenkool [mailto:segher@kernel.crashing.org]=20
Sent: Wednesday, November 14, 2007 3:00 PM
To: Siva Prasad
Subject: Re: printk/console_init - baud rate setting
> Thanks for your response Segher.
> I already have the command line "console=3DttyS0, 115200". Now, how to
> make sure that 115200 setting is calculated properly for the use by
> driver.
>
> In other words, can you kind enough to please let me know how 115200
is
> supported by the driver, based on the clock frequency.
That is solely the driver's own responsibility, you'll have to look
at the source code. 8250 typically just assumes 18.432MHz.
Segher
^ permalink raw reply
* Re: Hardware debuggers for PPC74xx G4 CPUs
From: Jerry Van Baren @ 2007-11-15 1:35 UTC (permalink / raw)
To: Jon Smirl; +Cc: Olof Johansson, linuxppc-dev
In-Reply-To: <9e4733910711131732i5ec5d226r4037e42399c38f59@mail.gmail.com>
Jon Smirl wrote:
> On 11/13/07, Benjamin Herrenschmidt <benh@kernel.crashing.org> wrote:
>>> That's why Dominic wants to get OpenOCD running on the PowerPC. All we
>>> need is the programming documentation for controlling the CPU via the
>>> debug hardware.
>> Note that this is basically different for every CPU around.
>
> I'd like to get it for the MPC5200 because of the project I am working
> on, an open source audio device. It would be nice if there was a cheap
> hardware debugger available for hackers to use on it. Maybe one of the
> Freescale developers will see this and send me the right docs.
>
> Is it radically different? Dominic has been able to support every ARM
> 7/9 chip he can get his hands on without too much trouble once the
> core support was written. I don't think he has ARM 11 working yet.
>
>>> Obviously this documentation exist, all of the commercial vendors had
>>> to have it to develop their debuggers. Maybe it is already out there
>>> and we just don't know where to look.
>> Ben.
DISCLAIMER: Extrapolating grossly from almost no knowledge!
My understanding is that the Freescale PPC debugger interface is based
on the JTAG interface using a proprietary command set. Basically, if
you do their magic BDM (JTAG extension) command, you get into an
internal scan chain that allows you to read/write the processor
internals (registers).
The problems are many...
* The documentation is only available under NDA, a problem for open
source debuggers.
* The scan chain is different on every processor, and may be different
on different revisions of the same processor.
* If you mess up with JTAG, you will probably burn up the CPU. Very
literally. I've seen it done. Twice. (Thankfully not my screwup, and
it wasn't a PPC so it deserved to die. ;-) The internal scan chain is
probably safer, but YMMV.
gvb
^ permalink raw reply
* Re: [PATCH] powerpc: Fix fs_enet module build
From: David Miller @ 2007-11-14 23:51 UTC (permalink / raw)
To: jochen; +Cc: jeff, netdev, linux-kernel, linuxppc-embedded, akpm
In-Reply-To: <473AE325.8070901@scram.de>
From: Jochen Friedrich <jochen@scram.de>
Date: Wed, 14 Nov 2007 12:59:33 +0100
> I know it's ugly, however, module building is completely
> broken right now and I just want to provide a quick and
> ugly fix until both that ppc->powerpc transition and the
> new binding transition are over. Noone wants to touch the
> old stuff any more as it's a pita and it's already scheduled
> for removal in a couple of months.
Fair enough, I'll apply the patch.
Thanks for the explanation.
^ permalink raw reply
* Re: [PATCH v5 04/13] [POWERPC] Add generic support for simple MPC5200 based boards
From: Stephen Rothwell @ 2007-11-14 23:21 UTC (permalink / raw)
To: Marian Balakowicz; +Cc: linuxppc-dev
In-Reply-To: <20071114102115.31052.67271.stgit@hekate.izotz.org>
[-- Attachment #1: Type: text/plain, Size: 694 bytes --]
Hi Marian,
On Wed, 14 Nov 2007 11:21:37 +0100 Marian Balakowicz <m8@semihalf.com> wrote:
>
> +++ b/arch/powerpc/platforms/52xx/mpc5200_simple.c
> +#include <asm/time.h>
> +#include <asm/machdep.h>
> +#include <asm/mpc52xx.h>
You still need asm/prom.h because you use of_get_flat_dt_root() and
of_flat_dt_is_compatible().
> +/* list of the supported boards */
> +static const char *board[] __initdata = {
Unfortunately you can't use "const" and "__initdata", so just remove the
"const". (const changes the attributes on the section that __initdata is
stored in.)
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply
* Re: 85xx Device tree problems: e0024520:02 not found
From: robert lazarski @ 2007-11-14 22:00 UTC (permalink / raw)
Cc: linuxppc-embedded
In-Reply-To: <473B699C.5040700@anagramm.de>
On Nov 14, 2007 4:33 PM, Clemens Koller <clemens.koller@anagramm.de> wrote:
> Hi, Robert!
>
> Just one more short note...
> My good - vs. - bad dmesg output:
>
> good 2.6.21-rc5-git:
> > Gianfar MII Bus: probed
> > eth0: Gianfar Ethernet Controller Version 1.2, 00:ww:xx:yy:zz:dd
> > eth0: Running with NAPI enabled
> > eth0: 256/256 RX/TX BD ring size
> > eth1: Gianfar Ethernet Controller Version 1.2, 00:ww:xx:yy:zz:dd
> > eth1: Running with NAPI enabled
> > eth1: 256/256 RX/TX BD ring size
> > eth2: Gianfar Ethernet Controller Version 1.2, 00:ww:xx:yy:zz:dd
> > eth2: Running with NAPI enabled
> > eth2: 256/256 RX/TX BD ring size
> > Marvell 88E1101: Registered new driver
> > Marvell 88E1111: Registered new driver
> > Marvell 88E1145: Registered new driver
> (I've wiped out my MAC)
>
> bad 2.6.24-rc2-git:
> < Gianfar MII Bus: probed
> < eth0: Gianfar Ethernet Controller Version 1.2, 00:00:00:00:00:00
> < eth0: Running with NAPI enabled
> < eth0: 256/256 RX/TX BD ring size
> < eth1: Gianfar Ethernet Controller Version 1.2, 00:00:00:00:00:00
> < eth1: Running with NAPI enabled
> < eth1: 256/256 RX/TX BD ring size
> < eth2: Gianfar Ethernet Controller Version 1.2, 00:00:00:00:00:00
> < eth2: Running with NAPI enabled
> < eth2: 256/256 RX/TX BD ring size
>
> The MACs are all 00 here.
> The PHY drivers don't get registered.
> (What happened to CONFIG_NETDEV_1000 in the newer kernels?)
>
> How is your mileage?
> Next round... tomorrow,
>
> regards,
>
> Clemens Koller
Hmm, I'm getting my mac addresses, the same ones I set in u-boot:
=> bootm 1000000 - c00000
## Booting image at 01000000 ...
Image Name: Linux-2.6.24-rc2-ge6a5c27f-dirty
Image Type: PowerPC Linux Kernel Image (gzip compressed)
Data Size: 1278631 Bytes = 1.2 MB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... OK
Uncompressing Kernel Image ... OK
## Current stack ends at 0x3FF9DD50 => set upper limit to 0x00800000
## cmdline at 0x007FFF00 ... 0x007FFF90
bd address = 0x3FF9DFB0
memstart = 0x00000000
memsize = 0x40000000
flashstart = 0xF8000000
flashsize = 0x08000000
flashoffset = 0x00000000
sramstart = 0x00000000
sramsize = 0x00000000
immr_base = 0xE0000000
bootflags = 0xE4013F80
intfreq = 888.888 MHz
busfreq = 355.555 MHz
ethaddr = 00:E0:0C:00:00:FD
eth1addr = 00:E0:0C:00:01:FD
eth2addr = 00:E0:0C:00:02:FD
eth3addr = 00:E0:0C:00:03:FD
IP addr = 10.101.43.142
baudrate = 115200 bps
Skipping initrd
Booting using the fdt at 0xc00000
No initrd
## device tree at 0x00C00000 ... 0x00C01B6C (len=7021=0x1B6D)
Loading Device Tree to 007fc000, end 007fdb6c ... OK
## Transferring control to Linux (at address 00000000) ...
serial8250.0: ttyS1 at MMIO 0xe0004600 (irq = 42) is a 16550A
RAMDISK driver initialized: 16 RAM disks of 32768K size 1024 blocksize
loop: module loaded
Gianfar MII Bus: probed
eth0: Gianfar Ethernet Controller Version 1.2, 00:e0:0c:00:00:fd
eth0: Running with NAPI enabled
eth0: 256/256 RX/TX BD ring size
eth1: Gianfar Ethernet Controller Version 1.2, 00:e0:0c:00:01:fd
eth1: Running with NAPI enabled
eth1: 256/256 RX/TX BD ring size
eth2: Gianfar Ethernet Controller Version 1.2, 00:e0:0c:00:02:fd
eth2: Running with NAPI enabled
eth2: 256/256 RX/TX BD ring size
eth3: Gianfar Ethernet Controller Version 1.2, 00:e0:0c:00:03:fd
eth3: Running with NAPI enabled
eth3: 256/256 RX/TX BD ring size
Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx
TCP cubic registered
Initializing XFRM netlink socket
NET: Registered protocol family 1
NET: Registered protocol family 17
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
e0024520:02 not found
eth2: Could not attach to PHY
IP-Config: Failed to open eth2
IP-Config: Device `eth2' not found.
Tomorrow's a holiday here in Brazil, will catch up with you Friday,
Robert
^ permalink raw reply
* Re: Kernel locks up after calling kernel_execve()
From: Paul Mackerras @ 2007-11-14 21:54 UTC (permalink / raw)
To: Gerhard Pircher; +Cc: linuxppc-dev
In-Reply-To: <20071114093939.297890@gmx.net>
Gerhard Pircher writes:
> Yeah, the northbridge hates the M bit! Thus the AmigaOne platform code
Wow.
> masks out the CPU_FTR_NEED_COHERENT flag and disables the L2 cache
> prefetch engines (I don't care about the performance loss).
> I couldn't find any other code that sets the M bit, except for huge TLB
> page support, but isn't that only for PPC64?
No it's not just for ppc64. We had a patch that went in some time ago
to ensure that the M bit was set on various 32-bit platforms because
otherwise we got data corruption (due to a small cache in the
northbridge not being kept coherent with the processor cache).
Look for CPU_FTR_NEED_COHERENT in include/asm-powerpc/cputable.h and
arch/powerpc/mm/*.
Paul.
^ permalink raw reply
* Re: 85xx Device tree problems: e0024520:02 not found
From: Clemens Koller @ 2007-11-14 21:33 UTC (permalink / raw)
To: robert lazarski; +Cc: linuxppc-embedded
In-Reply-To: <473B5940.2090306@anagramm.de>
Hi, Robert!
Just one more short note...
My good - vs. - bad dmesg output:
good 2.6.21-rc5-git:
> Gianfar MII Bus: probed
> eth0: Gianfar Ethernet Controller Version 1.2, 00:ww:xx:yy:zz:dd
> eth0: Running with NAPI enabled
> eth0: 256/256 RX/TX BD ring size
> eth1: Gianfar Ethernet Controller Version 1.2, 00:ww:xx:yy:zz:dd
> eth1: Running with NAPI enabled
> eth1: 256/256 RX/TX BD ring size
> eth2: Gianfar Ethernet Controller Version 1.2, 00:ww:xx:yy:zz:dd
> eth2: Running with NAPI enabled
> eth2: 256/256 RX/TX BD ring size
> Marvell 88E1101: Registered new driver
> Marvell 88E1111: Registered new driver
> Marvell 88E1145: Registered new driver
(I've wiped out my MAC)
bad 2.6.24-rc2-git:
< Gianfar MII Bus: probed
< eth0: Gianfar Ethernet Controller Version 1.2, 00:00:00:00:00:00
< eth0: Running with NAPI enabled
< eth0: 256/256 RX/TX BD ring size
< eth1: Gianfar Ethernet Controller Version 1.2, 00:00:00:00:00:00
< eth1: Running with NAPI enabled
< eth1: 256/256 RX/TX BD ring size
< eth2: Gianfar Ethernet Controller Version 1.2, 00:00:00:00:00:00
< eth2: Running with NAPI enabled
< eth2: 256/256 RX/TX BD ring size
The MACs are all 00 here.
The PHY drivers don't get registered.
(What happened to CONFIG_NETDEV_1000 in the newer kernels?)
How is your mileage?
Next round... tomorrow,
regards,
Clemens Koller
__________________________________
R&D Imaging Devices
Anagramm GmbH
Rupert-Mayer-Straße 45/1
Linhof Werksgelände
D-81379 München
Tel.089-741518-50
Fax 089-741518-19
http://www.anagramm-technology.com
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox