[U-Boot] [U-Boot-Users] [PATCH] cmd_spi: remove broken signed casting for display

Wolfgang Denk wd at denx.de
Tue Oct 14 14:20:35 CEST 2008


Dear Mike Frysinger,

In message <1223982278-28497-1-git-send-email-vapier at gentoo.org> you wrote:
> Since we're working with unsigned data, you can't apply a signed pointer
> cast and then attempt to print the result.  Otherwise you get wrong output
> when the sign bit is set like "0xFF" incorrectly extended to "0xFFFFFFFF".
> 
> Signed-off-by: Mike Frysinger <vapier at gentoo.org>
> ---
>  common/cmd_spi.c |    3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)

Applied, thanks.

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
Where a calculator on the ENIAC is equipped with 18,000 vacuum  tubes
and  weighs  30  tons,  computers  in  the future may have only 1,000
vacuum tubes and weigh only 1/2 tons. - Popular Mechanics, March 1949


More information about the U-Boot mailing list