public inbox for ecos-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug 1000672] New: redboot fconfig crash with gcc 4.3.2
@ 2009-01-20 19:26 bugzilla-daemon
  2009-02-22 15:21 ` [Bug 1000672] " bugzilla-daemon
  2009-03-04 17:25 ` bugzilla-daemon
  0 siblings, 2 replies; 3+ messages in thread
From: bugzilla-daemon @ 2009-01-20 19:26 UTC (permalink / raw)
  To: ecos-bugs

http://bugs.ecos.sourceware.org/show_bug.cgi?id=1000672

           Summary: redboot fconfig crash with gcc 4.3.2
           Product: eCos
           Version: CVS
          Platform: ixdp425 (Intel XScale IXDP425 board)
        OS/Version: ARM
            Status: UNCONFIRMED
          Severity: critical
          Priority: high
         Component: RedBoot
        AssignedTo: gary@mlbassoc.com
        ReportedBy: jvasco@verizon.net
         QAContact: ecos-bugs@ecos.sourceware.org
             Class: ---


Redboot gets an exception when trying to set any IP address with fconfig
when using gcc-4.3.2 on an ixp425 target (armeb). The issue seems to be
an alignment problem as val_ptr contains an odd address; it looks like gcc
is optimizing and trying to do a copy on a word boundary. The removal of
the cast fixes the problem.

This doesn't look like a compiler bug to me. I suspect that this problem
affects other arm variants but I only have access to an ixp425. The code
is incorrect as val_ptr is pointing to a place in a configuration buffer for
the raw data. Imposing (via a cast) a structure is not the right solution.
Note that a few lines down in the source, the memcpy in the other direction
does not have such a cast.

--- fconfig.c 2009-01-18 14:34:11.000000000 -0500
+++ fconfig.c.new 2009-01-18 14:35:22.000000000 -0500
@@ -388,7 +388,7 @@
break;
#ifdef CYGPKG_REDBOOT_NETWORKING
case CONFIG_IP:
- memcpy(&hold_ip_val.s_addr, &((in_addr_t *)val_ptr)->s_addr,
sizeof(in_addr_t));
+        memcpy(&hold_ip_val.s_addr, val_ptr, sizeof(in_addr_t));
       if (!_gethostbyname(line, &new_ip_val)) {
           return CONFIG_BAD;
       }


-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


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

* [Bug 1000672] redboot fconfig crash with gcc 4.3.2
  2009-01-20 19:26 [Bug 1000672] New: redboot fconfig crash with gcc 4.3.2 bugzilla-daemon
@ 2009-02-22 15:21 ` bugzilla-daemon
  2009-03-04 17:25 ` bugzilla-daemon
  1 sibling, 0 replies; 3+ messages in thread
From: bugzilla-daemon @ 2009-02-22 15:21 UTC (permalink / raw)
  To: ecos-bugs

http://bugs.ecos.sourceware.org/show_bug.cgi?id=1000672


John Dallaway <john@dallaway.org.uk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Version|CVS                         |3.0beta1




--- Comment #1 from John Dallaway <john@dallaway.org.uk>  2009-02-22 15:20:49 ---
Moving to version "3.0beta1" to ensure this issue receives attention.

The originator's patch is at:

  http://ecos.sourceware.org/ml/ecos-patches/2009-01/msg00016.html

Gary, there seems to be some doubt as to whether this is a compiler bug. If it
is a compiler bug, we need a workaround for eCos 3.0. Do you have time to
investigate further at present or should this be assigned to someone else?


-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


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

* [Bug 1000672] redboot fconfig crash with gcc 4.3.2
  2009-01-20 19:26 [Bug 1000672] New: redboot fconfig crash with gcc 4.3.2 bugzilla-daemon
  2009-02-22 15:21 ` [Bug 1000672] " bugzilla-daemon
@ 2009-03-04 17:25 ` bugzilla-daemon
  1 sibling, 0 replies; 3+ messages in thread
From: bugzilla-daemon @ 2009-03-04 17:25 UTC (permalink / raw)
  To: ecos-bugs

http://bugs.ecos.sourceware.org/show_bug.cgi?id=1000672


Gary Thomas <gary@mlbassoc.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |CURRENTRELEASE




--- Comment #2 from Gary Thomas <gary@mlbassoc.com>  2009-03-04 17:25:44 ---
Change applied - 2009-03-04


-- 
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


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

end of thread, other threads:[~2009-03-04 17:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-01-20 19:26 [Bug 1000672] New: redboot fconfig crash with gcc 4.3.2 bugzilla-daemon
2009-02-22 15:21 ` [Bug 1000672] " bugzilla-daemon
2009-03-04 17:25 ` bugzilla-daemon

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).