Hello all,
after searcing the XFree 4.0.1 sources i found the following piece of
code in /xc/programs/Xserver/hw/xfree86/os-support/linux/lnx_video.c
(and simmulair for other OS's)
When i understand the working of RTAI(and RTLinux) correct the direct
cli/sti functions are offlimit
for anything but the actual RT-code. Did anybody ran into problems with
XFree 4.0.1 on RT-Linux ?
I will try to recompile the server with soft cli/sti and see if that
works.(i compiled it first
on a normal jkernel and that ran OK (appart from the high latency) and i
compiled it on a RT-kernel
and than it just crashed my machine, when using RT-tasks. If i get it
right it will mean one needs to make RT-Linux XFree-4.0.1 versions ,
which would suck :-/ Are there simulair problems with XFree 3.XXX ?
/***************************************************************************/
/* Interrupt Handling
section */
/***************************************************************************/
Bool
xf86DisableInterrupts()
{
if (!ExtendedEnabled)
#if !defined(__mc68000__) && !defined(__powerpc__) &&
!defined(__sparc__) && !defined(__mips__)
if (iopl(3) || ioperm(0, 1024, 1))
return (FALSE);
#endif
#if defined(__alpha__) || defined(__mc68000__) || defined(__powerpc__)
|| defined(__sparc__) || defined(__mips__)
#else
#ifdef __GNUC__
#if defined(__ia64__)
__asm__ __volatile__ (";; rsm psr.i;; srlz.d" ::: "memory");
#else
__asm__ __volatile__("cli");
#endif
#else
asm("cli");
#endif
#endif
#if !defined(__mc68000__) && !defined(__powerpc__) &&
!defined(__sparc__) && !defined(__mips__)
if (!ExtendedEnabled) {
iopl(0);
ioperm(0, 1024, 0);
}
#endif
return (TRUE);
}
void
xf86EnableInterrupts()
{
if (!ExtendedEnabled)
#if !defined(__mc68000__) && !defined(__powerpc__) &&
!defined(__sparc__) && !defined(__mips__)
if (iopl(3) || ioperm(0, 1024, 1))
return;
#endif
#if defined(__alpha__) || defined(__mc68000__) || defined(__powerpc__)
|| defined(__sparc__) || defined(__mips__)
#else
#ifdef __GNUC__
#if defined(__ia64__)
__asm__ __volatile__ (";; ssm psr.i;; srlz.d" ::: "memory");
#else
__asm__ __volatile__("sti");
#endif
#else
asm("sti");
#endif
#endif
#if !defined(__mc68000__) && !defined(__powerpc__) &&
!defined(__sparc__) && !defined(__mips__)
if (!ExtendedEnabled) {
iopl(0);
ioperm(0, 1024, 0);
}
#endif
return;
}
Erwin Rol wrote:
>
> Hello RTAI'ers,
>
> I tried lxrt with RTAI-1.5 on 2.2.16 and found that the latency was
> rather high when i did something with the
> X-Server , like moving windows. So i though oh well it is lxrt , can't
> expect extern low latency with that
> so i ran the lateny test in
> /usr/src/rtai-1.5/examples/latency_calibration and found out it had the
> same problem.
>
> Here is what i did:
> 1) compiled all the stuff
> 2) maximized a gnome-termnial 1.2.4
> 3) ran the test in the window
> 4) everything fine max of about 15 usec
> 5) put an other gnometerm half over it
> 6) bang the max jumps to 15msec
> 7) removed the other term again and it drops to 15usec again
> 8) tried to remove the ONE_SHOT define in the test , but that had no
> effect
> 9) when pressing enter durring the test there is a jump too
>
> Now my question is: what am i doing wrong, or it this behavior correct
> :-) ?
>
> TIA,
> Erwin
>
> My system:
> ASUS AV7 (VIA KT133 chipset)
> Athlon TB 800MHz
> Infinion PC133 128MB DIMM
> Haupauge WinTV card (module not loaded)
> Dawicontrol (DC 2975U) SCSI controler (only for CD-rom and scanner)
> HD IBM-DJNA-371350
> NIC VIA chipset (dunno the cardbrand)
> G-card: S3 Inc. ViRGE/DX or /GX (rev 1).
> (see proc/pci below)
>
> Software:
> Kernel 2.2.16
> RTAI 1.5
> XFree 4.0.1
> updated RH 6.2 install
> compiler egcs-2.91.66
> glibc 2.1.3
> modutils 2.3.17
>
> kernel output of calibration:
> Nov 19 12:41:53 rawpower kernel: ***** STARTING THE REAL TIME UP
> SCHEDULER WITH NO LINUX *****
> Nov 19 12:41:53 rawpower kernel: ***** FP SUPPORT AND READY FOR A
> PERIODIC TIMER *****
> Nov 19 12:41:53 rawpower kernel: ***<> LINUX TICK AT 100 (HZ) <>***
> Nov 19 12:41:53 rawpower kernel: ***<> CALIBRATED CPU FREQUENCY
> 807213000 (HZ) <>***
> Nov 19 12:41:53 rawpower kernel: ***<> CALIBRATED
> 8254-TIMER-INTERRUPT-TO-SCHEDULER LATENCY 3171 (ns) <>***
> Nov 19 12:41:53 rawpower kernel: ***<> CALIBRATED ONE SHOT SETUP TIME
> 2828 (ns) <>***
>
> Here a print out of the test:
>
> *** min: -743, max: 4871 average: 640 ***
> *** min: -839, max: 7863 average: 639 ***
> *** min: -835, max: 7400 average: 496 ***
> *** min: -716, max: 7767 average: 488 ***
> *** min: -798, max: 7282 average: 514 ***
> *** min: -816, max: 9258 average: 517 ***
> *** min: -749, max: 10473 average: 524 ***
> *** min: -697, max: 11074 average: 553 ***
> *** min: -816, max: 11100 average: 534 ***
> *** min: -649, max: 11973 average: 534 ***
> *** min: -894, max: 4207901 average: 23581 *** <------ put
> a other Xterm over the out put window
> *** min: -742, max: 15357958 average: 297999 ***
> *** min: -854, max: 15300465 average: 295876 ***
> *** min: -891, max: 14982212 average: 284012 ***
> *** min: -824, max: 14912340 average: 281128 ***
> *** min: -452, max: 15320521 average: 296448 ***
> *** min: -653, max: 15273939 average: 294638 ***
> *** min: -586, max: 15296113 average: 295528 ***
> *** min: -850, max: 15317780 average: 296337 ***
> *** min: -398, max: 15321168 average: 296461 ***
> *** min: -645, max: 15306613 average: 296006 ***
> *** min: -824, max: 15301681 average: 295769 ***
> *** min: -5151, max: 15260932 average: 294135 ***
> *** min: -590, max: 15112233 average: 288549 ***
> *** min: -642, max: 14919694 average: 281243 ***
> *** min: -406, max: 14676508 average: 272180 ***
> *** min: -701, max: 14391389 average: 261751 ***
> *** min: -545, max: 14332357 average: 259660 ***
> *** min: -5796, max: 14362163 average: 260682 ***
> *** min: -530, max: 14577379 average: 268495 ***
> *** min: -2460, max: 14764780 average: 275409 ***
> *** min: -768, max: 15343923 average: 297346 ***
> *** min: -850, max: 181432 average: 690 *** <-----
> removed it again
> *** min: -861, max: 10618 average: 463 ***
> *** min: -816, max: 10887 average: 472 ***
> *** min: -716, max: 9535 average: 508 ***
> *** min: -697, max: 8129 average: 492 ***
>
> *** min: -894, max: 44331561 average: 320511 *** <----- after one
> press on the return key
> *** min: -735, max: 5448 average: 457 ***
> *** min: -909, max: 7268 average: 456 ***
>
> *** min: -846, max: 44267793 average: 313418 *** <--- and again
> *** min: -854, max: 10798 average: 465 ***
> *** min: -790, max: 10415 average: 463 ***
>
> /proc/pci
>
> PCI devices found:
> Bus 0, device 0, function 0:
> Host bridge: VIA Technologies Unknown device (rev 2).
> Vendor id=1106. Device id=305.
> Medium devsel. Master Capable. No bursts.
> Prefetchable 32 bit memory at 0xe0000000 [0xe0000008].
> Bus 0, device 1, function 0:
> PCI bridge: VIA Technologies Unknown device (rev 0).
> Vendor id=1106. Device id=8305.
> Medium devsel. Master Capable. No bursts.
> Bus 0, device 4, function 0:
> ISA bridge: VIA Technologies Unknown device (rev 34).
> Vendor id=1106. Device id=686.
> Medium devsel. Master Capable. No bursts.
> Bus 0, device 4, function 1:
> IDE interface: VIA Technologies VT 82C586 Apollo IDE (rev 16).
> Medium devsel. Fast back-to-back capable. Master Capable.
> Latency=32.
> I/O at 0xd800 [0xd801].
> Bus 0, device 4, function 2:
> USB Controller: VIA Technologies VT 82C586 Apollo USB (rev 16).
> Medium devsel. IRQ 15. Master Capable. Latency=32.
> I/O at 0xd400 [0xd401].
> Bus 0, device 4, function 3:
> USB Controller: VIA Technologies VT 82C586 Apollo USB (rev 16).
> Medium devsel. IRQ 15. Master Capable. Latency=32.
> I/O at 0xd000 [0xd001].
> Bus 0, device 4, function 4:
> Host bridge: VIA Technologies Unknown device (rev 48).
> Vendor id=1106. Device id=3057.
> Medium devsel. Fast back-to-back capable.
> Bus 0, device 9, function 0:
> Ethernet controller: VIA Technologies Unknown device (rev 6).
> Vendor id=1106. Device id=3043.
> Medium devsel. IRQ 15. Master Capable. Latency=64. Min
> Gnt=118.Max Lat=152.
> I/O at 0xa400 [0xa401].
> Non-prefetchable 32 bit memory at 0xdd800000 [0xdd800000].
> Bus 0, device 11, function 0:
> Multimedia video controller: Brooktree Bt878 2nd Contr. (?) (rev 2).
> Medium devsel. Fast back-to-back capable. IRQ 10. Master
> Capable. Latency=32. Min Gnt=16.Max Lat=40.
> Prefetchable 32 bit memory at 0xdf000000 [0xdf000008].
> Bus 0, device 11, function 1:
> Multimedia controller: Brooktree Bt878 (rev 2).
> Medium devsel. Fast back-to-back capable. IRQ 10. Master
> Capable. Latency=32. Min Gnt=4.Max Lat=255.
> Prefetchable 32 bit memory at 0xde800000 [0xde800008].
> Bus 0, device 12, function 0:
> VGA compatible controller: S3 Inc. ViRGE/DX or /GX (rev 1).
> Medium devsel. IRQ 5. Master Capable. Latency=32. Min
> Gnt=4.Max Lat=255.
> Non-prefetchable 32 bit memory at 0xd8000000 [0xd8000000].
> Bus 0, device 13, function 0:
> SCSI storage controller: NCR 53c875 (rev 38).
> Medium devsel. IRQ 15. Master Capable. Latency=134. Min
> Gnt=17.Max Lat=64.
> I/O at 0xa000 [0xa001].
> Non-prefetchable 32 bit memory at 0xd7800000 [0xd7800000].
> Non-prefetchable 32 bit memory at 0xd7000000 [0xd7000000].
> Bus 0, device 17, function 0:
> Unknown mass storage controller: Promise Technology Unknown device
> (rev 2).
> Vendor id=105a. Device id=d30.
> Medium devsel. IRQ 10. Master Capable. Latency=32.
> I/O at 0x9800 [0x9801].
> I/O at 0x9400 [0x9401].
> I/O at 0x9000 [0x9001].
> I/O at 0x8800 [0x8801].
> I/O at 0x8400 [0x8401].
> Non-prefetchable 32 bit memory at 0xd6800000 [0xd6800000].
>
> /proc/cpuinfo
> processor : 0
> vendor_id : AuthenticAMD
> cpu family : 6
> model : 4
> model name : AMD Athlon(tm) Processor
> stepping : 2
> cpu MHz : 807.213
> cache size : 256 KB
> fdiv_bug : no
> hlt_bug : no
> sep_bug : no
> f00f_bug : no
> coma_bug : no
> fpu : yes
> fpu_exception : yes
> cpuid level : 1
> wp : yes
> flags : fpu vme de pse tsc msr 6 mce cx8 sep mtrr pge 14 cmov
> fcmov 17 psn 22 mmx 24 30 3dnow
> bogomips : 1612.19
> -- [rtl] ---
> To unsubscribe:
> echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
> echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
> ---
> For more information on Real-Time Linux see:
> http://www.rtlinux.org/rtlinux/
-- [rtl] ---
To unsubscribe:
echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
---
For more information on Real-Time Linux see:
http://www.rtlinux.org/rtlinux/