linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* ELDK and suse 9.0
@ 2003-12-16  8:38 Kate Alhola
  2003-12-16  8:50 ` Steven Scholz
  2003-12-16 10:12 ` ELDK and suse 9.0 Wolfgang Denk
  0 siblings, 2 replies; 8+ messages in thread
From: Kate Alhola @ 2003-12-16  8:38 UTC (permalink / raw)
  To: linuxppc-embedded


I have user eldk a lot with Redhat 9 but after they discontinued it, i
decided to change to
suse 9 but looks a like that least standard eldk 2.1.0 install does not
work with suse9

May be i just need to build the rpm packages included in eldk with suse
from
sources but i have yet not have time to look out how they differ from
standard rpm
that comes with suse. Least symlinking eldk:s own rpm eith system rpm
does not work.
It gives just too many error messages about conflicts and dependensies.

I have tried tp get ELDK installed to suse 9.0 but it looks a like that
rpm program cpming with it
gives segmentetion fault when it uses build in rpm command. I have tried
it with two
diferent Suse 9.0 systems with exactly same results.


There is some debug traces:

install runs and does not give any error messages bus just ends. Running
it with strace
indicates that /opt/eldk/bin/rpm gives segmentation fault and running it by
strace indicates that that command fails with following log:


Kate

----- Debug traces comes here ------------
[root@katerinaii eldk-ppc-linux-x86]# cat debugout
trinity:/katerinaii/kate/denx/eldk-ppc-linux-x86 # ./install -v -d
/opt/eldk ppc_82xx


Do you really want to install into /opt/eldk directory[y/n]?: y

Installing cross RPMs

/opt/eldk/bin/rpm -ihv --nodeps  ./RPMS/rpm-4.0.3-1.03b_2.i386.rpm
Preparing...                ###########################################
[100%]
trinity:/katerinaii/kate/denx/eldk-ppc-linux-x86 # strace
/opt/eldk/bin/rpm -ihv --nodeps  ./RPMS/rpm-4.0.3-1.03b_2.i386.rpm

----- lots of lines deleted -----

open("/lib/libc.so.6", O_RDONLY)        = 7
read(7, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\0^\1\000"...,
1024) = 1024
fstat64(7, {st_mode=S_IFREG|0755, st_size=1470060, ...}) = 0
old_mmap(NULL, 1269380, PROT_READ|PROT_EXEC, MAP_PRIVATE, 7, 0) = 0x40244000
mprotect(0x40373000, 28292, PROT_NONE)  = 0
old_mmap(0x40373000, 20480, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED,
7, 0x12e000) = 0x40373000
old_mmap(0x40378000, 7812, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x40378000
close(7)                                = 0
open("/lib/ld-linux.so.2", O_RDONLY)    = 7
read(7, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0`\n\0\000"...,
1024) = 1024
fstat64(7, {st_mode=S_IFREG|0755, st_size=101556, ...}) = 0
old_mmap(NULL, 88440, PROT_READ|PROT_EXEC, MAP_PRIVATE, 7, 0) = 0x4037a000
mprotect(0x4038f000, 2424, PROT_NONE)   = 0
old_mmap(0x4038f000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED,
7, 0x15000) = 0x4038f000
close(7)                                = 0
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV +++
[root@katerinaii eldk-ppc-linux-x86]#


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

^ permalink raw reply	[flat|nested] 8+ messages in thread
* RE: reboot by software
@ 2003-12-16 13:16 VanBaren, Gerald (AGRE)
  0 siblings, 0 replies; 8+ messages in thread
From: VanBaren, Gerald (AGRE) @ 2003-12-16 13:16 UTC (permalink / raw)
  To: linuxppc-embedded


The problem with jumping to 0xFFF00100 is that the hardware (processor internal as well as external bits) is not reset and it messes up the start up sequence.  The easiest solution is to force a checkstop reset (via a machine check), which performs a hardware reset and gets the 8260 (and your external hardware if your hardware supports the reset properly) back into the reset state.

The easiest way to do this is to unmap the memory that is being used to execute code (including the vector area) and then force a machine check

For an example, see U-Boot reset: it may need to be adapted to your purposes, but is a very nice example.  U-Boot can be found on sourceforge.net.  It is maintained and supported by Wolfgang Denk and his merry band (the snippet below is from .../cpu/mpc8260/cpu.c and is copyright Wolfgang Denk with a GPL license).  For more information, see sourceforge and www.denx.de

gvb


int
do_reset(cmd_tbl_t *cmdtp, bd_t *bd, int flag, int argc, char *argv[])
{
	ulong msr, addr;

	volatile immap_t *immap = (immap_t *)CFG_IMMR;

	immap->im_clkrst.car_rmr = RMR_CSRE; /* Checkstop Reset enable */

	/* Interrupts and MMU off */
	__asm__ __volatile__ ("mfmsr    %0" : "=r"(msr) : );
	msr &= ~(MSR_ME|MSR_EE|MSR_IR|MSR_DR);
	__asm__ __volatile__ ("mtmsr    %0" : : "r"(msr) );

	/*
	 * Trying to execute the next instruction at a non-existing address
	 * should cause a machine check, resulting in reset
	 */
#ifdef CFG_RESET_ADDRESS
	addr = CFG_RESET_ADDRESS;
#else
	/*
	 * note: when CFG_MONITOR_BASE points to a RAM address, CFG_MONITOR_BASE
	 * - sizeof (ulong) is usually a valid address. Better pick an address
	 * known to be invalid on your system and assign it to CFG_RESET_ADDRESS.
	 */
	addr = CFG_MONITOR_BASE - sizeof (ulong);
#endif
	((void (*)(void ))addr)();
	return 1;

}


> -----Original Message-----
> From: owner-linuxppc-embedded@lists.linuxppc.org
> [mailto:owner-linuxppc-embedded@lists.linuxppc.org]On Behalf Of John
> Zhou
> Sent: Tuesday, December 16, 2003 4:39 AM
> To: linuxppc-embedded@lists.linuxppc.org
> Subject: reboot by software
>
>
>
> Hello!
>
> I have a linux running on my mpc8260 board( power on reset at
> 0xfff00100, I use 32 bit flash, and directly maping
> 0xF0000000 ~ 0xFFFFFFF in kernel).
>
> Now, I want to reboot system by software. But, when I jump to
> 0xfff00100 in kernel mode, it's going dead. Can anybody help me?
>
> Thanks.
>
> John
>
>
>


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

^ permalink raw reply	[flat|nested] 8+ messages in thread
* RE: reboot by software
@ 2003-12-16 14:40 Wells, Charles
  0 siblings, 0 replies; 8+ messages in thread
From: Wells, Charles @ 2003-12-16 14:40 UTC (permalink / raw)
  To: linuxppc-embedded; +Cc: 'zjzhou@newrocktech.com'


> Now, I want to reboot system by software. But, when I jump to 0xfff00100
in kernel mode, it's going > dead. Can anybody help me?

If you have the Software Watchdog Timer enabled, just do a lock-interrupts
followed by a branch-self.

Charlie


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2003-12-16 14:40 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-12-16  8:38 ELDK and suse 9.0 Kate Alhola
2003-12-16  8:50 ` Steven Scholz
2003-12-16  9:38   ` reboot by software John Zhou
2003-12-16 10:24     ` Wolfgang Denk
2003-12-16 13:10     ` Gary Thomas
2003-12-16 10:12 ` ELDK and suse 9.0 Wolfgang Denk
  -- strict thread matches above, loose matches on Subject: below --
2003-12-16 13:16 reboot by software VanBaren, Gerald (AGRE)
2003-12-16 14:40 Wells, Charles

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).