Subject: RE: busybox does not like 2.4.8, or the other way around?

From: Marc Karasek <[email-masked]>
Date: Wed, 26 Sep 2001 11:53:39 -0400

Yes, there was a bug in busybox that caused this.  I helped track it down a
few months ago and it should be fixed in the latest one.  I have attached an
email about the bug.  What version(s) of busybox are you using?

-----Original Message-----
From: Karsten Merker [mailto:[email-masked]]
Sent: Friday, September 21, 2001 1:30 AM
To: Jun Sun
Cc: [email-masked]
Subject: Re: busybox does not like 2.4.8, or the other way around?

On Thu, Sep 20, 2001 at 06:21:49PM -0700, Jun Sun wrote:

> I have a small busybox userland that works fine with 2.4.2 kernel, but
failed
> with the latest 2.4.8 kernel.  The symptom is that it is stuck at the
> following prompt:

[busybox waiting for keypress]

> A simple test shows the console is still working, i.e., pressing a key
*does*
> generate an interrupt and ISR *does* read the correct char value.
> 
> I really cannot think of anything else that might make busybox stuck here.

> Any clue?  Anybody else is using busybox with more recent kernels?

I have a smilar problem on my DECstation. Using 2.4.8 with the Debian
boot-floppies (based on busybox), the machine hangs when waiting for
the first keypress after the splash screen.
When booting 2.4.8 with my "normal" installation into single user mode,
I get a shell prompt, but cannot enter anything. I first thought of
a problem with the DECstation keyboard driver, but the same happens
on serial console. I have tested various kernel version with regard
to this - the last one working for me is 2.4.5.
When booting my "normal" installation with 2.4.8 into multiuser mode,
the machine crashes somewhere in the init scripts.

Is your box little or big endian?

Greetings,
Karsten
-- 
#include <standard_disclaimer>
Nach Paragraph 28 Abs. 3 Bundesdatenschutzgesetz widerspreche ich der
Nutzung
oder Uebermittlung meiner Daten fuer Werbezwecke oder fuer die Markt- oder
Meinungsforschung.

Subject: Re: Bug in serial.c
From: Fabrice Gautier <[email-masked]>
To: Marc Karasek <[email-masked]>
Cc: [email-masked]
Date: Sat, 21 Apr 2001 11:54:03 -0400

Hi Marc and Kanoj

This is definitely a busybox bug for me. Busybox (0.50pre) init didn't
set CREAD in c_cflag:

--- init.c.orig	Sat Apr 21 17:46:57 2001
+++ init.c	Sat Apr 21 17:46:31 2001
@@ -276,7 +276,7 @@
 
 	/* Make it be sane */
 	tty.c_cflag &= CBAUD|CBAUDEX|CSIZE|CSTOPB|PARENB|PARODD;
-	tty.c_cflag |= HUPCL|CLOCAL;
+	tty.c_cflag |= CREAD|HUPCL|CLOCAL;
 
 	/* input modes */
 	tty.c_iflag = ICRNL | IXON | IXOFF;

Guess this is the same problem for other inits. 
The sample init code Richard B. Johnson posted on lkml does have CREAD,
that's why he didn't noticed anything.

Thanks,

On Fri, 20 Apr 2001 23:01:50 -0400
Marc Karasek <[email-masked]> wrote:

> I got in touch with Kanoj (his email was the last one in the comments of
> serial.c) 
> 
> He recommended I make the below change to serial.c.  It worked for me and
I
> got my serial console port back :-)  
> 
> 
>  Okay. In change_speed(), comment out the two lines 
> 
>           if ((cflag & CREAD) == 0) 
>                   info->ignore_status_mask |= UART_LSR_DR; 
>     
>   This might get you back up. If you can track back to how the serial 
>   port needs to be opened, or some extra ioctls need to be made, let 
>   me know. 
> 
>   Kanoj 
> 
> 
> -----Original Message-----
> From: Fabrice Gautier
> To: [email-masked]
> Cc: [email-masked]
> Sent: 4/20/01 12:31 PM
> Subject: Re: Bug in serial.c
> 
> Same thing for me.
> 
> I'm using busybox as init/getty/shell.
> 
> Everything works fine with 2.4.2.
> With 2.4.3 console output is fine but not input.
> 
> Thanks
> 
> -- 
> Fabrice Gautier <[email-masked]>

-- 
Fabrice Gautier <[email-masked]>

---

From: Jun Sun <[email-masked]>
Date: Wed, 26 Sep 2001 10:26:01 -0700

> email about the bug.  What version(s) of busybox are you using?

It is 0.51.  Looks like the same busybox bug to me.  Time to update busybox.

I'd appreciate if someone has already updated my little busybox ramdisk at
http://linux.junsun.net and send me a copy ...

Jun

---

From: Karsten Merker <[email-masked]>
Date: Wed, 26 Sep 2001 18:47:10 +0200

On Wed, Sep 26, 2001 at 11:53:39AM -0400, Marc Karasek wrote:

[busybox does not react to a keypress]
> email about the bug.  What version(s) of busybox are you using?

busybox 0.60.1-2 (current version from Debian/Sid)

> > With 2.4.3 console output is fine but not input.

Hm, this seems to be another problem - 2.4.3 and 2.4.5 work fine for me,
anything newer than 2.4.5 does not. I suppose we have a kernel problem
after 2.4.5 as kernels newer than 2.4.5 completely crash on a DECstation 
sooner or later during bootup.

Greetings,
Karsten
-- 
#include <standard_disclaimer>
Nach Paragraph 28 Abs. 3 Bundesdatenschutzgesetz widerspreche ich der Nutzung
oder Uebermittlung meiner Daten fuer Werbezwecke oder fuer die Markt- oder
Meinungsforschung.

---

From: Geoffrey Espin <[email-masked]>
Date: Wed, 26 Sep 2001 14:56:23 -0700

Jun,

> http://linux.junsun.net and send me a copy ...

I couldn't get yours to work either.

I've put my ramdisk.o (ext2 fs) (you know where it goes :-)) with
busybox 60.1 tested on 2.4.9+SF on Markham/Korva:

    http://www.idiom.com/~espin/linux

I'll put my whole userland & ramdisk build scheme up soon...
mostly "souped up" VRLinux scheme with Lineo stuff.

Made with my own "gcc version 3.0 20010422 (prerelease)" as
ftp.mvista.com still down, eh.

BTW, your nec_candy.c driver didn't work for me (MII/PHY probs?)...
my old 2.4.0 candy.c version works.  Also, put up for you
consideration are small korva/{prom.c,setup.c} tweaks.

Geoff
-- 
Geoffrey Espin [email-masked]

---

From: Jun Sun <[email-masked]>
Date: Thu, 27 Sep 2001 10:21:39 -0700

Geoffrey Espin wrote:
> my old 2.4.0 candy.c version works. 

The setup for the driver is changed.  Did you add the driver setup code?  Look
for arch/mips/korva/candy_setup.c.

> Also, put up for you

Can you post them in patch format?  (use diff -u)

Jun