sysvinit-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [sysvinit-devel] the sysvinit pause


From: Dr. Werner Fink
Subject: Re: [sysvinit-devel] the sysvinit pause
Date: Fri, 18 Jan 2013 13:28:07 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

On Fri, Jan 18, 2013 at 12:59:48PM +0000, Yi Qingliang wrote:
> Thanks!
> 
> So tired... But, maybe you should congratulate me:).
> I got the root cause finally, although I still have doubt.

Please submit your patch to the kernels people. Simply to make
the tty code more reliable :)

> 1. same binary (barebox+kernel+rootfs) running well on mini2440
> 
> 2. I compared the serial related registers in CPU, and found only one 
> different:
> the register "UCON0"'s bitfield [11:10], ie. clock selection.
> on mini2440, it is 10, on my s3c2442, it is 00.
> on mini2440, the tty's wait_until_sent will return quickly, not on s3c2442.
> 
> on mini2440, the first try in waiting will found there is something not 
> sended, 
> the second try will found it cleared.
> 
> but on s3c2442, NOT so.
> 
> 
> 3. check the tty driver, I found in samsung.c, there is one function is 
> related with that:
>       's3c24xx_serial_setsource'
> 
> 4. and then found the caller: 's3c24xx_serial_set_termios'. I have added 
> printk in it. and the different it is.
> 
> 5. in 's3c24xx_serial_set_termios', it will find clock in system info,
> on mini2440, it found, on my s3c2442, no luck.
> 
> 6. add printk to print out all clocks. 
> on my s3c2442, there is not 'clk_uart_baud[1-3]'
> 
> 7, I continue search the clock sources, found that in arch/arm/mach-
> s3c24xx/clock-s3c2442.c. but it is only registered for s3c2440, not s3c2442.
> 
> 8. I checked directory mach-s3c24xx, found file 's3c2442.c' had registered 
> some 
> clock info for s3c2442, but only camera related.
> 
> 9. I added register routine in clock-s3c2440.c to register for s3c2442, 
> accroding to registering for s3c2440. (dropped camera related because 
> s3c2442.c registered that already, but different with s3c2440's)
> 
> 10. DONE!!!!! the problem freezing 30section missed. then the getty will give 
> login prompt without '-i' option.
> 
> 11. maybe it is done! but I don't know why kernel code have not register uart 
> related clock info for s3c2442, and I don't know where I can get the answer.
> 
> 
> 
> On Thursday, January 17, 2013 08:52:03 AM Dr. Werner Fink wrote:
> > On Thu, Jan 17, 2013 at 08:42:51AM +0000, Yi Qingliang wrote:
> > > On Wednesday, January 16, 2013 08:56:17 AM Dr. Werner Fink wrote:
> > > > On Wed, Jan 16, 2013 at 10:08:50AM +0000, address@hidden 
> wrote:
> > > > > On Wednesday, January 16, 2013 09:44:10 AM address@hidden
> > > 
> > > wrote:
> > > > > > On Tuesday, January 15, 2013 04:56:44 PM Dr. Werner Fink wrote:
> > > > > > > On Tue, Jan 15, 2013 at 11:11:21PM +0800, Yi Qingliang wrote:
> > > > > > > > On Tuesday, January 15, 2013 12:16:46 PM Dr. Werner Fink wrote:
> > > > > > > > > On Tue, Jan 15, 2013 at 06:42:26PM +0000,
> > > > > > > > > address@hidden
> > > > > 
> > > > > why the close(fd) freeze for 30seconds?
> > > > > is it related with serial setting? or serial driver?
> > > > 
> > > > That more kernel driver related. Sorry, but I'm not familiar with this
> > > > kind
> > > > of serial device nor driver :(
> > > 
> > > which tty the sysvinit will open if the kernel parameter is
> > > 'console=ttySAC0"? I debugged the sysvinit, it open the /dev/console, is
> > > that normal?
> > Yes as /dev/console is the system console and the real devices used for
> > the console are handled by the kernel.  Compare with e.g.
> > 
> >          cat /proc/consoles
> > 
> > which will list all devices used for the system console[1].  Even printers
> > could be used for a channel of the system console.
> > 
> > 
> >     Werner
> > 
> > [1] https://patchwork.kernel.org/patch/461091/
> -- 
> Nanjing Jilong
> Yi Qingliang
> address@hidden

       Werner

-- 
  "Having a smoking section in a restaurant is like having
          a peeing section in a swimming pool." -- Edward Burr



reply via email to

[Prev in Thread] Current Thread [Next in Thread]