From: Andreas Schwab <schwab@suse•de>
To: Masakazu Mokuno <mokuno@sm•sony.co.jp>
Cc: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom•com>,
linuxppc-dev@ozlabs•org, paulus@samba•org
Subject: Re: [PATCH] PS3: fix the bug the major version part is not compared
Date: Tue, 28 Aug 2007 15:26:50 +0200 [thread overview]
Message-ID: <jehcmj3i3p.fsf@sykes.suse.de> (raw)
In-Reply-To: <20070828211415.C2B5.MOKUNO@sm.sony.co.jp> (Masakazu Mokuno's message of "Tue\, 28 Aug 2007 21\:32\:29 +0900")
Masakazu Mokuno <mokuno@sm•sony.co.jp> writes:
> Fix the bug that the major version part of the firmware
> is not compared.
>
> Signed-off-by: Masakazu Mokuno <mokuno@sm•sony.co.jp>
> CC: Geoff Levand <geoffrey.levand@am•sony.com>
> ---
> arch/powerpc/platforms/ps3/setup.c | 2 +-
> include/asm-powerpc/ps3.h | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
>
> --- a/arch/powerpc/platforms/ps3/setup.c
> +++ b/arch/powerpc/platforms/ps3/setup.c
> @@ -54,7 +54,7 @@ void ps3_get_firmware_version(union ps3_
> }
> EXPORT_SYMBOL_GPL(ps3_get_firmware_version);
>
> -int ps3_compare_firmware_version(u16 major, u16 minor, u16 rev)
> +s64 ps3_compare_firmware_version(u16 major, u16 minor, u16 rev)
> {
> union ps3_firmware_version x;
>
Better yet: normalize the return value.
return (ps3_firmware_version.raw > x.raw) -
(ps3_firmware_version.raw < x.raw);
Andreas.
--
Andreas Schwab, SuSE Labs, schwab@suse•de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
PGP key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
next prev parent reply other threads:[~2007-08-28 13:26 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-28 12:32 [PATCH] PS3: fix the bug the major version part is not compared Masakazu Mokuno
2007-08-28 13:26 ` Andreas Schwab [this message]
2007-08-29 11:21 ` Masakazu Mokuno
2007-08-28 19:49 ` Geoff Levand
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=jehcmj3i3p.fsf@sykes.suse.de \
--to=schwab@suse$(echo .)de \
--cc=Geert.Uytterhoeven@sonycom$(echo .)com \
--cc=linuxppc-dev@ozlabs$(echo .)org \
--cc=mokuno@sm$(echo .)sony.co.jp \
--cc=paulus@samba$(echo .)org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox