All of lore.kernel.org
 help / color / mirror / Atom feed
* RE: getting Linux working on IBM Walnut demo board
@ 2003-05-28 20:59 Kerl, John
  0 siblings, 0 replies; 13+ messages in thread
From: Kerl, John @ 2003-05-28 20:59 UTC (permalink / raw)
  To: 'Brian S. Park', linuxppc-embedded


Brian:

Re flash capacity, there was a thread on this some months ago.
There are those who pride themselves on having the most compact
system possible, and who will tell you 2MB is "bloated".  There
are those who prefer to use a standard C library, and who think
5 MB is OK.  So it depends on how much you want to crunch things
down ...

However, I will say that an 8MB flash device should be plenty
for compressed kernel, compressed RAM disk which contains a nice
set of libraries + applications, firmware, etc.  And you might
be able to get by with 4MB.

We use a pair of StrataFlash parts on most all of our boards
-- these are 8MB, 16 bits wide; we usually use a pair of them
(for a 32-bit bus) which gives us 16MB of flash.  And that is
more than plenty.  All my firmware (several different tools)
fit comfortably in the last 1 MB.  I generally put some extras
in my RAM disk, e.g. some largish PDF files (product briefs)
so that a board can run a web server, dishing up some marketing
literature, etc, and I am not one of the people who wants the
tiniest C library, so I am one of the more profligate users.
And my zvmlinux.initrd is generally in the 3-5MB range.  That
leaves space in our 16MB flash for 2-3 of those zvmlinux.initrd's.

-----Original Message-----
From: Brian S. Park [mailto:brian@corelis.com]
Sent: Wednesday, May 28, 2003 1:53 PM
Subject: Re: getting Linux working on IBM Walnut demo board

Thank you all for good suggestions.

It turned out that ELDK default setup does not have any dev files. How do I
create all the dev files I need?

 >[root@karla2 dev]# ls
 >initctl  log  null

Also, I have a general question about Embedded Linux. What is the
reasonable amount of flash to have for a minimally configured Embedded
Linux system?

My target will be running small (<<1MB) program which will take
commands over TCP/IP network. So, I want to know how much flash
memory we should put on our custom target. We do not need support for
PCI/Video/Sound/HD/SCSI/Parallel port/... All we need from the OS is
network support. Probably using Linux is an overkill but since it's
free. :)

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

^ permalink raw reply	[flat|nested] 13+ messages in thread
* RE: getting Linux working on IBM Walnut demo board
@ 2003-05-28 19:03 Kerl, John
  0 siblings, 0 replies; 13+ messages in thread
From: Kerl, John @ 2003-05-28 19:03 UTC (permalink / raw)
  To: Kerl, John, 'Brian S. Park'
  Cc: 'linuxppc-embedded@lists.linuxppc.org'


Also, 'set tagstack' in your ~/.vimrc.

-----Original Message-----
From: Kerl, John
Sent: Wednesday, May 28, 2003 12:02 PM
To: Kerl, John; 'Brian S. Park'
Cc: 'linuxppc-embedded@lists.linuxppc.org'
Subject: RE: getting Linux working on IBM Walnut demo board


Ooooops, not reading your message well enough.
Of course you're using NFS, not RAM disk.

You can do a couple things:

*	cd into your export directory and make sure
	stuff is really there -- this is the Linux
	host looking at itself.

*	A nice diagnostic is to use another Linux PC,
	mounting the first Linux host's export directory
	over NFS.  I.e. the second PC is the NFS client,
	rather than the board.

*	You can resort to printk's ... you might do the
	following to assist in this:
	-	cd to kernel directory
	-	make tags
	-	Set up your editor for tags, e.g. in vim,
		.vimrc has a 'set tags=./tags' line in it.
	-	vim init/main.c, find the function you want,
		then control-] to dive in, control-t to
		come back out.

-----Original Message-----
From: Kerl, John [mailto:John.Kerl@avnet.com]
Sent: Wednesday, May 28, 2003 11:57 AM
To: 'Brian S. Park'
Cc: 'linuxppc-embedded@lists.linuxppc.org'
Subject: RE: getting Linux working on IBM Walnut demo board



Brian:

You can get the "all network ports in use" error when
there do not exist /dev/ttyp* -- these are the pseudo-ttys
needed by telnet.  You can mknod them; but I would double-check
your /dev directory.  If you're using ELDK, /dev/ttyp* should
already be there.

The "Unable to open an initial console" message is in init/main.c,
and occurs when /dev/console can't be opened.  Again, this points
suspicion at your filesystem.

To peek at your RAM disk, you can do the following (as root):

# gunzip < ramdisk.image.gz > ramdisk.image
# mkdir foo
# mount -o loop ramdisk.image foo

and then cd into foo and ls, etc.  Don't forget
to then do:

# umount foo
# rmdir foo
# rm ramdisk.image



-----Original Message-----
From: Brian S. Park [mailto:brian@corelis.com]
Sent: Wednesday, May 28, 2003 11:53 AM
To: Eran Mann
Cc: linuxppc-embedded@lists.linuxppc.org
Subject: Re: getting Linux working on IBM Walnut demo board



Eran,
Thank you very much. Now the kernel comes up and I can ping the target. :)

Now to the next problem. I'm booting with NFS root file system. Below is
the bootargs that I'm using.

 >bootargs=root=/dev/nfs rw nfsroot=192.168.1.78:/home/ELDK/ppc_4xx
console=ttyS0,115200
 >              console=tty0
ip=192.168.1.146:192.168.1.78:192.168.1.2:255.255.255.0:netusb::off

exports file on my development station has
 >/home/ELDK/ppc_4xx      netusb(rw,no_root_squash)

/home/ELDK/ppc_4xx is where ELDK installed the target file system on my
development machine.
Even though I can now ping the target, I can't telnet to it. I get the
following error.

 >telnet netusb
 >Trying 192.168.1.146...
 >Connected to netusb.
 >Escape character is '^]'.
 >telnetd: All network ports in use.
 >Connection closed by foreign host.

Is this normal? Do I now need to configure the target file system to enable
telnet?
Or is there still something wrong with my bootargs?

Also, after the kernel comes up, I can no longer type any command through
the serial terminal.
The following the message at the end of kernel boot. It says it was unable
to open the console.

 >IP-Config: Complete:
 >      device=eth0, addr=192.168.1.146, mask=255.255.255.0, gw=192.168.1.2,
 >     host=192.168.1.146, domain=, nis-domain=(none),
 >     bootserver=192.168.1.78, rootserver=192.168.1.78, rootpath=
 >NET4: Unix domain sockets 1.0/SMP for Linux NET4.0.
 >Looking up port of RPC 100003/2 on 192.168.1.78
 >Looking up port of RPC 100005/1 on 192.168.1.78
 >VFS: Mounted root (nfs filesystem).
 >Freeing unused kernel memory: 76k init
 >Warning: unable to open an initial console.

Any help will be appreciated.

Thank you

Brian

At 12:53 PM 5/28/2003 +0300, you wrote:
>Hello Brian,
>You can try what I suggested in:
>http://lists.linuxppc.org/linuxppc-embedded/200305/msg00222.html
>i.e. in the file arch/ppc/platforms/walnut.h to replace
>typedef struct board_info {
>...
>} bd_t;
>
>with:
>#include <asm/ppcboot.h>
>Hope that helps,
>         Eran.


===============================================================
Brian S. Park  brian@corelis.com  (562) 926-6727 x143
---------------------------------------------------------------
Everything we do helps our customers get to market
FASTER with HIGHER quality and LOWER cost
===============================================================


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

^ permalink raw reply	[flat|nested] 13+ messages in thread
* RE: getting Linux working on IBM Walnut demo board
@ 2003-05-28 19:02 Kerl, John
  0 siblings, 0 replies; 13+ messages in thread
From: Kerl, John @ 2003-05-28 19:02 UTC (permalink / raw)
  To: Kerl, John, 'Brian S. Park'
  Cc: 'linuxppc-embedded@lists.linuxppc.org'


Ooooops, not reading your message well enough.
Of course you're using NFS, not RAM disk.

You can do a couple things:

*	cd into your export directory and make sure
	stuff is really there -- this is the Linux
	host looking at itself.

*	A nice diagnostic is to use another Linux PC,
	mounting the first Linux host's export directory
	over NFS.  I.e. the second PC is the NFS client,
	rather than the board.

*	You can resort to printk's ... you might do the
	following to assist in this:
	-	cd to kernel directory
	-	make tags
	-	Set up your editor for tags, e.g. in vim,
		.vimrc has a 'set tags=./tags' line in it.
	-	vim init/main.c, find the function you want,
		then control-] to dive in, control-t to
		come back out.

-----Original Message-----
From: Kerl, John [mailto:John.Kerl@avnet.com]
Sent: Wednesday, May 28, 2003 11:57 AM
To: 'Brian S. Park'
Cc: 'linuxppc-embedded@lists.linuxppc.org'
Subject: RE: getting Linux working on IBM Walnut demo board



Brian:

You can get the "all network ports in use" error when
there do not exist /dev/ttyp* -- these are the pseudo-ttys
needed by telnet.  You can mknod them; but I would double-check
your /dev directory.  If you're using ELDK, /dev/ttyp* should
already be there.

The "Unable to open an initial console" message is in init/main.c,
and occurs when /dev/console can't be opened.  Again, this points
suspicion at your filesystem.

To peek at your RAM disk, you can do the following (as root):

# gunzip < ramdisk.image.gz > ramdisk.image
# mkdir foo
# mount -o loop ramdisk.image foo

and then cd into foo and ls, etc.  Don't forget
to then do:

# umount foo
# rmdir foo
# rm ramdisk.image



-----Original Message-----
From: Brian S. Park [mailto:brian@corelis.com]
Sent: Wednesday, May 28, 2003 11:53 AM
To: Eran Mann
Cc: linuxppc-embedded@lists.linuxppc.org
Subject: Re: getting Linux working on IBM Walnut demo board



Eran,
Thank you very much. Now the kernel comes up and I can ping the target. :)

Now to the next problem. I'm booting with NFS root file system. Below is
the bootargs that I'm using.

 >bootargs=root=/dev/nfs rw nfsroot=192.168.1.78:/home/ELDK/ppc_4xx
console=ttyS0,115200
 >              console=tty0
ip=192.168.1.146:192.168.1.78:192.168.1.2:255.255.255.0:netusb::off

exports file on my development station has
 >/home/ELDK/ppc_4xx      netusb(rw,no_root_squash)

/home/ELDK/ppc_4xx is where ELDK installed the target file system on my
development machine.
Even though I can now ping the target, I can't telnet to it. I get the
following error.

 >telnet netusb
 >Trying 192.168.1.146...
 >Connected to netusb.
 >Escape character is '^]'.
 >telnetd: All network ports in use.
 >Connection closed by foreign host.

Is this normal? Do I now need to configure the target file system to enable
telnet?
Or is there still something wrong with my bootargs?

Also, after the kernel comes up, I can no longer type any command through
the serial terminal.
The following the message at the end of kernel boot. It says it was unable
to open the console.

 >IP-Config: Complete:
 >      device=eth0, addr=192.168.1.146, mask=255.255.255.0, gw=192.168.1.2,
 >     host=192.168.1.146, domain=, nis-domain=(none),
 >     bootserver=192.168.1.78, rootserver=192.168.1.78, rootpath=
 >NET4: Unix domain sockets 1.0/SMP for Linux NET4.0.
 >Looking up port of RPC 100003/2 on 192.168.1.78
 >Looking up port of RPC 100005/1 on 192.168.1.78
 >VFS: Mounted root (nfs filesystem).
 >Freeing unused kernel memory: 76k init
 >Warning: unable to open an initial console.

Any help will be appreciated.

Thank you

Brian

At 12:53 PM 5/28/2003 +0300, you wrote:
>Hello Brian,
>You can try what I suggested in:
>http://lists.linuxppc.org/linuxppc-embedded/200305/msg00222.html
>i.e. in the file arch/ppc/platforms/walnut.h to replace
>typedef struct board_info {
>...
>} bd_t;
>
>with:
>#include <asm/ppcboot.h>
>Hope that helps,
>         Eran.


===============================================================
Brian S. Park  brian@corelis.com  (562) 926-6727 x143
---------------------------------------------------------------
Everything we do helps our customers get to market
FASTER with HIGHER quality and LOWER cost
===============================================================


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

^ permalink raw reply	[flat|nested] 13+ messages in thread
* RE: getting Linux working on IBM Walnut demo board
@ 2003-05-28 18:56 Kerl, John
  0 siblings, 0 replies; 13+ messages in thread
From: Kerl, John @ 2003-05-28 18:56 UTC (permalink / raw)
  To: 'Brian S. Park'; +Cc: 'linuxppc-embedded@lists.linuxppc.org'


Brian:

You can get the "all network ports in use" error when
there do not exist /dev/ttyp* -- these are the pseudo-ttys
needed by telnet.  You can mknod them; but I would double-check
your /dev directory.  If you're using ELDK, /dev/ttyp* should
already be there.

The "Unable to open an initial console" message is in init/main.c,
and occurs when /dev/console can't be opened.  Again, this points
suspicion at your filesystem.

To peek at your RAM disk, you can do the following (as root):

# gunzip < ramdisk.image.gz > ramdisk.image
# mkdir foo
# mount -o loop ramdisk.image foo

and then cd into foo and ls, etc.  Don't forget
to then do:

# umount foo
# rmdir foo
# rm ramdisk.image



-----Original Message-----
From: Brian S. Park [mailto:brian@corelis.com]
Sent: Wednesday, May 28, 2003 11:53 AM
To: Eran Mann
Cc: linuxppc-embedded@lists.linuxppc.org
Subject: Re: getting Linux working on IBM Walnut demo board



Eran,
Thank you very much. Now the kernel comes up and I can ping the target. :)

Now to the next problem. I'm booting with NFS root file system. Below is
the bootargs that I'm using.

 >bootargs=root=/dev/nfs rw nfsroot=192.168.1.78:/home/ELDK/ppc_4xx
console=ttyS0,115200
 >              console=tty0
ip=192.168.1.146:192.168.1.78:192.168.1.2:255.255.255.0:netusb::off

exports file on my development station has
 >/home/ELDK/ppc_4xx      netusb(rw,no_root_squash)

/home/ELDK/ppc_4xx is where ELDK installed the target file system on my
development machine.
Even though I can now ping the target, I can't telnet to it. I get the
following error.

 >telnet netusb
 >Trying 192.168.1.146...
 >Connected to netusb.
 >Escape character is '^]'.
 >telnetd: All network ports in use.
 >Connection closed by foreign host.

Is this normal? Do I now need to configure the target file system to enable
telnet?
Or is there still something wrong with my bootargs?

Also, after the kernel comes up, I can no longer type any command through
the serial terminal.
The following the message at the end of kernel boot. It says it was unable
to open the console.

 >IP-Config: Complete:
 >      device=eth0, addr=192.168.1.146, mask=255.255.255.0, gw=192.168.1.2,
 >     host=192.168.1.146, domain=, nis-domain=(none),
 >     bootserver=192.168.1.78, rootserver=192.168.1.78, rootpath=
 >NET4: Unix domain sockets 1.0/SMP for Linux NET4.0.
 >Looking up port of RPC 100003/2 on 192.168.1.78
 >Looking up port of RPC 100005/1 on 192.168.1.78
 >VFS: Mounted root (nfs filesystem).
 >Freeing unused kernel memory: 76k init
 >Warning: unable to open an initial console.

Any help will be appreciated.

Thank you

Brian

At 12:53 PM 5/28/2003 +0300, you wrote:
>Hello Brian,
>You can try what I suggested in:
>http://lists.linuxppc.org/linuxppc-embedded/200305/msg00222.html
>i.e. in the file arch/ppc/platforms/walnut.h to replace
>typedef struct board_info {
>...
>} bd_t;
>
>with:
>#include <asm/ppcboot.h>
>Hope that helps,
>         Eran.


===============================================================
Brian S. Park  brian@corelis.com  (562) 926-6727 x143
---------------------------------------------------------------
Everything we do helps our customers get to market
FASTER with HIGHER quality and LOWER cost
===============================================================


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

^ permalink raw reply	[flat|nested] 13+ messages in thread
* getting Linux working on IBM Walnut demo board
@ 2003-05-27 18:49 Brian S. Park
  2003-05-27 19:53 ` Wolfgang Denk
  0 siblings, 1 reply; 13+ messages in thread
From: Brian S. Park @ 2003-05-27 18:49 UTC (permalink / raw)
  To: linuxppc-embedded


Hello all,

I'm new to embedded Linux and need help from all the gurus out there.

I'm trying to boot Linux on IBM Walnut demo board with PPC405GP.
I download ELDK, installed it on a RedHat Linx 7.3 machine.
I was able to build u-boot 3.0 which came with ELDK and it booted
successfully on my demo board.
However, when I tried to rebuild the kernel (2.4.4 which came with ELDK) it
gives me the following error.
I'm using the default configuration for Walnut board (i.e. make
rmproper;make walnut_config;make oldconfig;make dep; make pImage).

Also, the documentation on http://www.denx.de/doc/ seems a bit old (it
still talks about ppcboot instead u-boot). Are there new ocuments or FAQ's
for a newbie like me?

Any help will be appreciated.

Thank you.

ppc_4xx-gcc -D__KERNEL__
-I/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include -Wall
-Wstrict-prototypes -Os -fomit-frame-pointer -fno-strict-aliasing
-D__powerpc__ -fsigned-char -msoft-float -pipe -ffixed-r2
-Wno-uninitialized -mmultiple -mstring -mcpu=403 -g  -c -o init/main.o
init/main.c
In file included from
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/linux/raid/md.h:38,
                  from init/main.c:24:
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/io.h: In
function `virt_to_bus':
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/io.h:212:
`PCI_DRAM_OFFSET' undeclared (first use in this function)
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/io.h:212:
(Each undeclared identifier is reported only once
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/io.h:212:
for each function it appears in.)
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/io.h:216:
warning: control reaches end of non-void function
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/io.h: In
function `bus_to_virt':
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/io.h:223:
`PCI_DRAM_OFFSET' undeclared (first use in this function)
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/io.h:227:
warning: control reaches end of non-void function
In file included from
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/linux/bootmem.h:8,
                  from init/main.c:29:
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:
In function `enable_dma':
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:208:
`_IO_BASE' undeclared (first use in this function)
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:
In function `disable_dma':
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:224:
`_IO_BASE' undeclared (first use in this function)
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:
In function `clear_dma_ff':
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:239:
`_IO_BASE' undeclared (first use in this function)
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:
In function `set_dma_mode':
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:248:
`_IO_BASE' undeclared (first use in this function)
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:
In function `set_dma_page':
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:262:
`_IO_BASE' undeclared (first use in this function)
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:
In function `set_dma_addr':
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:308:
`_IO_BASE' undeclared (first use in this function)
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:
In function `set_dma_count':
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:336:
`_IO_BASE' undeclared (first use in this function)
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:
In function `get_dma_residue':
/mnt1/home/ELDK/ppc_4xx/usr/src/linux-2.4.4-2002-10-06/include/asm/dma.h:366:
`_IO_BASE' undeclared (first use in this function)
make: *** [init/main.o] Error 1


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

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

end of thread, other threads:[~2003-05-29 20:26 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <Your message of "Tue, 27 May 2003 11:49:51 PDT." <5.1.1.6.2.20030527114004.01282240@corelis.com>
     [not found] ` <5.1.1.6.2.20030527160449.0128b868@corelis.com>
     [not found]   ` <3ED48719.60004@mrv.com>
2003-05-28 18:53     ` getting Linux working on IBM Walnut demo board Brian S. Park
2003-05-28 20:10       ` Eran Mann
2003-05-28 20:53         ` Brian S. Park
2003-05-28 21:34           ` Wolfgang Denk
2003-05-28 22:16             ` Brian S. Park
2003-05-29 20:17               ` Brian S. Park
2003-05-29 20:26                 ` Wolfgang Denk
2003-05-28 20:59 Kerl, John
  -- strict thread matches above, loose matches on Subject: below --
2003-05-28 19:03 Kerl, John
2003-05-28 19:02 Kerl, John
2003-05-28 18:56 Kerl, John
2003-05-27 18:49 Brian S. Park
2003-05-27 19:53 ` Wolfgang Denk

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.