lkml.org 
[lkml]   [2001]   [May]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: serial console problems with 2.4.4
From
Date
Fabrice Gautier <gautier@email.enst.fr> writes:

> On 02 May 2001 10:37:21 -0600
> ebiederm@xmission.com (Eric W. Biederman) wrote:
>
> > Fabrice Gautier <gautier@email.enst.fr> writes:
> > > So this this probably a sulogin/mingetty problem. They should set the
> > > CREAD flag in your tty c_cflag.
> > >
> > > the patch for busybox repalced the line
> > > tty.c_cflag |= HUPCL|CLOCAL
> > > by
> > > tty.c_cflag |= CREAD|HUPCL|CLOCAL
> > >
> > > Hope this help.
> >
> > This part is correct.
> >
> > However the kernel sets CREAD by default.
>
> Are your sure? Wasn't this the behaviour for 2.4.2 but changed in 2.4.3

init=/bin/bash works fine over a serial console in 2.4.4. So I am
certain.

I get the impression that something in 2.4.3 fixed CREAD handling, and we
started noticing the buggy user space.

> > sysvinit (and possibly other inits) clears CREAD.
>
> In my case I was using busybox as init. So there is no sysinit or any other
> init called before this line.

The busy box init is also clearing CREAD (as of 0.51 anyway).

> > I wish I knew where the breakage actually occured.
>
> Just look at this diff on serial.c between 2.4.2 and 2.4.3:

If it was a real diff between 2.4.2 and 2.4.3 I would agree, however it looks
like your attempt to fix 2.4.3.

Eric


> --- serial.c Sat Apr 21 17:22:53 2001
> +++ ../../../linux-2.4.2/drivers/char/serial.c Sat Feb 17 01:02:36 2001
> @@ -1764,8 +1765,8 @@
> /*
> * !!! ignore all characters if CREAD is not set
> */
> -// if ((cflag & CREAD) == 0)
> -// info->ignore_status_mask |= UART_LSR_DR;
> + if ((cflag & CREAD) == 0)
> + info->ignore_status_mask |= UART_LSR_DR;
> save_flags(flags); cli();
> if (uart_config[info->state->type].flags & UART_STARTECH) {
> serial_outp(info, UART_LCR, 0xBF);
>

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:52    [from the cache]
©2003-2011 Jasper Spaans