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

Masakazu Mokuno mokuno at sm.sony.co.jp
Wed Aug 29 21:30:25 EST 2007


Fix the bug that the major version part of the firmware 
is not compared.

Signed-off-by: Masakazu Mokuno <mokuno at sm.sony.co.jp>
CC: Geoff Levand <geoffrey.levand at am.sony.com>
---
 arch/powerpc/platforms/ps3/setup.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

--- a/arch/powerpc/platforms/ps3/setup.c
+++ b/arch/powerpc/platforms/ps3/setup.c
@@ -63,7 +63,8 @@ int ps3_compare_firmware_version(u16 maj
 	x.minor = minor;
 	x.rev = rev;
 
-	return (ps3_firmware_version.raw - x.raw);
+	return (ps3_firmware_version.raw > x.raw) -
+	       (ps3_firmware_version.raw < x.raw);
 }
 EXPORT_SYMBOL_GPL(ps3_compare_firmware_version);
 
--
Masakazu MOKUNO




More information about the Linuxppc-dev mailing list