* how to get busybox shell prompt on console port?
@ 2005-04-10 14:51 Robert P. J. Day
2005-04-10 15:58 ` Kylo Ginsberg
0 siblings, 1 reply; 5+ messages in thread
From: Robert P. J. Day @ 2005-04-10 14:51 UTC (permalink / raw)
To: Embedded PPC Linux list
i'm still wrestling with how to get my 8xx-based board's shell
prompt to show up on the console port. i've built a simple
2.6.11.7-based kernel and (busybox-based) root filesystem and, fairly
quickly, i realized i needed to use the following kernel boot line:
Linux/PPC load: rw root=/dev/ram0 console=ttyCPM0,9600
as the boot proceeds, i eventually see:
Serial: CPM driver $Revision: 0.01 $
ttyCPM0 at MMIO 0xfa200a80 (irq = 20) is a CPM UART
ttyCPM1 at MMIO 0xfa200a00 (irq = 46) is a CPM UART
which seems to be a good sign. however, after all the standard boot
output, i'm left with no shell prompt, and i'm assuming it's just
because i haven't correctly started the shell thru /etc/inittab with
the correct parameters to have it talk to that console port.
what would be the correct invocation of /bin/sh in /etc/inittab to
reflect my serial/console port setup above? thanks.
rday
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: how to get busybox shell prompt on console port?
2005-04-10 14:51 how to get busybox shell prompt on console port? Robert P. J. Day
@ 2005-04-10 15:58 ` Kylo Ginsberg
2005-04-10 17:06 ` Robert P. J. Day
0 siblings, 1 reply; 5+ messages in thread
From: Kylo Ginsberg @ 2005-04-10 15:58 UTC (permalink / raw)
To: Robert P. J. Day; +Cc: Embedded PPC Linux list
I use this line in /etc/inittab (assuming you've built busybox to
include sh):
ttyCPM0::respawn:-/bin/sh
Robert P. J. Day wrote:
> i'm still wrestling with how to get my 8xx-based board's shell
>prompt to show up on the console port. i've built a simple
>2.6.11.7-based kernel and (busybox-based) root filesystem and, fairly
>quickly, i realized i needed to use the following kernel boot line:
>
> Linux/PPC load: rw root=/dev/ram0 console=ttyCPM0,9600
>
> as the boot proceeds, i eventually see:
>
> Serial: CPM driver $Revision: 0.01 $
> ttyCPM0 at MMIO 0xfa200a80 (irq = 20) is a CPM UART
> ttyCPM1 at MMIO 0xfa200a00 (irq = 46) is a CPM UART
>
>which seems to be a good sign. however, after all the standard boot
>output, i'm left with no shell prompt, and i'm assuming it's just
>because i haven't correctly started the shell thru /etc/inittab with
>the correct parameters to have it talk to that console port.
>
> what would be the correct invocation of /bin/sh in /etc/inittab to
>reflect my serial/console port setup above? thanks.
>
>rday
>_______________________________________________
>Linuxppc-embedded mailing list
>Linuxppc-embedded@ozlabs.org
>https://ozlabs.org/mailman/listinfo/linuxppc-embedded
>
>
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: how to get busybox shell prompt on console port?
2005-04-10 15:58 ` Kylo Ginsberg
@ 2005-04-10 17:06 ` Robert P. J. Day
2005-04-10 17:24 ` Kylo Ginsberg
0 siblings, 1 reply; 5+ messages in thread
From: Robert P. J. Day @ 2005-04-10 17:06 UTC (permalink / raw)
To: Kylo Ginsberg; +Cc: Embedded PPC Linux list
On Sun, 10 Apr 2005, Kylo Ginsberg wrote:
> I use this line in /etc/inittab (assuming you've built busybox to include sh):
>
> ttyCPM0::respawn:-/bin/sh
(first, a caveat: even though this is the 2.6 kernel, i'm still using
devfs for historical reasons. that will change shortly but may be
part of my problems.)
i'm pretty sure i tried that combo, and several others like it, and i
finally had success with the following entry in /etc/inittab:
::respawn:/bin/sh < /dev/console > /dev/console 2> /dev/console
yes, it's disgusting but it works. once i got a prompt, i noticed
that these are the contents of /dev:
crw------- 1 root root 204, 46 Dec 31 1969 <NULL>0
crw------- 1 root root 204, 47 Dec 31 1969 <NULL>1
crw------- 1 root root 5, 1 Oct 2 08:56 console
crw-rw-rw- 1 root root 1, 7 Dec 31 1969 full
drwxr-xr-x 1 root root 0 Dec 31 1969 input
crw-r----- 1 root root 1, 2 Dec 31 1969 kmem
crw-r--r-- 1 root root 1, 11 Dec 31 1969 kmsg
drwxr-xr-x 1 root root 0 Dec 31 1969 loop
crw-r----- 1 root root 1, 1 Dec 31 1969 mem
drwxr-xr-x 1 root root 0 Dec 31 1969 misc
crw-rw-rw- 1 root root 1, 3 Dec 31 1969 null
crw-r----- 1 root root 1, 4 Dec 31 1969 port
crw-rw-rw- 1 root root 5, 2 Dec 31 1969 ptmx
drwxr-xr-x 1 root root 0 Dec 31 1969 pts
drwxr-xr-x 1 root root 0 Dec 31 1969 pty
crw-r--r-- 1 root root 1, 8 Dec 31 1969 random
drwxr-xr-x 1 root root 0 Dec 31 1969 rd
lr-xr-xr-x 1 root root 4 Sep 25 1969 root -> rd/0
drwxr-xr-x 1 root root 0 Dec 31 1969 shm
crw-rw-rw- 1 root root 5, 0 Dec 31 1969 tty
crw-r--r-- 1 root root 1, 9 Dec 31 1969 urandom
crw-rw-rw- 1 root root 1, 5 Dec 31 1969 zero
in other words, no /dev/ttyCPM0 which may be why that first solution
never worked (i'm still fuzzy on support for the serial/console ports
so i'm reading up on that now.) but given that i have a /dev/console,
i'll stick with that for now until i have a better fix.
and what's the two "NULL" entries up there? those are new to me.
rday
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: how to get busybox shell prompt on console port?
2005-04-10 17:06 ` Robert P. J. Day
@ 2005-04-10 17:24 ` Kylo Ginsberg
2005-04-10 20:58 ` Robert P. J. Day
0 siblings, 1 reply; 5+ messages in thread
From: Kylo Ginsberg @ 2005-04-10 17:24 UTC (permalink / raw)
To: Robert P. J. Day; +Cc: Embedded PPC Linux list
[-- Attachment #1: Type: text/html, Size: 3158 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: how to get busybox shell prompt on console port?
2005-04-10 17:24 ` Kylo Ginsberg
@ 2005-04-10 20:58 ` Robert P. J. Day
0 siblings, 0 replies; 5+ messages in thread
From: Robert P. J. Day @ 2005-04-10 20:58 UTC (permalink / raw)
To: Kylo Ginsberg; +Cc: Embedded PPC Linux list
[-- Attachment #1: Type: TEXT/PLAIN, Size: 601 bytes --]
On Sun, 10 Apr 2005, Kylo Ginsberg wrote:
> Fwiw, I explicitly created the CPM devices; note that the
> major/minor match those of your NULL nodes. I'm running 2.6.11.
> I'm fuzzy re if/how these devices should be automagically created by
> the kernel.
>
> mknod ttyCPM0 c 204 46
> mknod ttyCPM1 c 204 47
> chmod 660 ttyCPM*
>
...
> crw------- 1 root root 204, 46 Dec 31 1969 <NULL>0
> crw------- 1 root root 204, 47 Dec 31 1969 <NULL>1
well, since i'm using devfs, i'm assuming that's what i get by
default. ok, that clears up some of the confusion. thanks.
rday
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2005-04-10 21:01 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-04-10 14:51 how to get busybox shell prompt on console port? Robert P. J. Day
2005-04-10 15:58 ` Kylo Ginsberg
2005-04-10 17:06 ` Robert P. J. Day
2005-04-10 17:24 ` Kylo Ginsberg
2005-04-10 20:58 ` Robert P. J. Day
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).