[rtl] Crash of Computer
Hi, all: I'm developing a real application, which the system crash is never expected. I often encounter the crash during the development of RT application, but this day i found a strange problem: If i insert the rt module after the system running for a long time (without rt application running), the system is crashed. Then I reboot the system and insert that, there is no problem. It seems the rt module need a clean memory enviroment (i.e. after a long uptime, the system's mem is not so orderly). So what i want to know is does anyone have a suggestion about the situation we should avoid in kernel programming, especially in real time module programming, such as the mem allocation, etc. I think this will increase the stability of the RT system based on RT-Linux. Thanks in advance. Zhixu Liu -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/rtlinux/
Re: [rtl] Re: your mail
Hi, thanks for your reply. I have use ioremap realize the share memory in rt kernel. Anyway, I think it's better to use ioremap in kernel mode, since we can visit the physics directly. (see /usr/src/linux/Documentation/IO-mapping.txt) Zhixu Liu -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/rtlinux/
No Subject
Hi, everyone: I have a question about the share memory use mmap. (in rtlinux-2.2) I use the example in mmap, but what i want to know is is there is a limit of the size of share memory, for when i try to map a region about 1000 int, in the kernel module the computer always dead. Following is the program i use. === #include #include #include #include //DATA * start; int *start; size_t length = 1000; #define BASE_ADDRESS (96*0x10) //96Mb I have reserve the left 32Mb in lilo.conf int init_module(void ) { int i; int fd = open("/dev/mem", O_RDWR); if (fd < 0) { rtl_printf("failed to open /dev/mem\n"); return -1; } start = (int *)mmap(0,length*sizeof(int),PROT_READ|PROT_WRITE, MAP_SHARED,fd,BASE_ADDRESS); if (start == (int *) -1) { rtl_printf("failed to map /dev/mem\n"); return -1; } rtl_printf("%p\n",start); for (i = 0; i < 1000; i++) { rtl_printf ("%d\t",i); start[i]=i; rtl_printf ("%d\n", start[i]); } return 0; } void cleanup_module(void ) { munmap(start, length); } #ifndef MODULE int main(void) { if (init_module() == 0) { cleanup_module(); } return 0; } #endif === If i run this program in module, then the computer is dead. If i run in user program, it's ok. Anyone have some some suggestion about this? Thanks in anvance. Zhixu Liu -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/rtlinux/
[rtl] About interrupt routine
Hi, everyone: Can i use following functions in real time driver? interruptible_sleep_on_timeout wake_up_interruptible cli Zhixu Liu ¬¬ EMail: [EMAIL PROTECTED] Tel: 010-68236046 -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/rtlinux/
No Subject
Hi, everyone: I'm use linux2.2.14+rtlinux2.2 with only one CPU. I'm trying to write a rt_driver for my camac 2915 pci device, first i just realize a open and a close interface (both only print out a open or close message). In my init_module, i use some pci routine to get the parameter of the 2915, print out. i use rtl_register_chrdev to register the rtdriver, then when i try to open the device in my another module, it just fail. Attach with the driver, can anyone give me some advice. Thanks in anvance. Zhixu Liu ¬¬ EMail: [EMAIL PROTECTED] test
[rtl] Bus Frenquency
After install thr rtai, i found there is no bus frequency when i type dmesg, the configuration of my PC is: Dell OptiPlex GX1 with PIII 500, UP. No APIC ( What's APIC?) And when i run latency_callibration, the data display are all <0. What is this mean? Thanks very much. Zhixu Liu ¬¬ EMail: [EMAIL PROTECTED] Tel: 010-68236046 -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/~rtlinux/
[rtl] RTAI and rtlinux
What's the difference between RTAI and rtlinux (FSM Lab.)? Zhixu -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/~rtlinux/
[rtl] Interrupt Driven RT Task
Hi, everyone: I have seen the example of RT task, and found they are almost timer driven, but i want my rt task interrupt driven, for the interrupt is not periodic, does anyone have some idea about this. I don't know if i register the interrupt handler in the diver, does it mean whenever there is a interrupt, the driver will response it? If so, how can i active my rt task? Thanks. Zhixu ¬¬ EMail: [EMAIL PROTECTED] -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/~rtlinux/
Re: [rtl] How to use the Real-Time interrupt?
I have looked the example of rt_com, but it need to modify the driver, this is not easy, i want to know whether there is some method which i needn't modify the driver, or just do a little patch to the driver. ¬¬ EMail: [EMAIL PROTECTED] Tel: 8610-68236046 On Sun, 12 Mar 2000, Tomasz Motylewski wrote: > On Sun, 12 Mar 2000, Zhixu Liu wrote: > > > I'm working on a realtime DAQ system. I want my realtime task work whenever > > the hardware generate a interrupt, then i can read the data into computer, > > so i want know how to intergerate this realtime interrupt to the realtime > > task, for the driver of the hardware has realize the interrupt, i don't > > know whether i should change the driver's interrupt routine. It's best > > someone can give a example of the program or a framework. > > You just need to register your interrupt handler function as real time > handler. I guess you will not need to define real time tasks - RT tasks are > timer driven. > > I hope someone will send some examples, if not, write me again, I will try to > find some. > > -- > Tomek > > -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/~rtlinux/
[rtl] How to use the Real-Time interrupt?
Hi, everyone: I'm working on a realtime DAQ system. I want my realtime task work whenever the hardware generate a interrupt, then i can read the data into computer, so i want know how to intergerate this realtime interrupt to the realtime task, for the driver of the hardware has realize the interrupt, i don't know whether i should change the driver's interrupt routine. It's best someone can give a example of the program or a framework. Thanks in advance. Zhixu Liu Email: [EMAIL PROTECTED] -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/~rtlinux/
Re: [rtl] About interrupt
On Fri, 25 Feb 2000, Michael Barabanov wrote: > Zhixu Liu ([EMAIL PROTECTED]) wrote: > > Hi, everyone: > > > > I am working on a DAQ with CAMAC, and i prepare to put the task of get > > the data from CAMAC crate into a real time task. > > > > The drive of my camac carte controller 3922 with PCI 2915 was written, > > and it has realize the interrupt (in normal linux), and now i want the real > > time task will work only after a interrupt of the camac. What should i do > > to associate this interrupt with the real time task. > > > > What's the meaning of rtl_request_irq(...)? > > You should use rtl_request_irq. It installs an interrupt handler > for the given irq. There is a manual page for this function > in the man/man3 directory. I also suggest you read the GettingStarted.txt > file and the FAQ. > Does it mean i should change the driver of 2915, for the original driver of 2915 have a interrupt handler, should i replace it with rtl_request_irq(...)? Thanks a lot. > Michael. > -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/~rtlinux/
[rtl] About rtl2.2
Does anyone install the rtl2.2 for linux 2.2.14. I download it, but find it without the option of hard real time support when i try to compile the kernel. What's wrong with the kernelpatch? Zhixu Liu -- E_Mail: [EMAIL PROTECTED] -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/~rtlinux/
[rtl] About interrupt
Hi, everyone: I am working on a DAQ with CAMAC, and i prepare to put the task of get the data from CAMAC crate into a real time task. The drive of my camac carte controller 3922 with PCI 2915 was written, and it has realize the interrupt (in normal linux), and now i want the real time task will work only after a interrupt of the camac. What should i do to associate this interrupt with the real time task. What's the meaning of rtl_request_irq(...)? Thanks. Zhixu Liu -- E_Mail: [EMAIL PROTECTED] -- [rtl] --- To unsubscribe: echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR echo "unsubscribe rtl " | mail [EMAIL PROTECTED] --- For more information on Real-Time Linux see: http://www.rtlinux.org/~rtlinux/