Re: [rtl] Memory mapped IO (fwd)
This I have tried already, so I was in the right direction. I have read the IO-mapping.txt, but when I use ioremap, the code does not compile anymore. As soon as I include asm/io.h, I get several pages of warnings, mentioning all kind of header files. I have seen in the code of another driver that they use -I/usr/src/linux/include in the Makefile. When I do that, it compiles OK, but insmod tells unresolved symbol ioremap. I think the way I make the code is wrong. Bas Benschop Faculty of Applied Physics University of Twente The Netherlands Use ioremap(physical_address) Read /usr/src/linux/Documentation/IO-mapping.txt Read other Linux PCI drivers code. Best regards, -- Tomek On Mon, 4 Sep 2000, Bas Benschop wrote: Maybe this question is off-topic, but I'm quite new in both rtl and C-programming. I have a SBS-greenspring carrier board with an DAC module. This board is completely memory mapped. I can get the memory location it uses with the pci functions, but when I try to look at this location I get a segmentation fault. So I need a function to tell the kernel that I want so much memory at that location. How to do such a thing? -- [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/
Re: [rtl] Memory mapped IO
Bas Benschop wrote: Maybe this question is off-topic, but I'm quite new in both rtl and C-programming. I have a SBS-greenspring carrier board with an DAC module. This board is completely memory mapped. I can get the memory location it uses with the pci functions, but when I try to look at this location I get a segmentation fault. So I need a function to tell the kernel that I want so much memory at that location. How to do such a thing? depending on the io or memory space : use ioremap or request_region for more information, look at IO-mapping and PCI doc files in the /usr/src/linux/Documentation directory bye Thanks in advance, Bas Benschop Faculty of Applied Physics University of Twente The Netherlands -- [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/
[rtl] task suspended ?
Hoi ! Is there any chance to find out wether a task is suspended with pthread_suspend_np ? My problem is, that I have a queue emptying thread, which sould be suspend itself when the queue is empty, and started again for a periodic time until the queue ist empty again. The startup should be done from outside the task. blue skies Jan -- -- Jan Christian Albiez -- -- FZI -- Haid-und-Neu-Str. 10-14 -- 76131 Karlsruhe -- +49 721 9654 206 -- -- segmentation violation in module reality.o ... ... please shutdown your universe and reboot -- -- [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/
Re: [rtl] RTAI and RTLinux
Tue, 05 Sep 2000 [EMAIL PROTECTED] wrote: Let's say I have N message buffers in a pool. What if there is no more free buffer? Then the design for your hard real time system was wrong :-) Or system reached its limits. Yep, and the only options are a) redesign and b) upgrading the hardware. It depends on your possibilities and intentions. What if amount of incoming data is unpredictable but you have to process at most as you can with a limited hardware? That's a kind of *soft* real time system, which is not really what RTL is intended for. (Although the input-"some kind of output" latency could have a hard RT requirement - but the memory allocation would still be soft RT.) You can't optimize a single API for both hard and soft RT, at least not without making it a major PITA to use if you want hard RT, so IMHO, it's a very good idea not to mix these two kinds of systems up when discussing APIs. (The general problem of soft RT capable systems is that the dynamic allocation and other stuff they provide makes it virtually impossible to write hard RT applications, even if the kernel theoretically could provide the required timing guarantees.) Then one can choice a stragegy of survival: throw away unprocessable data and do some clever. (Plan B: crash and reboot. ;-) Well, with some systems, plan B and the "stragegy of survival" both actually give the same result as plan C: miss a deadline and wreck some very expensive machinery... This basically applies to all control systems dealing with powerful and/or sensitive machines, and particularly in situations where people may get hurt or killed if the machines freak out. I'd say that a thoroughly tested RTL solution could be appropriate at least for the less critical systems in this range, but that doesn't go for *any* kind of soft RT system - and anything that shares resources with non RT tasks in a similar way to a shared memory pool is actually a soft RT system. David Olofson Programmer Reologica Instruments AB [EMAIL PROTECTED] ..- M u C o S . .- David Olofson --. | A Free/Open Multimedia | | Audio Hacker | | Plugin and Integration Standard | |Linux Advocate| ` http://www.linuxdj.com/mucos -' | Open Source Advocate | ..- A u d i a l i t y . |Singer| | Rock Solid Low Latency Signal Processing | | Songwriter | `--- http://www.angelfire.com/or/audiality -' `- [EMAIL PROTECTED] -' -- [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/
Re: [rtl] task suspended ?
You can send a wakeup signal. This will have no effect if the thread is already awake. On Tue, Sep 05, 2000 at 02:58:19PM +0200, Jan Albiez wrote: Hoi ! Is there any chance to find out wether a task is suspended with pthread_suspend_np ? My problem is, that I have a queue emptying thread, which sould be suspend itself when the queue is empty, and started again for a periodic time until the queue ist empty again. The startup should be done from outside the task. blue skies Jan -- -- Jan Christian Albiez -- -- FZI -- Haid-und-Neu-Str. 10-14 -- 76131 Karlsruhe -- +49 721 9654 206 -- -- segmentation violation in module reality.o ... ... please shutdown your universe and reboot -- -- [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/ -- - Victor Yodaiken Finite State Machine Labs: The RTLinux Company. www.fsmlabs.com www.rtlinux.com -- [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/
Re: [rtl] RTAI and RTLinux
On Tue, Sep 05, 2000 at 05:05:56PM +0200, David Olofson wrote: Tue, 05 Sep 2000 [EMAIL PROTECTED] wrote: Let's say I have N message buffers in a pool. What if there is no more free buffer? Then the design for your hard real time system was wrong :-) Or system reached its limits. Yep, and the only options are a) redesign and b) upgrading the hardware. It depends on your possibilities and intentions. What if amount of incoming data is unpredictable but you have to process at most as you can with a limited hardware? That's a kind of *soft* real time system, which is not really what RTL is intended for. (Although the input-"some kind of output" latency could have a hard RT requirement - but the memory allocation would still be soft RT.) You can't optimize a single API for both hard and soft RT, at least not without making it a major PITA to use if you want hard RT, so IMHO, it's a very good idea not to mix these two kinds of systems up when discussing APIs. I don't think that "running out of memory" and "running out of CPU time" are fundamentally different things. It's just that with a memory allocator, you are notified of a lack of resources and can do something graceful instead of locking the machine. dave... -- [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/
Re: [rtl] RTAI and RTLinux
On Tue, Sep 05, 2000 at 10:18:25AM -0700, David Schleef wrote: I don't think that "running out of memory" and "running out of CPU time" are fundamentally different things. It's just that with a memory allocator, you are notified of a lack of resources and can do something graceful instead of locking the machine. Sure. But I think there is a significant difference between: 1. At startup time, allocate N buffers for a pool for a particular purpose and have an allocate/free routine. and 2. Maintain a general purpose buffer pool with unknown size and many users. -- - Victor Yodaiken Finite State Machine Labs: The RTLinux Company. www.fsmlabs.com www.rtlinux.com -- [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/
Re: [rtl] task suspended ?
Jan Albiez ([EMAIL PROTECTED]) wrote: Hoi ! Is there any chance to find out wether a task is suspended with pthread_suspend_np ? My problem is, that I have a queue emptying thread, which sould be suspend itself when the queue is empty, and started again for a periodic time until the queue ist empty again. The startup should be done from outside the task. You can use semaphores. To suspend itself, the thread should sem_wait(sem) To wake the thread up, use sem_post(sem); Michael. -- [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/