On Fri, 6 Apr 2001, C. W. Wright (1698) wrote:

> To use/access a set-aside region above linux, I put the following in the
> linux lilo.conf file:
> 
> image=/boot/rtl3.0-2.2.18
>         append="mem=252M"
>         label=rtl2218
>         read-only
>         root=/dev/hda2
> 
> 
> Then you run lilo, and reboot.  In a linux user program you then 
> to set some pointer variables to the physical and virtual above-linux
> area.  For example:
> 
>   if ((fd = open("/dev/mem", O_RDWR)) < 0) {
>     perror("main() opening /dev/mem");
>     return -1;
>   }
> 
> // Establish a pointer to the reserved memory above linux
>   pram_above_linux = (void *) (LINUX_MEGS * MEGABYTE);
>   vram_above_linux = (void *) ((UI32) mmap(0,
>                                    (4 * MEGABYTE),
>                                    PROT_WRITE | PROT_READ,
>                                    MAP_SHARED | MAP_FILE,
>                                    fd,
>                                    (unsigned int) (pram_above_linux)));

This is OK. Remember to use ioremap in kernel space.

--
Tomek

-- [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/

Reply via email to