public inbox for ecos-patches@sourceware.org
 help / color / mirror / Atom feed
* Correct redboot hang with uninitialized config.
@ 2010-04-23 10:27 Kirill Berezin
  2010-04-23 12:02 ` John Dallaway
  0 siblings, 1 reply; 2+ messages in thread
From: Kirill Berezin @ 2010-04-23 10:27 UTC (permalink / raw)
  To: ecos-patches

[-- Attachment #1: Type: text/plain, Size: 353 bytes --]

Hello,

I suddenly came across possible hang or sigfault condition for redboot 
with no configuration stored in flash.
The current version of dns module has a default initialization of dns 
domain as a pointer to zero.
As a result redboot hangs on boot on mips32 platform. I attached a patch 
with possible solution, I hope it will be helpful.

Kirill.

[-- Attachment #2: redboot_dns_init.diff --]
[-- Type: text/plain, Size: 660 bytes --]

Index: dns.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/redboot/current/src/net/dns.c,v
retrieving revision 1.5
diff -c -r1.5 dns.c
*** dns.c	29 Jan 2009 17:50:04 -0000	1.5
--- dns.c	22 Apr 2010 12:09:32 -0000
***************
*** 76,82 ****
                        dns_domain,
                        ALWAYS_ENABLED, true,
                        CONFIG_STRING,
!                       0
          );
  #endif
  
--- 76,82 ----
                        dns_domain,
                        ALWAYS_ENABLED, true,
                        CONFIG_STRING,
!                       ""
          );
  #endif
  

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

* Re: Correct redboot hang with uninitialized config.
  2010-04-23 10:27 Correct redboot hang with uninitialized config Kirill Berezin
@ 2010-04-23 12:02 ` John Dallaway
  0 siblings, 0 replies; 2+ messages in thread
From: John Dallaway @ 2010-04-23 12:02 UTC (permalink / raw)
  To: Kirill Berezin; +Cc: ecos-patches

Hi Kirill

Kirill Berezin wrote:

> I suddenly came across possible hang or sigfault condition for redboot
> with no configuration stored in flash.
> The current version of dns module has a default initialization of dns
> domain as a pointer to zero.
> As a result redboot hangs on boot on mips32 platform. I attached a patch
> with possible solution, I hope it will be helpful.

Good catch. Fix checked in.

Thank you

John Dallaway
eCos maintainer

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

end of thread, other threads:[~2010-04-23 12:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-04-23 10:27 Correct redboot hang with uninitialized config Kirill Berezin
2010-04-23 12:02 ` John Dallaway

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 read-only IMAP folder(s) and NNTP newsgroup(s).