Thread (4 messages) 4 messages, 3 authors, 2007-08-29

Re: [PATCH] PS3: fix the bug the major version part is not compared

From: Andreas Schwab <hidden>
Date: 2007-08-28 13:26:58

Masakazu Mokuno [off-list ref] writes:
quoted hunk ↗ jump to hunk
Fix the bug that the major version part of the firmware 
is not compared.

Signed-off-by: Masakazu Mokuno <redacted>
CC: Geoff Levand <redacted>
---
 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."
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help