This is the mail archive of the
ecos-patches@sources.redhat.com
mailing list for the eCos project.
PowerPC - more warnings cleaned up
- From: Gary Thomas <gary at mlbassoc dot com>
- To: eCos patches <ecos-patches at ecos dot sourceware dot org>
- Date: Fri, 23 Apr 2004 15:12:24 -0600
- Subject: PowerPC - more warnings cleaned up
- Organization: MLB Associates
--
Gary Thomas <gary@mlbassoc.com>
MLB Associates
Index: hal/powerpc/arch/current/ChangeLog
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/hal/powerpc/arch/current/ChangeLog,v
retrieving revision 1.62
diff -u -5 -p -r1.62 ChangeLog
--- hal/powerpc/arch/current/ChangeLog 23 Apr 2004 20:55:32 -0000 1.62
+++ hal/powerpc/arch/current/ChangeLog 23 Apr 2004 21:10:38 -0000
@@ -1,7 +1,8 @@
2004-04-23 Gary Thomas <gary@mlbassoc.com>
+ * include/hal_arch.h:
* src/redboot_linux_exec.c (do_exec): Fix compiler warning about bad
cast (dereferencing type-punned pointer will break strict-aliasing rules)
2004-04-22 Jani Monoses <jani@iv.ro>
Index: hal/powerpc/arch/current/include/hal_arch.h
===================================================================
RCS file: /misc/cvsfiles/ecos/packages/hal/powerpc/arch/current/include/hal_arch.h,v
retrieving revision 1.13
diff -u -5 -p -r1.13 hal_arch.h
--- hal/powerpc/arch/current/include/hal_arch.h 24 Nov 2003 14:28:15 -0000 1.13
+++ hal/powerpc/arch/current/include/hal_arch.h 23 Apr 2004 21:10:39 -0000
@@ -10,10 +10,11 @@
//=============================================================================
//####ECOSGPLCOPYRIGHTBEGIN####
// -------------------------------------------
// This file is part of eCos, the Embedded Configurable Operating System.
// Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
+// Copyright (C) 2004 Gary Thomas
//
// eCos is free software; you can redistribute it and/or modify it under
// the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2 or (at your option) any later version.
//
@@ -267,11 +268,11 @@ typedef struct {
// Copy a set of registers from a HAL_SavedRegisters structure into a
// GDB ordered array.
#define HAL_GET_GDB_REGISTERS( _aregval_, _regs_ ) \
CYG_MACRO_START \
- GDB_Registers *_gdb_ = (GDB_Registers *)(_aregval_); \
+ GDB_Registers *_gdb_ = (GDB_Registers *)((void *)(_aregval_)); \
int _i_; \
\
for( _i_ = 0; _i_ < 32; _i_++ ) \
_gdb_->gpr[_i_] = (_regs_)->d[_i_]; \
\
@@ -279,17 +280,17 @@ typedef struct {
_gdb_->msr = (_regs_)->msr; \
_gdb_->cr = (_regs_)->cr; \
_gdb_->lr = (_regs_)->lr; \
_gdb_->ctr = (_regs_)->ctr; \
_gdb_->xer = (_regs_)->xer; \
- HAL_GET_GDB_FLOATING_POINT_REGISTERS(_gdb_, _regs_); \
+ HAL_GET_GDB_FLOATING_POINT_REGISTERS(_gdb_, _regs_); \
CYG_MACRO_END
// Copy a GDB ordered array into a HAL_SavedRegisters structure.
#define HAL_SET_GDB_REGISTERS( _regs_ , _aregval_ ) \
CYG_MACRO_START \
- GDB_Registers *_gdb_ = (GDB_Registers *)(_aregval_); \
+ GDB_Registers *_gdb_ = (GDB_Registers *)((void *)(_aregval_)); \
int _i_; \
\
for( _i_ = 0; _i_ < 32; _i_++ ) \
(_regs_)->d[_i_] = _gdb_->gpr[_i_]; \
\
@@ -297,11 +298,11 @@ typedef struct {
(_regs_)->msr = _gdb_->msr; \
(_regs_)->cr = _gdb_->cr; \
(_regs_)->lr = _gdb_->lr; \
(_regs_)->ctr = _gdb_->ctr; \
(_regs_)->xer = _gdb_->xer; \
- HAL_SET_GDB_FLOATING_POINT_REGISTERS(_regs_, _gdb_); \
+ HAL_SET_GDB_FLOATING_POINT_REGISTERS(_regs_, _gdb_); \
CYG_MACRO_END
//-----------------------------------------------------------------------------
// HAL setjmp