[U-Boot] [PATCH] board/flagadm/flash.c: fix compile warning

Wolfgang Denk
2009-09-11T18:10:58Z

Dear Scott Wood,

In message <20090911163321.GB13783@b07421-ec1.am.freescale.net> you wrote:
>
> > - ushort * d = (ushort*)&da;
> > + ulong *dla = &da;
> > + ushort *d = (ushort*)dla;
>
> I don't see how this is any more legal under strict aliasing rules -- you
> just made it a little more complicated and fooled the compiler into not
> warning.

Hm... I apologize if I don;t understand this any better, but for me
silencing the compiler was all that I intended at this moment ;-)

Do you have any better approach?

Best regards,

Wolfgang Denk

--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Eureka! -- Archimedes