[patch] correctly count CPU objects in the ia64/sn hwperf interface

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Tony,

please accept this patch to fix a logic error in the SGI ia64/sn
hwperf interface.

Thanks
-- Mark

Correctly count CPU objects for SGI ia64/sn hwperf interface

Signed-off-by: Mark Goodwin <markgw@xxxxxxx>
Signed-off-by: Jack Steiner <steiner@xxxxxxx>

--- a/arch/ia64/sn/kernel/sn2/sn_hwperf.c	2007-07-03 20:48:17.000000000 +1000
+++ b/arch/ia64/sn/kernel/sn2/sn_hwperf.c	2007-07-03 16:04:35.472855575 +1000
@@ -750,9 +750,10 @@
 			goto error;
 		} else
 		if ((r = sn_hwperf_enum_objects(&nobj, &objs)) == 0) {
+			int cpuobj_index = 0;
+
 			memset(p, 0, a.sz);
 			for (i = 0; i < nobj; i++) {
-				int cpuobj_index = 0;
 				if (!SN_HWPERF_IS_NODE(objs + i))
 					continue;
 				node = sn_hwperf_obj_to_cnode(objs + i);

[Index of Archives]     [Linux Kernel]     [Sparc Linux]     [DCCP]     [Linux ARM]     [Yosemite News]     [Linux SCSI]     [Linux x86_64]     [Linux for Ham Radio]

  Powered by Linux