fix for HZ != 100 on i386

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

fix for HZ != 100 on i386

Alexandre Ratchov
Hello,

In sys/src/i386/i386/powernow-k7.c and powernow-k8.c we use the
CPU_CLOCKUPDATE() macro to determine cstate->fsb at initialization. The
CPU_CLOCKUPDATE() macro just sets 'pentium_base_tsc' (defined in
microtime.s). This seems to be needed regardless if HZ is defined.

however, if HZ is defined, then CPU_CLOCKUPDATE() and pentium_base_tsc
aren't defined and in this case, the kernel compilation fails.

The attached patch, fixes this in the following way:

        - define PENTIUM_CLOCKUPDATE() and pentium_base_tsc, even if HZ
          is defined.

        - make powernow-k7.c and powernow-k8.c use
          PENTIUM_CLOCKUPDATE() (instead of CPU_CLOCKUPDATE())

        - if HZ isn't defined, then define CPU_CLOCKUPDATE() to
          PENTIUM_CLOCKUPDATE(), so it will be used in
          sys/kern/kern_clock.c

Works for me with HZ = 1024. Comments?

regards,

--
Alexandre
Index: i386/microtime.s
===================================================================
RCS file: /cvs/src/sys/arch/i386/i386/microtime.s,v
retrieving revision 1.20
diff -u -r1.20 microtime.s
--- i386/microtime.s 13 Jun 2004 21:49:15 -0000 1.20
+++ i386/microtime.s 7 Jan 2006 18:56:39 -0000
@@ -135,12 +135,17 @@
 
  ret
 
+#endif /* !defined(HZ) */
+
 #if defined(I586_CPU) || defined(I686_CPU)
  .data
  .globl _C_LABEL(pentium_base_tsc)
  .comm _C_LABEL(pentium_base_tsc),8
  .text
+#endif
 
+#ifndef HZ
+#if defined(I586_CPU) || defined(I686_CPU)
  .align 2, 0x90
 pentium_microtime:
  pushfl
Index: i386/powernow-k7.c
===================================================================
RCS file: /cvs/src/sys/arch/i386/i386/powernow-k7.c,v
retrieving revision 1.9
diff -u -r1.9 powernow-k7.c
--- i386/powernow-k7.c 28 Nov 2005 17:48:02 -0000 1.9
+++ i386/powernow-k7.c 7 Jan 2006 18:56:40 -0000
@@ -367,7 +367,7 @@
  startvid = PN7_STA_SVID(status);
  currentfid = PN7_STA_CFID(status);
 
- CPU_CLOCKUPDATE();
+ PENTIUM_CLOCKUPDATE();
  cstate->fsb = pentium_base_tsc / 100000 / k7pnow_fid_to_mult[currentfid];
  /*
  * If start FID is different to max FID, then it is a
Index: i386/powernow-k8.c
===================================================================
RCS file: /cvs/src/sys/arch/i386/i386/powernow-k8.c,v
retrieving revision 1.3
diff -u -r1.3 powernow-k8.c
--- i386/powernow-k8.c 26 Nov 2005 11:22:12 -0000 1.3
+++ i386/powernow-k8.c 7 Jan 2006 18:56:40 -0000
@@ -398,7 +398,7 @@
  maxvid = PN8_STA_MVID(status);
  currentfid = PN8_STA_CFID(status);
 
- CPU_CLOCKUPDATE();
+ PENTIUM_CLOCKUPDATE();
  cstate->fsb = pentium_base_tsc/ 100000/ pn8_fid_to_mult[currentfid>>1];
 
  cstate->vid_to_volts = pn8_vid_to_volts;
Index: include/cpu.h
===================================================================
RCS file: /cvs/src/sys/arch/i386/include/cpu.h,v
retrieving revision 1.73
diff -u -r1.73 cpu.h
--- include/cpu.h 4 Nov 2005 06:55:36 -0000 1.73
+++ include/cpu.h 7 Jan 2006 18:56:41 -0000
@@ -252,9 +252,8 @@
  * High resolution clock support (Pentium only)
  */
 void calibrate_cyclecounter(void);
-#ifndef HZ
 extern u_quad_t pentium_base_tsc;
-#define CPU_CLOCKUPDATE() \
+#define PENTIUM_CLOCKUPDATE() \
  do { \
  if (pentium_mhz) { \
  __asm __volatile("cli\n" \
@@ -265,7 +264,10 @@
  } \
  } while (0)
 #endif
-#endif
+
+#ifndef HZ
+#define CPU_CLOCKUPDATE() PENTIUM_CLOCKUPDATE()
+#endif
 
 /*
  * pull in #defines for kinds of processors

Reply | Threaded
Open this post in threaded view
|

Re: fix for HZ != 100 on i386

gklok
This patch has been around for a while, it needs testing,
GWK

Index: src/sys/arch/i386/i386/powernow-k7.c
===================================================================
RCS file: /cvs/src/sys/arch/i386/i386/powernow-k7.c,v
retrieving revision 1.9
diff -u -r1.9 powernow-k7.c
--- src/sys/arch/i386/i386/powernow-k7.c 28 Nov 2005 17:48:02 -0000 1.9
+++ src/sys/arch/i386/i386/powernow-k7.c 7 Dec 2005 10:16:29 -0000
@@ -233,7 +233,7 @@
  if (cstate->errata_a0)
  enable_intr();
 
- pentium_mhz = ((cstate->state_table[i].freq / 100000)+1)*100;
+ pentium_mhz = cstate->state_table[i].freq;
 
  return 1;
 }
@@ -254,7 +254,7 @@
  for (n = 0, i = 0; i < npst; ++i) {
  state.fid = *p++;
  state.vid = *p++;
- state.freq = 100 * k7pnow_fid_to_mult[state.fid] * cstate->fsb;
+ state.freq = k7pnow_fid_to_mult[state.fid>>1] * cstate->fsb;
  if (cstate->errata_a0 &&
     (k7pnow_fid_to_mult[state.fid] % 10) == 5)
  continue;
@@ -309,20 +309,6 @@
 
  if (cpusig == pst->signature && fid == pst->fid
     && vid == pst->vid) {
- switch(pst->signature) {
- case 0x760:
- case 0x761:
- case 0x762:
- case 0x770:
- case 0x771:
- case 0x780:
- case 0x781:
- case 0x7a0:
- break;
- default:
- return 0;
- }
-
  if (abs(cstate->fsb - pst->fsb) > 5)
  continue;
  cstate->n_states = pst->n_states;
@@ -367,8 +353,7 @@
  startvid = PN7_STA_SVID(status);
  currentfid = PN7_STA_CFID(status);
 
- CPU_CLOCKUPDATE();
- cstate->fsb = pentium_base_tsc / 100000 / k7pnow_fid_to_mult[currentfid];
+ cstate->fsb = pentium_mhz / k7pnow_fid_to_mult[currentfid>>1];
  /*
  * If start FID is different to max FID, then it is a
  * mobile processor.  If not, it is a low powered desktop
@@ -388,7 +373,7 @@
  for(i = 0; i < cstate->n_states; i++) {
  state = &cstate->state_table[i];
  printf("%c%d", i==0 ? '(' : ',',
-    ((state->freq / 100000)+1)*100);
+    state->freq);
  }
  printf(")\n");
  k7pnow_current_state[cpu_number()] = cstate;
Index: src/sys/arch/i386/i386/powernow-k8.c
===================================================================
RCS file: /cvs/src/sys/arch/i386/i386/powernow-k8.c,v
retrieving revision 1.3
diff -u -r1.3 powernow-k8.c
--- src/sys/arch/i386/i386/powernow-k8.c 26 Nov 2005 11:22:12 -0000 1.3
+++ src/sys/arch/i386/i386/powernow-k8.c 7 Dec 2005 08:45:17 -0000
@@ -304,7 +304,7 @@
  if (cfid != fid || cvid != vid)
  return (1);
 
- pentium_mhz = ((cstate->state_table[i].freq / 100000)+1)*100;
+ pentium_mhz = cstate->state_table[i].freq;
  return (0);
 }
 
@@ -321,7 +321,7 @@
  state.fid = *p++;
  state.vid = *p++;
 
- state.freq = 100 * pn8_fid_to_mult[state.fid >>1] *cstate->fsb;
+ state.freq = pn8_fid_to_mult[state.fid >>1] *cstate->fsb;
  j = n;
  while (j > 0 && cstate->state_table[j - 1].freq > state.freq) {
  memcpy(&cstate->state_table[j],
@@ -398,8 +398,7 @@
  maxvid = PN8_STA_MVID(status);
  currentfid = PN8_STA_CFID(status);
 
- CPU_CLOCKUPDATE();
- cstate->fsb = pentium_base_tsc/ 100000/ pn8_fid_to_mult[currentfid>>1];
+ cstate->fsb = pentium_mhz / pn8_fid_to_mult[currentfid>>1];
 
  cstate->vid_to_volts = pn8_vid_to_volts;
  /*
@@ -419,7 +418,7 @@
  for(i= 0; i < cstate->n_states; i++) {
  state = &cstate->state_table[i];
  printf("%c%d", i==0 ? '(' : ',',
-    ((state->freq / 100000)+1)*100);
+    state->freq);
  }
  printf(")\n");
  k8pnow_current_state[cpu_number()] = cstate;

Reply | Threaded
Open this post in threaded view
|

Re: fix for HZ != 100 on i386

gklok
I appologize for replying to my own post,
please ignore that its wrong, if someone could test this on a K8 please I
would be very happy to see the dmesg, and md5 -t before and after, adjusting
setperf.

Index: src/sys/arch/i386/i386/powernow-k8.c
===================================================================
RCS file: /cvs/src/sys/arch/i386/i386/powernow-k8.c,v
retrieving revision 1.3
diff -u -r1.3 powernow-k8.c
--- src/sys/arch/i386/i386/powernow-k8.c 26 Nov 2005 11:22:12 -0000 1.3
+++ src/sys/arch/i386/i386/powernow-k8.c 8 Jan 2006 15:05:22 -0000
@@ -304,7 +304,7 @@
  if (cfid != fid || cvid != vid)
  return (1);
 
- pentium_mhz = ((cstate->state_table[i].freq / 100000)+1)*100;
+ pentium_mhz = cstate->state_table[i].freq;
  return (0);
 }
 
@@ -321,7 +321,7 @@
  state.fid = *p++;
  state.vid = *p++;
 
- state.freq = 100 * pn8_fid_to_mult[state.fid >>1] *cstate->fsb;
+ state.freq = pn8_fid_to_mult[state.fid] / 10 * cstate->fsb;
  j = n;
  while (j > 0 && cstate->state_table[j - 1].freq > state.freq) {
  memcpy(&cstate->state_table[j],
@@ -398,8 +398,7 @@
  maxvid = PN8_STA_MVID(status);
  currentfid = PN8_STA_CFID(status);
 
- CPU_CLOCKUPDATE();
- cstate->fsb = pentium_base_tsc/ 100000/ pn8_fid_to_mult[currentfid>>1];
+ cstate->fsb = pentium_mhz / (pn8_fid_to_mult[currentfid] / 10);
 
  cstate->vid_to_volts = pn8_vid_to_volts;
  /*
@@ -419,7 +418,7 @@
  for(i= 0; i < cstate->n_states; i++) {
  state = &cstate->state_table[i];
  printf("%c%d", i==0 ? '(' : ',',
-    ((state->freq / 100000)+1)*100);
+    state->freq);
  }
  printf(")\n");
  k8pnow_current_state[cpu_number()] = cstate;

Index: src/sys/arch/i386/i386/powernow-k7.c
===================================================================
RCS file: /cvs/src/sys/arch/i386/i386/powernow-k7.c,v
retrieving revision 1.9
diff -u -r1.9 powernow-k7.c
--- src/sys/arch/i386/i386/powernow-k7.c 28 Nov 2005 17:48:02 -0000 1.9
+++ src/sys/arch/i386/i386/powernow-k7.c 8 Jan 2006 15:10:54 -0000
@@ -233,7 +233,7 @@
  if (cstate->errata_a0)
  enable_intr();
 
- pentium_mhz = ((cstate->state_table[i].freq / 100000)+1)*100;
+ pentium_mhz = cstate->state_table[i].freq;
 
  return 1;
 }
@@ -254,7 +254,7 @@
  for (n = 0, i = 0; i < npst; ++i) {
  state.fid = *p++;
  state.vid = *p++;
- state.freq = 100 * k7pnow_fid_to_mult[state.fid] * cstate->fsb;
+ state.freq = k7pnow_fid_to_mult[state.fid] / 10 * cstate->fsb;
  if (cstate->errata_a0 &&
     (k7pnow_fid_to_mult[state.fid] % 10) == 5)
  continue;
@@ -309,20 +309,6 @@
 
  if (cpusig == pst->signature && fid == pst->fid
     && vid == pst->vid) {
- switch(pst->signature) {
- case 0x760:
- case 0x761:
- case 0x762:
- case 0x770:
- case 0x771:
- case 0x780:
- case 0x781:
- case 0x7a0:
- break;
- default:
- return 0;
- }
-
  if (abs(cstate->fsb - pst->fsb) > 5)
  continue;
  cstate->n_states = pst->n_states;
@@ -367,8 +353,7 @@
  startvid = PN7_STA_SVID(status);
  currentfid = PN7_STA_CFID(status);
 
- CPU_CLOCKUPDATE();
- cstate->fsb = pentium_base_tsc / 100000 / k7pnow_fid_to_mult[currentfid];
+ cstate->fsb = pentium_mhz / (k7pnow_fid_to_mult[currentfid] / 10);
  /*
  * If start FID is different to max FID, then it is a
  * mobile processor.  If not, it is a low powered desktop
@@ -388,7 +373,7 @@
  for(i = 0; i < cstate->n_states; i++) {
  state = &cstate->state_table[i];
  printf("%c%d", i==0 ? '(' : ',',
-    ((state->freq / 100000)+1)*100);
+    state->freq);
  }
  printf(")\n");
  k7pnow_current_state[cpu_number()] = cstate;

Reply | Threaded
Open this post in threaded view
|

Re: fix for HZ != 100 on i386

Ian Darwin
[hidden email] wrote:

>I appologize for replying to my own post,
>please ignore that its wrong, if someone could test this on a K8 please I
>would be very happy to see the dmesg, and md5 -t before and after, adjusting
>setperf.
>  
>
[Sent to the list because mail to sender is bouncing!]

See attached. CPU is an amd64 running with i386 kernel, so this may
or may not help you.

Ian
md5-after.txt
ian:1$ md5 -t
MD5 time trial.  Processing 10000 10000-byte blocks...
Digest = 52e5f9c9e6f656f3e1800dfa5579d089
Time   = 0.421685 seconds
Speed  = 237143839.595907 bytes/second
ian:2$ md5 -t
MD5 time trial.  Processing 10000 10000-byte blocks...
Digest = 52e5f9c9e6f656f3e1800dfa5579d089
Time   = 0.425493 seconds
Speed  = 235021492.715509 bytes/second
ian:3$ md5 -t
MD5 time trial.  Processing 10000 10000-byte blocks...
Digest = 52e5f9c9e6f656f3e1800dfa5579d089
Time   = 0.424876 seconds
Speed  = 235362788.201734 bytes/second
ian:4$

Script done on Sun Jan  8 12:28:08 2006
md5-before.txt
ian:1$ md5 -t
MD5 time trial.  Processing 10000 10000-byte blocks...
Digest = 52e5f9c9e6f656f3e1800dfa5579d089
Time   = 0.424790 seconds
Speed  = 235410438.098825 bytes/second
ian:2$ md5 -t
MD5 time trial.  Processing 10000 10000-byte blocks...
Digest = 52e5f9c9e6f656f3e1800dfa5579d089
Time   = 0.425735 seconds
Speed  = 234887899.749844 bytes/second
ian:3$ md5 -t
MD5 time trial.  Processing 10000 10000-byte blocks...
Digest = 52e5f9c9e6f656f3e1800dfa5579d089
Time   = 0.425550 seconds
Speed  = 234990012.924451 bytes/second
ian:4$

Script done on Sun Jan  8 12:19:38 2006
OpenBSD 3.8-current (DAROAD) #63: Sun Jan  8 12:18:51 EST 2006
    rootatdaroad.darwinsys.com:/usr/src/sys/arch/i386/compile/DAROAD
cpu0: AMD Athlon(tm) 64 Processor 3500+ ("AuthenticAMD" 686-class, 512KB L2 cache) 2.19 GHz
cpu0: FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,MMX,FXSR,SSE,SSE2
cpu0: AMD Powernow: TS FID VID TTP
cpu0: AMD Cool`n'Quiet K8 available states (726,1694,1936,2178)
real mem  = 1072209920 (1047080K)
avail mem = 971726848 (948952K)
using 4278 buffers containing 53714944 bytes (52456K) of memory
mainbus0 (root)
bios0 at mainbus0: AT/286+(49) BIOS, date 03/22/05, BIOS32 rev. 0 @ 0xfd5f0
bios0: ROM list: 0xc0000/0xf000 0xd0000/0x6000! 0xd8000/0x1000 0xdf800/0x800!
cpu0 at mainbus0
pci0 at mainbus0 bus 0: configuration mode 1 (no bios)
pchb0 at pci0 dev 0 function 0 "ATI RS480 Host" rev 0x00
ppb0 at pci0 dev 1 function 0 "ATI RS480 PCIE" rev 0x00
pci1 at ppb0 bus 1
vga1 at pci1 dev 5 function 0 "ATI Radeon XPRESS 200M" rev 0x00
wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation)
wsdisplay0: screen 1-5 added (80x25, vt100 emulation)
vendor "ATI", unknown product 0x5a36 (class bridge subclass PCI, rev 0x00) at pci0 dev 4 function 0 not configured
ohci0 at pci0 dev 19 function 0 "ATI IXP400 USB" rev 0x00: irq 11, version 1.0, legacy support
usb0 at ohci0: USB revision 1.0
uhub0 at usb0
uhub0: ATI OHCI root hub, rev 1.00/1.00, addr 1
uhub0: 4 ports with 4 removable, self powered
ohci1 at pci0 dev 19 function 1 "ATI IXP400 USB" rev 0x00: irq 11, version 1.0, legacy support
usb1 at ohci1: USB revision 1.0
uhub1 at usb1
uhub1: ATI OHCI root hub, rev 1.00/1.00, addr 1
uhub1: 4 ports with 4 removable, self powered
ehci0 at pci0 dev 19 function 2 "ATI IXP400 USB2" rev 0x00: irq 11
usb2 at ehci0: USB revision 2.0
uhub2 at usb2
uhub2: ATI EHCI root hub, rev 2.00/1.00, addr 1
uhub2: 8 ports with 8 removable, self powered
"ATI IXP400 SMBus" rev 0x10 at pci0 dev 20 function 0 not configured
pciide0 at pci0 dev 20 function 1 "ATI IXP400 IDE" rev 0x00: DMA, channel 0 configured to compatibility, channel 1 configured to compatibility
wd0 at pciide0 channel 0 drive 0: <ST9808211A>
wd0: 16-sector PIO, LBA48, 76319MB, 156301488 sectors
wd0(pciide0:0:0): using PIO mode 4, DMA mode 2, Ultra-DMA mode 5
atapiscsi0 at pciide0 channel 1 drive 0
scsibus0 at atapiscsi0: 2 targets
cd0 at scsibus0 targ 0 lun 0: <HL-DT-ST, DVD-RW GCA-4080N, 0C35> SCSI0 5/cdrom removable
cd0(pciide0:1:0): using PIO mode 4, DMA mode 2
pcib0 at pci0 dev 20 function 3 "ATI IXP400 ISA" rev 0x00
ppb1 at pci0 dev 20 function 4 "ATI IXP400 PCI" rev 0x00
pci2 at ppb1 bus 3
"Texas Instruments TSB43AB22 FireWire" rev 0x00 at pci2 dev 0 function 0 not configured
"Broadcom BCM4306" rev 0x03 at pci2 dev 2 function 0 not configured
cbb0 at pci2 dev 4 function 0 "Texas Instruments PCI7XX1 CardBus" rev 0x00pci_intr_map: no mapping for pin A
: couldn't map interrupt
"Texas Instruments PCI7XX1 Flash" rev 0x00 at pci2 dev 4 function 3 not configured
"Texas Instruments PCI7XX1 Secure Data" rev 0x00 at pci2 dev 4 function 4 not configured
rl0 at pci2 dev 6 function 0 "Realtek 8139" rev 0x10: irq 10, address 00:0f:b0:70:1c:ef
rlphy0 at rl0 phy 0: RTL internal phy
auixp0 at pci0 dev 20 function 5 "ATI IXP400 AC97" rev 0x01: irq 10
auixp0: soft resetting aclink
"ATI IXP400 Modem" rev 0x01 at pci0 dev 20 function 6 not configured
pchb1 at pci0 dev 24 function 0 "AMD AMD64 HyperTransport" rev 0x00
pchb2 at pci0 dev 24 function 1 "AMD AMD64 Address Map" rev 0x00
pchb3 at pci0 dev 24 function 2 "AMD AMD64 DRAM Cfg" rev 0x00
pchb4 at pci0 dev 24 function 3 "AMD AMD64 Misc Cfg" rev 0x00
isa0 at pcib0
isadma0 at isa0
pckbc0 at isa0 port 0x60/5
pckbd0 at pckbc0 (kbd slot)
pckbc0: using irq 1 for kbd slot
wskbd0 at pckbd0: console keyboard, using wsdisplay0
pmsi0 at pckbc0 (aux slot)
pckbc0: using irq 12 for aux slot
wsmouse0 at pmsi0 mux 0
pcppi0 at isa0 port 0x61
midi0 at pcppi0: <PC speaker>
spkr0 at pcppi0
sysbeep0 at pcppi0
npx0 at isa0 port 0xf0/16: using exception 16
biomask ebfd netmask effd ttymask ffff
pctr: user-level cycle counter enabled
uhub3 at uhub0 port 2
uhub3: ALCOR Generic USB Hub, rev 1.10/3.12, addr 2
uhub3: 4 ports with 4 removable, self powered
umass0 at uhub3 port 3 configuration 1 interface 0
umass0: ICneric USB Storage Device, rev 1.10/1.00, addr 3
umass0: using SCSI over Bulk-Only
scsibus1 at umass0: 2 targets
sd0 at scsibus1 targ 1 lun 0: <IC, USB Storage-SMC, 322E> SCSI0 0/direct removable
sd0: drive offline
sd1 at scsibus1 targ 1 lun 1: <IC, USB Storage-SMC, 322E> SCSI0 0/direct removable
sd1: drive offline
sd2 at scsibus1 targ 1 lun 2: <IC, USB Storage-MMC, 322E> SCSI0 0/direct removable
sd2: drive offline
sd3 at scsibus1 targ 1 lun 3: <IC, USB Storage-MSC, 322E> SCSI0 0/direct removable
sd3: drive offline
uhidev0 at uhub3 port 4 configuration 1 interface 0
uhidev0: Logitech USB-PS/2 Optical Mouse, rev 2.00/11.00, addr 4, iclass 3/1
ums0 at uhidev0: 3 buttons and Z dir.
wsmouse1 at ums0 mux 0
dkcsum: wd0 matches BIOS drive 0x80
sd0(umass0:1:0): Check Condition (error 0x70) on opcode 0x1e
    SENSE KEY: Not Ready
     ASC/ASCQ: Medium Not Present
sd1(umass0:1:1): Check Condition (error 0x70) on opcode 0x1e
    SENSE KEY: Not Ready
     ASC/ASCQ: Medium Not Present
sd2(umass0:1:2): Check Condition (error 0x70) on opcode 0x1e
    SENSE KEY: Not Ready
     ASC/ASCQ: Medium Not Present
sd3(umass0:1:3): Check Condition (error 0x70) on opcode 0x1e
    SENSE KEY: Not Ready
     ASC/ASCQ: Medium Not Present
root on wd0a
rootdev=0x0 rrootdev=0x300 rawdev=0x302
ac97: codec id 0x43585430 (Conexant CX?????)
ac97: codec features reserved, headphone, 18 bit DAC, 18 bit ADC, No 3D Stereo
audio0 at auixp0

Reply | Threaded
Open this post in threaded view
|

Re: fix for HZ != 100 on i386

Alexandre Ratchov
In reply to this post by gklok
On Sun, Jan 08, 2006 at 10:30:47AM -0500, [hidden email] wrote:
> I appologize for replying to my own post,
> please ignore that its wrong, if someone could test this on a K8 please I
> would be very happy to see the dmesg, and md5 -t before and after, adjusting
> setperf.
>

hello,

i don't own the appropriate hardware to test setperf adjusting,
however i tried your patch on various cpus (amd-athlon, intel pentium,
pentium III) and it solves my problems related to HZ != 100.

thanks,

--
Alexandre